diff options
author | leot <leot@pkgsrc.org> | 2016-04-27 12:34:58 +0000 |
---|---|---|
committer | leot <leot@pkgsrc.org> | 2016-04-27 12:34:58 +0000 |
commit | 45ac0d9db664be80cdec21156154e937ad0972b5 (patch) | |
tree | c5ebd2242eb3bf202bf067ae3ca778f37ff7f64b /print | |
parent | 54a9844479016721013454a339ee6966d9a5e8e0 (diff) | |
download | pkgsrc-45ac0d9db664be80cdec21156154e937ad0972b5.tar.gz |
Update print/mupdf to 1.9a.
pkgsrc changes:
o Update MASTER_SITES (archive/ subdirectory contains all the distfiles,
latest stable version and also older ones)
o Bump BUILDLINK_A[BP]I_DEPENDS.mupdf to 1.9a due to several API and ABI
changes
Changes:
MuPDF 1.9a (2016-04-26)
-----------------------
Version 1.9a is a bug fix release. If you run into issues with selecting or
searching for text with ligatures, you should upgrade from 1.9.
MuPDF 1.9 (2016-04-18)
-----------------------
The 1.9 release is here!
Headline changes:
* New command line tools: create and run.
* New low-level Java interface for desktop and android.
* Bidirectional layout for Arabic and Hebrew scripts.
* Shaping complex scripts for EPUB text layout.
* Noto fallback fonts for EPUB layout.
mutool create:
* Create new PDF files from scratch.
* Read an annotated content stream in a text file and write a PDF file,
automatically embedding font and image resources.
mutool run:
* Run javascript scripts with MuPDF bindings.
* The interface is similar to the new Java interface.
mutool draw:
* Optional multi-threaded operation (Windows and pthreads).
* Optional low memory mode (primarily for testing).
Diffstat (limited to 'print')
-rw-r--r-- | print/mupdf/Makefile | 9 | ||||
-rw-r--r-- | print/mupdf/PLIST | 9 | ||||
-rw-r--r-- | print/mupdf/buildlink3.mk | 6 | ||||
-rw-r--r-- | print/mupdf/distinfo | 17 | ||||
-rw-r--r-- | print/mupdf/files/mupdf.pc | 2 | ||||
-rw-r--r-- | print/mupdf/patches/patch-Makethird | 19 | ||||
-rw-r--r-- | print/mupdf/patches/patch-ab | 39 | ||||
-rw-r--r-- | print/mupdf/patches/patch-ac | 104 | ||||
-rw-r--r-- | print/mupdf/patches/patch-thirdparty_mujs_Makefile | 47 |
9 files changed, 144 insertions, 108 deletions
diff --git a/print/mupdf/Makefile b/print/mupdf/Makefile index d4018455177..f3679410837 100644 --- a/print/mupdf/Makefile +++ b/print/mupdf/Makefile @@ -1,10 +1,9 @@ -# $NetBSD: Makefile,v 1.35 2016/03/05 11:27:54 jperkin Exp $ +# $NetBSD: Makefile,v 1.36 2016/04/27 12:34:58 leot Exp $ -DISTNAME= mupdf-1.8-source +DISTNAME= mupdf-1.9a-source PKGNAME= ${DISTNAME:S/-source//} -PKGREVISION= 3 CATEGORIES= print -MASTER_SITES= http://mupdf.com/downloads/ +MASTER_SITES= http://mupdf.com/downloads/archive/ MAINTAINER= leot@NetBSD.org HOMEPAGE= http://mupdf.com/ @@ -36,6 +35,7 @@ post-extract: ${WRKSRC}/thirdparty/curl \ ${WRKSRC}/thirdparty/freetype \ ${WRKSRC}/thirdparty/glfw \ + ${WRKSRC}/thirdparty/harfbuzz \ ${WRKSRC}/thirdparty/jbig2dec \ ${WRKSRC}/thirdparty/jpeg \ ${WRKSRC}/thirdparty/openjpeg \ @@ -48,6 +48,7 @@ post-install: ${INSTALL_DATA} ${WRKSRC}/mupdf.pc ${DESTDIR}${PREFIX}/lib/pkgconfig .include "../../devel/zlib/buildlink3.mk" +.include "../../fonts/harfbuzz/buildlink3.mk" .include "../../graphics/freetype2/buildlink3.mk" .include "../../graphics/jbig2dec/buildlink3.mk" .include "../../mk/jpeg.buildlink3.mk" diff --git a/print/mupdf/PLIST b/print/mupdf/PLIST index f4f9f0a27f9..3e28b950a37 100644 --- a/print/mupdf/PLIST +++ b/print/mupdf/PLIST @@ -1,10 +1,11 @@ -@comment $NetBSD: PLIST,v 1.11 2016/02/04 11:50:24 leot Exp $ +@comment $NetBSD: PLIST,v 1.12 2016/04/27 12:34:58 leot Exp $ bin/mujstest bin/mupdf ${PLIST.glfw}bin/mupdf-gl bin/mutool include/mupdf/fitz.h include/mupdf/fitz/annotation.h +include/mupdf/fitz/bidi.h include/mupdf/fitz/bitmap.h include/mupdf/fitz/buffer.h include/mupdf/fitz/colorspace.h @@ -28,12 +29,14 @@ include/mupdf/fitz/outline.h include/mupdf/fitz/output-pcl.h include/mupdf/fitz/output-png.h include/mupdf/fitz/output-pnm.h +include/mupdf/fitz/output-ps.h include/mupdf/fitz/output-pwg.h include/mupdf/fitz/output-svg.h include/mupdf/fitz/output-tga.h include/mupdf/fitz/output.h include/mupdf/fitz/path.h include/mupdf/fitz/pixmap.h +include/mupdf/fitz/pool.h include/mupdf/fitz/separation.h include/mupdf/fitz/shade.h include/mupdf/fitz/store.h @@ -48,7 +51,6 @@ include/mupdf/fitz/ucdn.h include/mupdf/fitz/unzip.h include/mupdf/fitz/util.h include/mupdf/fitz/version.h -include/mupdf/fitz/write-document.h include/mupdf/fitz/xml.h include/mupdf/html.h include/mupdf/memento.h @@ -63,6 +65,7 @@ include/mupdf/pdf/document.h include/mupdf/pdf/event.h include/mupdf/pdf/field.h include/mupdf/pdf/font.h +include/mupdf/pdf/graft.h include/mupdf/pdf/interpret.h include/mupdf/pdf/javascript.h include/mupdf/pdf/name-table.h @@ -74,8 +77,8 @@ include/mupdf/pdf/resource.h include/mupdf/pdf/widget.h include/mupdf/pdf/xref.h include/mupdf/xps.h -lib/libmujs.la lib/libmupdf.la +lib/libmupdfthird.la lib/pkgconfig/mupdf.pc man/man1/mupdf.1 man/man1/mutool.1 diff --git a/print/mupdf/buildlink3.mk b/print/mupdf/buildlink3.mk index 2ba9f4295e9..d657f02ec89 100644 --- a/print/mupdf/buildlink3.mk +++ b/print/mupdf/buildlink3.mk @@ -1,12 +1,12 @@ -# $NetBSD: buildlink3.mk,v 1.10 2016/03/05 11:27:54 jperkin Exp $ +# $NetBSD: buildlink3.mk,v 1.11 2016/04/27 12:34:58 leot Exp $ BUILDLINK_TREE+= mupdf .if !defined(MUPDF_BUILDLINK3_MK) MUPDF_BUILDLINK3_MK:= -BUILDLINK_API_DEPENDS.mupdf+= mupdf>=1.8 -BUILDLINK_ABI_DEPENDS.mupdf?= mupdf>=1.8nb3 +BUILDLINK_API_DEPENDS.mupdf+= mupdf>=1.9a +BUILDLINK_ABI_DEPENDS.mupdf?= mupdf>=1.9a BUILDLINK_PKGSRCDIR.mupdf?= ../../print/mupdf pkgbase := mupdf diff --git a/print/mupdf/distinfo b/print/mupdf/distinfo index 13ea721e960..117a71bc343 100644 --- a/print/mupdf/distinfo +++ b/print/mupdf/distinfo @@ -1,11 +1,12 @@ -$NetBSD: distinfo,v 1.23 2016/02/04 11:50:24 leot Exp $ +$NetBSD: distinfo,v 1.24 2016/04/27 12:34:58 leot Exp $ -SHA1 (mupdf-1.8-source.tar.gz) = 9fbc9e06f0b74fe904745c363324eaca3517bfce -RMD160 (mupdf-1.8-source.tar.gz) = 2708f5650f23101a66cef92b7903aafb716f9c02 -SHA512 (mupdf-1.8-source.tar.gz) = 938fbed4afc0dd0aa621911cd70b9289c6a4f13d026f9390b11fc86d5b37845a76943c9fa42f218f67fe298295f15d6664a18be7bf73b5d952724122510f9deb -Size (mupdf-1.8-source.tar.gz) = 14169777 bytes -SHA1 (patch-Makethird) = a44207c6c33fabec7e35c5f94bf30ab4172a93bc -SHA1 (patch-ab) = a8ea41737aee65ad36ff52089d772844fb96d464 -SHA1 (patch-ac) = 75447e4a2ab2ba9f9691a860499897e15d2498fa +SHA1 (mupdf-1.9a-source.tar.gz) = f2b3c21e5060d6ec56ea0d0c32b0feac7eac0e5f +RMD160 (mupdf-1.9a-source.tar.gz) = 0cb0d098c603b16be217e42299052a928d95c3fc +SHA512 (mupdf-1.9a-source.tar.gz) = 9f804fd65c2dc6b7a3bd73961b1f1a8bf93d52903cccf6302acd6982dfa433125a3b8e77b808984921aee097877280fa21aafb87468cd0a8e4cfa900284a262b +Size (mupdf-1.9a-source.tar.gz) = 20493793 bytes +SHA1 (patch-Makethird) = 0a5951d543755c42053013f03b1c573b5da9c82c +SHA1 (patch-ab) = c1ee4dd0b79aa0d905c0a0b634fbd016c063cd64 +SHA1 (patch-ac) = 51b62ef8ff3e6c44ad954b2405bd982f9d682d37 SHA1 (patch-ae) = c6b113818b32cb4470e8549c00a16e0b2f364ede SHA1 (patch-source_fitz_load-jpx.c) = 661b6a7f1d4da4f0cf5de3762db2f77d91239a6b +SHA1 (patch-thirdparty_mujs_Makefile) = f1da7cdf2c9e2e4bbac3e80ef486204a39b27e34 diff --git a/print/mupdf/files/mupdf.pc b/print/mupdf/files/mupdf.pc index 4fce120701c..c34f5dc6eed 100644 --- a/print/mupdf/files/mupdf.pc +++ b/print/mupdf/files/mupdf.pc @@ -5,6 +5,6 @@ includedir=${prefix}/include Name: mupdf Description: library for PDF files -Version: 1.8 +Version: 1.9a Libs: -Wl,-R${libdir} -L${libdir} -lmupdf Cflags: -I${includedir} diff --git a/print/mupdf/patches/patch-Makethird b/print/mupdf/patches/patch-Makethird index 8a54d5ebfa4..6c5db234ec4 100644 --- a/print/mupdf/patches/patch-Makethird +++ b/print/mupdf/patches/patch-Makethird @@ -1,20 +1,19 @@ -$NetBSD: patch-Makethird,v 1.5 2016/02/04 11:50:24 leot Exp $ +$NetBSD: patch-Makethird,v 1.6 2016/04/27 12:34:58 leot Exp $ o mujs building support with libtool ---- Makethird.orig 2015-11-10 16:19:51.000000000 +0000 +--- Makethird.orig 2016-04-06 12:06:53.000000000 +0000 +++ Makethird -@@ -51,14 +51,14 @@ endif - - ifneq "$(wildcard $(MUJS_DIR)/README)" "" - --MUJS_LIB := $(OUT)/libmujs.a -+MUJS_LIB := $(OUT)/libmujs.la +@@ -24,13 +24,13 @@ ifneq "$(wildcard $(MUJS_DIR)/README)" " MUJS_OUT := $(OUT)/mujs MUJS_SRC := one.c --$(MUJS_LIB): $(addprefix $(MUJS_OUT)/, $(MUJS_SRC:%.c=%.o)) -+$(MUJS_LIB): $(addprefix $(MUJS_OUT)/, $(MUJS_SRC:%.c=%.lo)) +-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) diff --git a/print/mupdf/patches/patch-ab b/print/mupdf/patches/patch-ab index 319bdff40b5..47a55937361 100644 --- a/print/mupdf/patches/patch-ab +++ b/print/mupdf/patches/patch-ab @@ -1,11 +1,11 @@ -$NetBSD: patch-ab,v 1.11 2016/02/04 11:50:24 leot Exp $ +$NetBSD: patch-ab,v 1.12 2016/04/27 12:34:58 leot Exp $ o Handle the various operating systems in the same way avoiding hardcoding -o Build and link with openjpeg-2.1 +o Properly recognize glfw support ---- Makerules.orig 2015-11-10 16:19:51.000000000 +0000 +--- Makerules.orig 2016-04-06 12:06:53.000000000 +0000 +++ Makerules -@@ -29,46 +29,6 @@ ifeq "$(largefile)" "yes" +@@ -43,46 +43,6 @@ ifeq "$(largefile)" "yes" CFLAGS += -DFZ_LARGEFILE endif @@ -13,29 +13,29 @@ o Build and link with openjpeg-2.1 -ifeq "$(OS)" "MINGW" - -HAVE_X11 ?= no --HAVE_GLUT ?= yes -- --SYS_GLUT_CFLAGS = -DFREEGLUT_STATIC -Ithirdparty/freeglut/include --SYS_GLUT_LIBS = -Lthirdparty/freeglut/lib -lfreeglut_static -lopengl32 -lgdi32 -lwinmm - -# Mac OS X doesn't have pkg-config so we hard code paths. -else ifeq "$(OS)" "MACOS" - -HAVE_X11 ?= yes --HAVE_GLUT ?= yes +-HAVE_PTHREADS ?= yes - +-# Mac OS X deprecated openssl, so the default is to not include it. +-HAVE_OPENSSL ?= no +-SYS_OPENSSL_CFLAGS = +-SYS_OPENSSL_LIBS = +-ifeq "$(HAVE_OPENSSL)" "yes" -SYS_OPENSSL_CFLAGS = -DHAVE_OPENSSL -SYS_OPENSSL_LIBS = -lcrypto +-endif - -SYS_CURL_DEPS = -lpthread - -SYS_X11_CFLAGS = -I/usr/X11R6/include -SYS_X11_LIBS = -L/usr/X11R6/lib -lX11 -lXext --SYS_GLUT_CFLAGS = -Wno-deprecated-declarations --SYS_GLUT_LIBS = -framework GLUT -framework OpenGL - --SYS_FREETYPE_CFLAGS = -I/usr/X11R6/include/freetype2 --SYS_FREETYPE_LIBS = -lfreetype +-SYS_FREETYPE_CFLAGS = $(shell freetype-config --cflags) +-SYS_FREETYPE_LIBS = $(shell freetype-config --libs) -SYS_OPENJPEG_LIBS = -lopenjpeg -SYS_JBIG2DEC_LIBS = -ljbig2dec -SYS_JPEG_LIBS = -ljpeg @@ -50,14 +50,12 @@ o Build and link with openjpeg-2.1 -else ifeq "$(OS)" "Linux" - HAVE_X11 ?= yes - HAVE_GLUT ?= yes + HAVE_PTHREADS ?= yes -@@ -87,8 +47,16 @@ SYS_CURL_DEPS = -lpthread -lrt +@@ -101,6 +61,17 @@ SYS_CURL_DEPS = -lpthread -lrt SYS_X11_CFLAGS = $(shell pkg-config --cflags x11 xext) SYS_X11_LIBS = $(shell pkg-config --libs x11 xext) --SYS_GLUT_CFLAGS = --SYS_GLUT_LIBS = -lglut -lGL +ifeq "$(shell pkg-config --exists glut && echo yes)" "yes" +SYS_GLUT_CFLAGS = $(shell pkg-config --cflags glut) +SYS_GLUT_LIBS = $(shell pkg-config --libs glut) @@ -68,10 +66,11 @@ o Build and link with openjpeg-2.1 +SYS_GLFW_CFLAGS = $(shell pkg-config --cflags glfw3) +SYS_GLFW_LIBS = $(shell pkg-config --libs glfw3) +endif - ++ + SYS_HARFBUZZ_CFLAGS = $(shell pkg-config --cflags harfbuzz) + SYS_HARFBUZZ_LIBS = $(shell pkg-config --libs harfbuzz) SYS_FREETYPE_CFLAGS = $(shell pkg-config --cflags freetype2) - SYS_FREETYPE_LIBS = $(shell pkg-config --libs freetype2) -@@ -98,8 +66,6 @@ SYS_JBIG2DEC_LIBS = -ljbig2dec +@@ -111,8 +82,6 @@ SYS_JBIG2DEC_LIBS = -ljbig2dec SYS_JPEG_LIBS = -ljpeg SYS_ZLIB_LIBS = -lz diff --git a/print/mupdf/patches/patch-ac b/print/mupdf/patches/patch-ac index dc1468ceae8..e73d59a83ac 100644 --- a/print/mupdf/patches/patch-ac +++ b/print/mupdf/patches/patch-ac @@ -1,14 +1,14 @@ -$NetBSD: patch-ac,v 1.13 2016/02/04 11:50:24 leot Exp $ +$NetBSD: patch-ac,v 1.14 2016/04/27 12:34:58 leot Exp $ o libtool support o Install target cleanup +o Do not force `-O0' flag when building o Install only one "mupdf" binary, prefer the featureful one and always - install it as "mupdf" -o libmujs support: install like a non-thirdparty mupdf's library + install it as "mupdf" ---- Makefile.orig 2015-11-10 16:19:51.000000000 +0000 +--- Makefile.orig 2016-04-21 11:14:32.000000000 +0000 +++ Makefile -@@ -41,22 +41,12 @@ CFLAGS += $(ZLIB_CFLAGS) +@@ -38,22 +38,12 @@ CFLAGS += $(ZLIB_CFLAGS) # --- Commands --- @@ -37,7 +37,7 @@ o libmujs support: install like a non-thirdparty mupdf's library # --- File lists --- -@@ -91,33 +81,33 @@ XPS_SRC_HDR := $(wildcard source/xps/*.h +@@ -89,17 +79,17 @@ XPS_SRC_HDR := $(wildcard source/xps/*.h HTML_SRC_HDR := $(wildcard source/html/*.h) GPRF_SRC_HDR := $(wildcard source/gprf/*.h) @@ -54,52 +54,36 @@ o libmujs support: install like a non-thirdparty mupdf's library +HTML_OBJ := $(subst source/, $(OUT)/, $(addsuffix .lo, $(basename $(HTML_SRC)))) +GPRF_OBJ := $(subst source/, $(OUT)/, $(addsuffix .lo, $(basename $(GPRF_SRC)))) - # --- Choice of Javascript library --- - ifeq "$(HAVE_MUJS)" "yes" -PDF_OBJ += $(OUT)/pdf/js/pdf-js.o --PDF_OBJ += $(OUT)/pdf/js/pdf-jsimp-mu.o -+PDF_OBJ += $(OUT)/pdf/js/pdf-js.lo -+PDF_OBJ += $(OUT)/pdf/js/pdf-jsimp-mu.lo - THIRD_LIBS += $(MUJS_LIB) - LIBS += $(MUJS_LIBS) - CFLAGS += $(MUJS_CFLAGS) - else ifeq "$(HAVE_JSCORE)" "yes" --PDF_OBJ += $(OUT)/pdf/js/pdf-js.o --PDF_OBJ += $(OUT)/pdf/js/pdf-jsimp-jscore.o -+PDF_OBJ += $(OUT)/pdf/js/pdf-js.lo -+PDF_OBJ += $(OUT)/pdf/js/pdf-jsimp-jscore.lo - LIBS += $(JSCORE_LIBS) - CFLAGS += $(JSCORE_CFLAGS) - else ifeq "$(HAVE_V8)" "yes" --PDF_OBJ += $(OUT)/pdf/js/pdf-js.o --PDF_OBJ += $(OUT)/pdf/js/pdf-jsimp-cpp.o $(OUT)/pdf/js/pdf-jsimp-v8.o +PDF_OBJ += $(OUT)/pdf/js/pdf-js.lo -+PDF_OBJ += $(OUT)/pdf/js/pdf-jsimp-cpp.lo $(OUT)/pdf/js/pdf-jsimp-v8.lo - LIBS += $(V8_LIBS) - CFLAGS += $(V8_CFLAGS) else -PDF_OBJ += $(OUT)/pdf/js/pdf-js-none.o +PDF_OBJ += $(OUT)/pdf/js/pdf-js-none.lo endif $(FITZ_OBJ) : $(FITZ_HDR) $(FITZ_SRC_HDR) -@@ -129,47 +119,50 @@ $(GPRF_OBJ) : $(FITZ_HDR) $(GPRF_HDR) $( - - # --- Library --- +@@ -123,7 +113,7 @@ FONT_GEN_SIL := $(subst resources/fonts/ --MUPDF_LIB := $(OUT)/libmupdf.a -+MUPDF_LIB := $(OUT)/libmupdf.la + FONT_BIN := $(FONT_BIN_DROID) $(FONT_BIN_NOTO) $(FONT_BIN_URW) $(FONT_BIN_SIL) + FONT_GEN := $(FONT_GEN_DROID) $(FONT_GEN_NOTO) $(FONT_GEN_URW) $(FONT_GEN_SIL) +-FONT_OBJ := $(subst $(GEN)/, $(OUT)/fonts/, $(addsuffix .o, $(basename $(FONT_GEN)))) ++FONT_OBJ := $(subst $(GEN)/, $(OUT)/fonts/, $(addsuffix .lo, $(basename $(FONT_GEN)))) - $(MUPDF_LIB) : $(FITZ_OBJ) $(PDF_OBJ) $(XPS_OBJ) $(CBZ_OBJ) $(HTML_OBJ) $(GPRF_OBJ) + $(GEN)/%.c : resources/fonts/droid/%.ttc $(FONTDUMP) + $(QUIET_GEN) $(FONTDUMP) $@ $< +@@ -141,8 +131,8 @@ $(FONT_GEN_URW) : $(FONT_BIN_URW) - INSTALL_LIBS := $(MUPDF_LIB) -+ifeq "$(HAVE_MUJS)" "yes" -+INSTALL_LIBS += $(MUJS_LIB) -+endif + # --- Library --- - # --- Rules --- +-MUPDF_LIB = $(OUT)/libmupdf.a +-THIRD_LIB = $(OUT)/libmupdfthird.a ++MUPDF_LIB = $(OUT)/libmupdf.la ++THIRD_LIB = $(OUT)/libmupdfthird.la + MUPDF_OBJ := $(FITZ_OBJ) $(FONT_OBJ) $(PDF_OBJ) $(XPS_OBJ) $(CBZ_OBJ) $(HTML_OBJ) $(GPRF_OBJ) + THIRD_OBJ := $(FREETYPE_OBJ) $(HARFBUZZ_OBJ) $(JBIG2DEC_OBJ) $(JPEG_OBJ) $(MUJS_OBJ) $(OPENJPEG_OBJ) $(ZLIB_OBJ) +@@ -157,39 +147,39 @@ INSTALL_LIBS := $(MUPDF_LIB) $(THIRD_LIB $(ALL_DIR) $(OUT) $(GEN) : $(MKDIR_CMD) @@ -125,6 +109,11 @@ o libmujs support: install like a non-thirdparty mupdf's library +$(OUT)/%.lo : scripts/%.c | $(OUT) $(CC_CMD) +-$(OUT)/fonts/%.o : $(GEN)/%.c | $(ALL_DIR) +- $(CC_CMD) -O0 ++$(OUT)/fonts/%.lo : $(GEN)/%.c | $(ALL_DIR) ++ $(CC_CMD) + -$(OUT)/platform/x11/%.o : platform/x11/%.c | $(ALL_DIR) +$(OUT)/platform/x11/%.lo : platform/x11/%.c | $(ALL_DIR) $(CC_CMD) $(X11_CFLAGS) @@ -144,20 +133,18 @@ o libmujs support: install like a non-thirdparty mupdf's library -.PRECIOUS : $(OUT)/%.o # Keep intermediates from chained rules +.PRECIOUS : $(OUT)/%.lo # Keep intermediates from chained rules - # --- Generated CMAP, FONT and JAVASCRIPT files --- + # --- Generated CMap and JavaScript files --- -@@ -233,17 +226,17 @@ endif +@@ -240,16 +230,16 @@ endif generate: $(CMAP_GEN) $(FONT_GEN) $(JAVASCRIPT_GEN) $(ADOBECA_GEN) $(NAME_GEN) -$(OUT)/pdf/pdf-cmap-table.o : $(CMAP_GEN) --$(OUT)/pdf/pdf-fontfile.o : $(FONT_GEN) -$(OUT)/pdf/pdf-pkcs7.o : $(ADOBECA_GEN) -$(OUT)/pdf/js/pdf-js.o : $(JAVASCRIPT_GEN) -$(OUT)/pdf/pdf-object.o : source/pdf/pdf-name-table.h -$(OUT)/cmapdump.o : include/mupdf/pdf/cmap.h source/pdf/pdf-cmap.c source/pdf/pdf-cmap-parse.c source/pdf/pdf-name-table.h +$(OUT)/pdf/pdf-cmap-table.lo : $(CMAP_GEN) -+$(OUT)/pdf/pdf-fontfile.lo : $(FONT_GEN) +$(OUT)/pdf/pdf-pkcs7.lo : $(ADOBECA_GEN) +$(OUT)/pdf/js/pdf-js.lo : $(JAVASCRIPT_GEN) +$(OUT)/pdf/pdf-object.lo : source/pdf/pdf-name-table.h @@ -166,15 +153,15 @@ o libmujs support: install like a non-thirdparty mupdf's library # --- Tools and Apps --- MUTOOL := $(addprefix $(OUT)/, mutool) --MUTOOL_OBJ := $(addprefix $(OUT)/tools/, mutool.o mudraw.o pdfclean.o pdfextract.o pdfinfo.o pdfposter.o pdfshow.o pdfpages.o) -+MUTOOL_OBJ := $(addprefix $(OUT)/tools/, mutool.lo mudraw.lo pdfclean.lo pdfextract.lo pdfinfo.lo pdfposter.lo pdfshow.lo pdfpages.lo) +-MUTOOL_OBJ := $(addprefix $(OUT)/tools/, mutool.o mudraw.o murun.o pdfclean.o pdfcreate.o pdfextract.o pdfinfo.o pdfposter.o pdfshow.o pdfpages.o pdfmerge.o) ++MUTOOL_OBJ := $(addprefix $(OUT)/tools/, mutool.lo mudraw.lo murun.lo pdfclean.lo pdfcreate.lo pdfextract.lo pdfinfo.lo pdfposter.lo pdfshow.lo pdfpages.lo pdfmerge.lo) $(MUTOOL_OBJ): $(FITZ_HDR) $(PDF_HDR) - $(MUTOOL) : $(MUPDF_LIB) $(THIRD_LIBS) + $(MUTOOL) : $(MUPDF_LIB) $(THIRD_LIB) $(MUTOOL) : $(MUTOOL_OBJ) -@@ -251,27 +244,27 @@ $(MUTOOL) : $(MUTOOL_OBJ) +@@ -257,27 +247,27 @@ $(MUTOOL) : $(MUTOOL_OBJ) MJSGEN := $(OUT)/mjsgen - $(MJSGEN) : $(MUPDF_LIB) $(THIRD_LIBS) + $(MJSGEN) : $(MUPDF_LIB) $(THIRD_LIB) -$(MJSGEN) : $(addprefix $(OUT)/tools/, mjsgen.o) +$(MJSGEN) : $(addprefix $(OUT)/tools/, mjsgen.lo) $(LINK_CMD) @@ -183,7 +170,7 @@ o libmujs support: install like a non-thirdparty mupdf's library -MUJSTEST_OBJ := $(addprefix $(OUT)/platform/x11/, jstest_main.o pdfapp.o) +MUJSTEST_OBJ := $(addprefix $(OUT)/platform/x11/, jstest_main.lo pdfapp.lo) $(MUJSTEST_OBJ) : $(FITZ_HDR) $(PDF_HDR) - $(MUJSTEST) : $(MUPDF_LIB) $(THIRD_LIBS) + $(MUJSTEST) : $(MUPDF_LIB) $(THIRD_LIB) $(MUJSTEST) : $(MUJSTEST_OBJ) $(LINK_CMD) @@ -193,7 +180,7 @@ o libmujs support: install like a non-thirdparty mupdf's library +MUVIEW_X11 := $(OUT)/platform/x11/mupdf +MUVIEW_X11_OBJ := $(addprefix $(OUT)/platform/x11/, x11_main.lo x11_image.lo pdfapp.lo) $(MUVIEW_X11_OBJ) : $(FITZ_HDR) $(PDF_HDR) - $(MUVIEW_X11) : $(MUPDF_LIB) $(THIRD_LIBS) + $(MUVIEW_X11) : $(MUPDF_LIB) $(THIRD_LIB) $(MUVIEW_X11) : $(MUVIEW_X11_OBJ) $(LINK_CMD) $(X11_LIBS) @@ -203,9 +190,9 @@ o libmujs support: install like a non-thirdparty mupdf's library +MUVIEW_GLFW := $(OUT)/platform/gl/mupdf-gl +MUVIEW_GLFW_OBJ := $(addprefix $(OUT)/platform/gl/, gl-font.lo gl-input.lo gl-main.lo) $(MUVIEW_GLFW_OBJ) : $(FITZ_HDR) $(PDF_HDR) platform/gl/gl-app.h - $(MUVIEW_GLFW) : $(MUPDF_LIB) $(THIRD_LIBS) $(GLFW_LIB) + $(MUVIEW_GLFW) : $(MUPDF_LIB) $(THIRD_LIB) $(GLFW_LIB) $(MUVIEW_GLFW) : $(MUVIEW_GLFW_OBJ) -@@ -279,8 +272,8 @@ $(MUVIEW_GLFW) : $(MUVIEW_GLFW_OBJ) +@@ -285,8 +275,8 @@ $(MUVIEW_GLFW) : $(MUVIEW_GLFW_OBJ) endif ifeq "$(HAVE_CURL)" "yes" @@ -214,16 +201,16 @@ o libmujs support: install like a non-thirdparty mupdf's library +MUVIEW_X11_CURL := $(OUT)/platform/x11/curl/mupdf +MUVIEW_X11_CURL_OBJ := $(addprefix $(OUT)/platform/x11/curl/, x11_main.lo x11_image.lo pdfapp.lo curl_stream.lo) $(MUVIEW_X11_CURL_OBJ) : $(FITZ_HDR) $(PDF_HDR) - $(MUVIEW_X11_CURL) : $(MUPDF_LIB) $(THIRD_LIBS) $(CURL_LIB) + $(MUVIEW_X11_CURL) : $(MUPDF_LIB) $(THIRD_LIB) $(CURL_LIB) $(MUVIEW_X11_CURL) : $(MUVIEW_X11_CURL_OBJ) -@@ -290,17 +283,27 @@ endif +@@ -296,17 +286,26 @@ endif ifeq "$(HAVE_WIN32)" "yes" MUVIEW_WIN32 := $(OUT)/mupdf -MUVIEW_WIN32_OBJ := $(addprefix $(OUT)/platform/x11/, win_main.o pdfapp.o win_res.o) +MUVIEW_WIN32_OBJ := $(addprefix $(OUT)/platform/x11/, win_main.lo pdfapp.lo win_res.lo) $(MUVIEW_WIN32_OBJ) : $(FITZ_HDR) $(PDF_HDR) - $(MUVIEW_WIN32) : $(MUPDF_LIB) $(THIRD_LIBS) + $(MUVIEW_WIN32) : $(MUPDF_LIB) $(THIRD_LIB) $(MUVIEW_WIN32) : $(MUVIEW_WIN32_OBJ) $(LINK_CMD) $(WIN32_LIBS) endif @@ -231,23 +218,22 @@ o libmujs support: install like a non-thirdparty mupdf's library -MUVIEW := $(MUVIEW_X11) $(MUVIEW_WIN32) $(MUVIEW_GLFW) +MUVIEW := $(MUVIEW_X11) $(MUVIEW_WIN32) MUVIEW_CURL := $(MUVIEW_X11_CURL) $(MUVIEW_WIN32_CURL) -+MUVIEW_GLFW := $(MUVIEW_GLFW) -+ + +-INSTALL_APPS := $(MUTOOL) $(MUVIEW) $(MUJSTEST) $(MUVIEW_CURL) +INSTALL_APPS := $(MUTOOL) $(MUJSTEST) +ifeq "$(HAVE_CURL)" "yes" +INSTALL_APPS += $(MUVIEW_CURL) +else ifeq "$(HAVE_X11)" "yes" +INSTALL_APPS += $(MUVIEW) +endif - --INSTALL_APPS := $(MUTOOL) $(MUVIEW) $(MUJSTEST) $(MUVIEW_CURL) ++ +ifeq "$(HAVE_GLFW)" "yes" +INSTALL_APPS += $(MUVIEW_GLFW) +endif # --- Examples --- -@@ -343,24 +346,26 @@ libs: $(INSTALL_LIBS) +@@ -349,24 +348,26 @@ libs: $(INSTALL_LIBS) apps: $(INSTALL_APPS) install: libs apps diff --git a/print/mupdf/patches/patch-thirdparty_mujs_Makefile b/print/mupdf/patches/patch-thirdparty_mujs_Makefile new file mode 100644 index 00000000000..334af5cc58f --- /dev/null +++ b/print/mupdf/patches/patch-thirdparty_mujs_Makefile @@ -0,0 +1,47 @@ +$NetBSD: patch-thirdparty_mujs_Makefile,v 1.1 2016/04/27 12:34:58 leot Exp $ + +o Add libtool support lo mujs. +o Avoid to set (unused) VERSION variable. + +--- thirdparty/mujs/Makefile.orig 2016-03-01 20:52:00.000000000 +0000 ++++ thirdparty/mujs/Makefile +@@ -41,16 +41,16 @@ jsdump.c: astnames.h opnames.h + build: + mkdir -p build + +-build/%.o: %.c $(HDRS) ++build/%.lo: %.c $(HDRS) + $(CC) $(CFLAGS) -o $@ -c $< + +-build/libmujs.a: $(OBJS) ++build/libmujs.la: $(OBJS) + $(AR) cru $@ $^ + +-build/mujs: build/main.o build/libmujs.a ++build/mujs: build/main.lo build/libmujs.la + $(CC) $(LDFLAGS) -o $@ $^ -lm + +-build/mujsone: build/main.o build/one.o ++build/mujsone: build/main.o build/one.lo + $(CC) $(LDFLAGS) -o $@ $^ -lm + + install: release +@@ -61,12 +61,12 @@ install: release + install build/libmujs.a $(DESTDIR)$(libdir) + install build/mujs $(DESTDIR)$(bindir) + +-VERSION = $(shell git describe --tags --always) +- +-tarball: +- git archive --format=zip --prefix=mujs-$(VERSION)/ HEAD > mujs-$(VERSION).zip +- git archive --format=tar --prefix=mujs-$(VERSION)/ HEAD | gzip > mujs-$(VERSION).tar.gz +- git archive --format=tar --prefix=mujs-$(VERSION)/ HEAD | xz > mujs-$(VERSION).tar.xz ++#VERSION = $(shell git describe --tags --always) ++# ++#tarball: ++# git archive --format=zip --prefix=mujs-$(VERSION)/ HEAD > mujs-$(VERSION).zip ++# git archive --format=tar --prefix=mujs-$(VERSION)/ HEAD | gzip > mujs-$(VERSION).tar.gz ++# git archive --format=tar --prefix=mujs-$(VERSION)/ HEAD | xz > mujs-$(VERSION).tar.xz + + tags: $(SRCS) main.c $(HDRS) + ctags $^ |