pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/print/mupdf mupdf: Update print/mupdf to 1.14.0



details:   https://anonhg.NetBSD.org/pkgsrc/rev/ef0464277a35
branches:  trunk
changeset: 323998:ef0464277a35
user:      leot <leot%pkgsrc.org@localhost>
date:      Thu Oct 04 19:02:33 2018 +0000

description:
mupdf: Update print/mupdf to 1.14.0

pkgsrc changes:
 - Pass USE_SYSTEM_LIBS=yes via MAKE_ENV in order to honor system (pkgsrc)
   packages {C,LD}FLAGS
 - Rewrite the logic to disable lcms2 in patch-ab and inject -DNO_ICC
   directly via CFLAGS

Changes:
MuPDF 1.14.0
------------
* New features:
    * Added "Source Han Serif" CJK fallback font.
    * Added more scripts to the Noto fallback fonts.
    * Multi-page PNM support.
    * "mutool show" now supports a path syntax for selecting objects to show.

* Build system simplifications:
    * Auto-generated CMap, ICC, and JS source files are checked in to git.
    * Embedded CMap resources are now generated by a python script.
    * Embedded font resources are linked directly if using GNU ld or windows.
    * Namegen tool replaced by use of C macros.
    * Simplified Makefile.

* Annotation editing:
    * New annotation editing mode in mupdf-gl.
    * Can create, edit, and delete most annotation types.
    * Can create appearance streams for most annotation types.
    * Can create appearance streams for Tx form fields.
    * Can create appearance streams for Ch form fields.

* Form filling in mupdf-gl:
    * Can click buttons, checkboxes, and radioboxes.
    * Can fill out text fields using dialog box.
    * Can select choice options using dialog box.
    * Can verify and sign digital signatures.

* Improved UI for mupdf-gl:
    * Password dialog.
    * Error dialog.
    * Open/save file dialog.
    * Snap selection to words or lines by holding control or control+shift.
    * Save and restore current location, bookmarks, and navigation history.

* Bug fixes:
    * Improved CJK character fallback handling in EPUB.

* API changes:
    * Pass rectangle and matrix structs by value.
    * Replaced PDF_NAME_Xxx macros with PDF_NAME(Xxx).
    * Added PDF_TRUE, PDF_FALSE, and PDF_NULL constant pdf_obj* macros.
    * Added helper functions: pdf_dict_get_int, etc.
    * Removed 'doc' argument in pdf_new_int, etc.
    * Quads instead of rects when highlighting and searching text.
    * mutool run: Pass arguments to script in scriptArgs global.

diffstat:

 print/mupdf/Makefile                               |    6 +-
 print/mupdf/PLIST                                  |   11 +-
 print/mupdf/buildlink3.mk                          |    5 +-
 print/mupdf/distinfo                               |   24 +-
 print/mupdf/files/mupdf.pc                         |    2 +-
 print/mupdf/patches/patch-Makethird                |   32 +-
 print/mupdf/patches/patch-ab                       |  193 ++++++---
 print/mupdf/patches/patch-ac                       |  404 ++++++++++----------
 print/mupdf/patches/patch-platform_gl_gl-app.h     |   10 +-
 print/mupdf/patches/patch-platform_gl_gl-main.c    |   23 +-
 print/mupdf/patches/patch-source_fitz_load-jpx.c   |   18 +-
 print/mupdf/patches/patch-thirdparty_mujs_Makefile |   35 +-
 12 files changed, 403 insertions(+), 360 deletions(-)

diffs (truncated from 1093 to 300 lines):

diff -r bce05b6ff40f -r ef0464277a35 print/mupdf/Makefile
--- a/print/mupdf/Makefile      Thu Oct 04 16:05:56 2018 +0000
+++ b/print/mupdf/Makefile      Thu Oct 04 19:02:33 2018 +0000
@@ -1,8 +1,7 @@
-# $NetBSD: Makefile,v 1.61 2018/08/16 18:54:31 adam Exp $
+# $NetBSD: Makefile,v 1.62 2018/10/04 19:02:33 leot Exp $
 
-DISTNAME=      mupdf-1.13.0-source
+DISTNAME=      mupdf-1.14.0-source
 PKGNAME=       ${DISTNAME:S/-source//}
-PKGREVISION=   1
 CATEGORIES=    print
 MASTER_SITES=  https://mupdf.com/downloads/archive/
 
@@ -23,6 +22,7 @@
 MAKE_FLAGS+=           XCFLAGS=${CFLAGS:Q}
 MAKE_FLAGS+=           build=release
 MAKE_ENV+=             HAVE_LIBCRYPTO=no       # Needs openssl-1.1.0
+MAKE_ENV+=             USE_SYSTEM_LIBS=yes
 
 CFLAGS+=       -DJBIG_NO_MEMENTO
 CFLAGS.SunOS+= -D_XOPEN_SOURCE=600
diff -r bce05b6ff40f -r ef0464277a35 print/mupdf/PLIST
--- a/print/mupdf/PLIST Thu Oct 04 16:05:56 2018 +0000
+++ b/print/mupdf/PLIST Thu Oct 04 19:02:33 2018 +0000
@@ -1,4 +1,4 @@
-@comment $NetBSD: PLIST,v 1.16 2018/05/06 13:19:10 leot Exp $
+@comment $NetBSD: PLIST,v 1.17 2018/10/04 19:02:33 leot Exp $
 bin/mjsgen
 bin/mujstest
 bin/mupdf
@@ -64,7 +64,6 @@
 include/mupdf/pdf-tools.h
 include/mupdf/pdf.h
 include/mupdf/pdf/annot.h
-include/mupdf/pdf/appearance.h
 include/mupdf/pdf/clean.h
 include/mupdf/pdf/cmap.h
 include/mupdf/pdf/crypt.h
@@ -83,10 +82,10 @@
 include/mupdf/pdf/widget.h
 include/mupdf/pdf/xref.h
 include/mupdf/ucdn.h
+lib/libmupdf-pkcs7.la
+lib/libmupdf-third.la
+lib/libmupdf-threads.la
 lib/libmupdf.la
-lib/libmupdfthird.la
-lib/libmupkcs7.la
-lib/libmuthreads.la
 lib/pkgconfig/mupdf.pc
 man/man1/mupdf.1
 man/man1/mutool.1
@@ -99,10 +98,12 @@
 share/doc/mupdf/coding-overview.html
 share/doc/mupdf/coding-progressive.html
 share/doc/mupdf/coding-style.html
+share/doc/mupdf/examples/bbox-device.js
 share/doc/mupdf/examples/create-thumbnail.js
 share/doc/mupdf/examples/draw-device.js
 share/doc/mupdf/examples/draw-document.js
 share/doc/mupdf/examples/example.c
+share/doc/mupdf/examples/fix-s22pdf.js
 share/doc/mupdf/examples/jpx-to-pdf.js
 share/doc/mupdf/examples/multi-threaded.c
 share/doc/mupdf/examples/pdf-create-lowlevel.js
diff -r bce05b6ff40f -r ef0464277a35 print/mupdf/buildlink3.mk
--- a/print/mupdf/buildlink3.mk Thu Oct 04 16:05:56 2018 +0000
+++ b/print/mupdf/buildlink3.mk Thu Oct 04 19:02:33 2018 +0000
@@ -1,12 +1,11 @@
-# $NetBSD: buildlink3.mk,v 1.25 2018/08/16 18:54:31 adam Exp $
+# $NetBSD: buildlink3.mk,v 1.26 2018/10/04 19:02:33 leot Exp $
 
 BUILDLINK_TREE+=       mupdf
 
 .if !defined(MUPDF_BUILDLINK3_MK)
 MUPDF_BUILDLINK3_MK:=
 
-BUILDLINK_API_DEPENDS.mupdf+=  mupdf>=1.13.0
-BUILDLINK_ABI_DEPENDS.mupdf?=  mupdf>=1.13.0nb1
+BUILDLINK_API_DEPENDS.mupdf+=  mupdf>=1.14.0
 BUILDLINK_PKGSRCDIR.mupdf?=    ../../print/mupdf
 
 pkgbase := mupdf
diff -r bce05b6ff40f -r ef0464277a35 print/mupdf/distinfo
--- a/print/mupdf/distinfo      Thu Oct 04 16:05:56 2018 +0000
+++ b/print/mupdf/distinfo      Thu Oct 04 19:02:33 2018 +0000
@@ -1,14 +1,14 @@
-$NetBSD: distinfo,v 1.40 2018/05/06 13:19:10 leot Exp $
+$NetBSD: distinfo,v 1.41 2018/10/04 19:02:33 leot Exp $
 
-SHA1 (mupdf-1.13.0-source.tar.gz) = d4fe867dbdef2e1a465e66cbbd1efb4b1285ef48
-RMD160 (mupdf-1.13.0-source.tar.gz) = 078e972c2f41a34308a52af24ac5ddbf41471342
-SHA512 (mupdf-1.13.0-source.tar.gz) = d7fca7292e612959893a728d35964cf7b4e607385bdd72e81b8ca1de6ab642f999b734afbbf32d75400cd29b7e178ec360e65c91d7b1e1a53c2a04ff0adbd707
-Size (mupdf-1.13.0-source.tar.gz) = 51425034 bytes
-SHA1 (patch-Makethird) = 77820f7344e00140a9792b5a6a3ddb1afa01b7bb
-SHA1 (patch-ab) = 5ca9de36a7f38cdcf0578cded98cdd54bed78ab5
-SHA1 (patch-ac) = 0c140ee7f0a86bc300c91845da0bd3bf5f0b7c14
+SHA1 (mupdf-1.14.0-source.tar.gz) = 289023cd4d10cc42177cd5ee3f20a936f35c84a4
+RMD160 (mupdf-1.14.0-source.tar.gz) = 5b0d14594da547dd80332b96dad93477b6a5d096
+SHA512 (mupdf-1.14.0-source.tar.gz) = 9a8c5d7ce8336fd2cc2d49574a9f3909900e77a734e804380c17a30df1b10bb9c35d781f43dd70b423bf3c607575ef5a901bb70c1b6ce703fe27e03818fc2a62
+Size (mupdf-1.14.0-source.tar.gz) = 55652044 bytes
+SHA1 (patch-Makethird) = 33b7ccf235e971c44e159a687cecc033155957ba
+SHA1 (patch-ab) = 5ef190923d648165cdf29174f1521bd069c7e6f9
+SHA1 (patch-ac) = 4f685e425bff4d257ca3bce3d2b536d5cea1e8aa
 SHA1 (patch-ae) = c6b113818b32cb4470e8549c00a16e0b2f364ede
-SHA1 (patch-platform_gl_gl-app.h) = 6e5e547df27ecb2b82cadd71489d2eb9138c1ce2
-SHA1 (patch-platform_gl_gl-main.c) = 526c3e8c1c548490ef97f59e491b237f803f250e
-SHA1 (patch-source_fitz_load-jpx.c) = b507c1ebab027167af363c9f0f64d8690ea75ff3
-SHA1 (patch-thirdparty_mujs_Makefile) = d3e163bcc4e3d2509401b87e5da8eddb35394dc9
+SHA1 (patch-platform_gl_gl-app.h) = f8682b54821a560b2ba1082bcf215eeefb549644
+SHA1 (patch-platform_gl_gl-main.c) = edff1aa77c4d6af59b2eca442340606a0bae9970
+SHA1 (patch-source_fitz_load-jpx.c) = 161d21bca13bb57db37807aec844c85dc5b34157
+SHA1 (patch-thirdparty_mujs_Makefile) = fc7cbbbeb2a59c4322e2ed46e12cf3dddfd21d28
diff -r bce05b6ff40f -r ef0464277a35 print/mupdf/files/mupdf.pc
--- a/print/mupdf/files/mupdf.pc        Thu Oct 04 16:05:56 2018 +0000
+++ b/print/mupdf/files/mupdf.pc        Thu Oct 04 19:02:33 2018 +0000
@@ -6,5 +6,5 @@
 Name: mupdf
 Description: library for PDF files
 Version: @VERSION@
-Libs: -Wl,-R${libdir} -L${libdir} -lmupdf -lmupdfthird -lmuthreads -lmupkcs7
+Libs: -Wl,-R${libdir} -L${libdir} -lmupdf -lmupdf-third -lmupdf-threads -lmupdf-pkcs7
 Cflags: -I${includedir}
diff -r bce05b6ff40f -r ef0464277a35 print/mupdf/patches/patch-Makethird
--- a/print/mupdf/patches/patch-Makethird       Thu Oct 04 16:05:56 2018 +0000
+++ b/print/mupdf/patches/patch-Makethird       Thu Oct 04 19:02:33 2018 +0000
@@ -1,35 +1,17 @@
-$NetBSD: patch-Makethird,v 1.8 2017/12/18 15:06:34 leot Exp $
+$NetBSD: patch-Makethird,v 1.9 2018/10/04 19:02:33 leot Exp $
 
 - mujs building support with libtool
 - Avoid the internal lcms2 version provided and honors SYS_LCMS2_{CFLAGS,LIBS}.
   These are handled in patches/patch-ab.
 
---- Makethird.orig     2017-11-23 11:42:45.000000000 +0000
+--- Makethird.orig     2018-09-25 12:39:17.000000000 +0000
 +++ Makethird
-@@ -27,13 +27,13 @@ ifneq "$(wildcard $(MUJS_DIR)/README)" "
- MUJS_OUT := $(OUT)/thirdparty/mujs
- MUJS_SRC := one.c
+@@ -229,7 +229,7 @@ else
+ THIRD_SRC += thirdparty/mujs/one.c
+ THIRD_CFLAGS += -Ithirdparty/mujs
  
--MUJS_OBJ := $(addprefix $(MUJS_OUT)/, $(MUJS_SRC:%.c=%.o))
-+MUJS_OBJ := $(addprefix $(MUJS_OUT)/, $(MUJS_SRC:%.c=%.lo))
- 
--$(MUJS_OUT)/one.o: $(wildcard $(MUJS_DIR)/js*.c $(MUJS_DIR)/utf*.c $(MUJS_DIR)/regex.c $(MUJS_DIR)/*.h)
-+$(MUJS_OUT)/one.lo: $(wildcard $(MUJS_DIR)/js*.c $(MUJS_DIR)/utf*.c $(MUJS_DIR)/regex.c $(MUJS_DIR)/*.h)
- 
- $(MUJS_OUT):
-       $(MKDIR_CMD)
--$(MUJS_OUT)/%.o: $(MUJS_DIR)/%.c | $(MUJS_OUT)
-+$(MUJS_OUT)/%.lo: $(MUJS_DIR)/%.c | $(MUJS_OUT)
+-$(OUT)/thirdparty/mujs/%.o: thirdparty/mujs/%.c
++$(OUT)/thirdparty/mujs/%.lo: thirdparty/mujs/%.c
        $(CC_CMD)
  
- MUJS_CFLAGS := -I$(MUJS_DIR)
-@@ -575,7 +575,8 @@ $(LCMS2_OUT)/%.o: $(LCMS2_DIR)/src/%.c |
- 
- LCMS2_CFLAGS := -I$(LCMS2_DIR)/include
- else
--LCMS2_CFLAGS := -DNO_ICC
-+LCMS2_CFLAGS := $(SYS_LCMS2_CFLAGS)
-+LCMS2_LIBS := $(SYS_LCMS2_LIBS)
  endif
- 
- # --- cURL ---
diff -r bce05b6ff40f -r ef0464277a35 print/mupdf/patches/patch-ab
--- a/print/mupdf/patches/patch-ab      Thu Oct 04 16:05:56 2018 +0000
+++ b/print/mupdf/patches/patch-ab      Thu Oct 04 19:02:33 2018 +0000
@@ -1,92 +1,145 @@
-$NetBSD: patch-ab,v 1.17 2018/05/06 13:19:10 leot Exp $
+$NetBSD: patch-ab,v 1.18 2018/10/04 19:02:33 leot Exp $
 
 - Handle the various operating systems in the same way avoiding hardcoding
+- Avoid to use objcopy by setting HAVE_OBJCOPY to no (if `yes', and with
+  `USE_TOOLS+= objcopy' the objcopy-ing fails as follow:
+    OBJCOPY build/release/resources/fonts/urw/Dingbats.cff.o
+    build/release/resources/fonts/urw/Dingbats.cff.o:1: warning: NUL character seen; rest of line ignored
+    build/release/resources/fonts/urw/Dingbats.cff.o:1: *** missing separator.  Stop.
+  (also for other fonts)).  This needs to be investigated further.
 - Avoid internal version of freeglut and try to pick it up via pkg-config and
   set SYS_GLUT_{CFLAGS,LIBS} accordingly.
 - Avoid internal version of lcms2 and try to pick it up via pkg-config and
   set SYS_LCMS2_{CFLAGS,LIBS} accordingly.
   If no lcms2 is available just pass `-DNO_ICC' to disable it via
-  SYS_LCMS2_CFLAGS.
+  CFLAGS.
 
---- Makerules.orig     2018-04-12 13:14:06.000000000 +0000
+--- Makerules.orig     2018-09-25 12:39:17.000000000 +0000
 +++ Makerules
-@@ -65,38 +65,10 @@ else
- $(error unknown build setting: '$(build)')
- endif
+@@ -6,17 +6,6 @@ OS := $(OS:MSYS%=MINGW)
+ OS := $(OS:Windows_NT=MINGW)
+ OS := $(OS:Darwin=MACOS)
  
--# Windows (MINGW) build doesn't use system libraries.
--ifeq "$(OS)" "MINGW"
+-ifeq ($(findstring -fembed-bitcode,$(XCFLAGS)),)
+-  # clang does not support these in combination with -fembed-bitcode
+-  CFLAGS += -ffunction-sections -fdata-sections
+-endif
+-
+-ifeq ($(OS),MACOS)
+-  LDREMOVEUNREACH := -Wl,-dead_strip
+-else
+-  LDREMOVEUNREACH := -Wl,--gc-sections
+-endif
 -
--WINDRES := windres
--HAVE_X11 ?= no
--HAVE_WIN32 := yes
+ SANITIZE_FLAGS += -fsanitize=address
+ SANITIZE_FLAGS += -fsanitize=leak
+ 
+@@ -72,77 +61,63 @@ SYS_MUJS_LIBS := -lmujs
+ SYS_OPENJPEG_LIBS := -lopenjp2
+ SYS_ZLIB_LIBS := -lz
+ 
+-ifeq ($(OS),MINGW)
+-  WINDRES := windres
+-  HAVE_WIN32 := yes
 -
--# Mac OS X doesn't have pkg-config so we hard code paths.
--else ifeq "$(OS)" "MACOS"
--
--HAVE_X11 ?= no
--
--HAVE_GLUT ?= yes
--SYS_GLUT_CFLAGS := -Wno-deprecated-declarations
--SYS_GLUT_LIBS := -framework GLUT -framework OpenGL
+-else ifeq ($(OS),MACOS)
+-  HAVE_GLUT := yes
+-  SYS_GLUT_CFLAGS := -Wno-deprecated-declarations
+-  SYS_GLUT_LIBS := -framework GLUT -framework OpenGL
+-  CC = xcrun cc
+-  AR = xcrun ar
+-  LD = xcrun ld
+-  RANLIB = xcrun ranlib
++HAVE_OBJCOPY := no
+ 
+-else ifeq ($(OS),Linux)
+-  HAVE_OBJCOPY := yes
 -
--CC = xcrun cc
--AR = xcrun ar
--LD = xcrun ld
--RANLIB_CMD = xcrun ranlib $@
--
--# Linux uses pkg-config for system libraries.
--else ifeq "$(OS)" "Linux"
--
- HAVE_PTHREAD := yes
- SYS_PTHREAD_CFLAGS :=
- SYS_PTHREAD_LIBS := -lpthread
+-  ifeq ($(shell pkg-config --exists freetype2 && echo yes),yes)
++ifeq ($(shell pkg-config --exists freetype2 && echo yes),yes)
+       SYS_FREETYPE_CFLAGS := $(shell pkg-config --cflags freetype2)
+       SYS_FREETYPE_LIBS := $(shell pkg-config --libs freetype2)
+-  endif
+-  ifeq ($(shell pkg-config --exists harfbuzz && echo yes),yes)
++endif
++ifeq ($(shell pkg-config --exists harfbuzz && echo yes),yes)
+       SYS_HARFBUZZ_CFLAGS := $(shell pkg-config --cflags harfbuzz)
+       SYS_HARFBUZZ_LIBS := $(shell pkg-config --libs harfbuzz)
+-  endif
+-  ifeq ($(shell pkg-config --exists lcms2 && echo yes),yes)
++endif
++ifeq ($(shell pkg-config --exists lcms2 && echo yes),yes)
+       SYS_LCMS2_CFLAGS := $(shell pkg-config --cflags lcms2)
+       SYS_LCMS2_LIBS := $(shell pkg-config --libs lcms2)
+-  endif
+-  ifeq ($(shell pkg-config --exists libjpeg && echo yes),yes)
++else
++      CFLAGS += -DNO_ICC
++endif
++ifeq ($(shell pkg-config --exists libjpeg && echo yes),yes)
+       SYS_LIBJPEG_CFLAGS := $(shell pkg-config --cflags libjpeg)
+       SYS_LIBJPEG_LIBS := $(shell pkg-config --libs libjpeg)
+-  endif
+-  ifeq ($(shell pkg-config --exists libopenjp2 && echo yes),yes)
++endif
++ifeq ($(shell pkg-config --exists libopenjp2 && echo yes),yes)
+       SYS_OPENJPEG_CFLAGS := $(shell pkg-config --cflags libopenjp2)
+       SYS_OPENJPEG_LIBS := $(shell pkg-config --libs libopenjp2)
+-  endif
+-  ifeq ($(shell pkg-config --exists zlib && echo yes),yes)
++endif
++ifeq ($(shell pkg-config --exists zlib && echo yes),yes)
+       SYS_ZLIB_CFLAGS := $(shell pkg-config --cflags zlib)
+       SYS_ZLIB_LIBS := $(shell pkg-config --libs zlib)
+-  endif
++endif
  



Home | Main Index | Thread Index | Old Index