summaryrefslogtreecommitdiff
path: root/print
diff options
context:
space:
mode:
authorwiz <wiz>2010-02-18 10:07:32 +0000
committerwiz <wiz>2010-02-18 10:07:32 +0000
commit41ebde9dbdbae8f92d6c6ac7f9cc6ca7f08bdc10 (patch)
tree98337b90dcc5b891b81bcfcb3673f88cc5471e0a /print
parent7ecb305d94f17925488b25106b35aa3fa97256a0 (diff)
downloadpkgsrc-41ebde9dbdbae8f92d6c6ac7f9cc6ca7f08bdc10.tar.gz
Initial import of mupdf-0.0.937 (svn version 937).
MuPDF is a lightweight PDF viewer and toolkit written in portable C. The renderer in MuPDF is tailored for high quality anti-aliased graphics. MuPDF renders text with metrics and spacing accurate to within fractions of a pixel for the highest fidelity in reproducing the look of a printed page on screen. MuPDF has a small footprint. A binary that includes the standard Roman fonts is only one megabyte. A build with full CJK support (including an Asian font) is approximately five megabytes. MuPDF has support for all non-interactive PDF 1.7 features, and the toolkit provides a simple API for accessing the internal structures of the PDF document. Example code for navigating interactive links and bookmarks, encrypting PDF files, extracting fonts, images, and searchable text, and rendering pages to image files is provided.
Diffstat (limited to 'print')
-rw-r--r--print/mupdf/DESCR17
-rw-r--r--print/mupdf/Makefile45
-rw-r--r--print/mupdf/PLIST11
-rw-r--r--print/mupdf/buildlink3.mk14
-rw-r--r--print/mupdf/distinfo6
-rw-r--r--print/mupdf/files/mupdf.pc10
-rw-r--r--print/mupdf/patches/patch-aa29
7 files changed, 132 insertions, 0 deletions
diff --git a/print/mupdf/DESCR b/print/mupdf/DESCR
new file mode 100644
index 00000000000..41c10d37924
--- /dev/null
+++ b/print/mupdf/DESCR
@@ -0,0 +1,17 @@
+MuPDF is a lightweight PDF viewer and toolkit written in portable C.
+
+The renderer in MuPDF is tailored for high quality anti-aliased
+graphics. MuPDF renders text with metrics and spacing accurate to
+within fractions of a pixel for the highest fidelity in reproducing
+the look of a printed page on screen.
+
+MuPDF has a small footprint. A binary that includes the standard
+Roman fonts is only one megabyte. A build with full CJK support
+(including an Asian font) is approximately five megabytes.
+
+MuPDF has support for all non-interactive PDF 1.7 features, and
+the toolkit provides a simple API for accessing the internal
+structures of the PDF document. Example code for navigating
+interactive links and bookmarks, encrypting PDF files, extracting
+fonts, images, and searchable text, and rendering pages to image
+files is provided.
diff --git a/print/mupdf/Makefile b/print/mupdf/Makefile
new file mode 100644
index 00000000000..f3d1409db7f
--- /dev/null
+++ b/print/mupdf/Makefile
@@ -0,0 +1,45 @@
+# $NetBSD: Makefile,v 1.1.1.1 2010/02/18 10:07:32 wiz Exp $
+#
+
+DISTNAME= mupdf-r937
+PKGNAME= ${DISTNAME:S/-r/-0.0./}
+CATEGORIES= print
+MASTER_SITES= http://ccxvii.net/mupdf/download/
+
+MAINTAINER= pkgsrc-users@NetBSD.org
+HOMEPAGE= http://ccxvii.net/mupdf/
+COMMENT= Lightweight PDF viewer and toolkit
+LICENSE= gnu-gpl-v3
+
+BUILD_DEPENDS+= jam-[0-9]*:../../devel/jam
+
+PKG_DESTDIR_SUPPORT= user-destdir
+
+USE_TOOLS+= pkg-config
+
+WRKSRC= ${WRKDIR}/mupdf
+MAKE_ENV+= OS=pkgsrc
+MAKE_ENV+= FT=${BUILDLINK_PREFIX.freetype2}
+
+INSTALLATION_DIRS+= bin include lib/pkgconfig share/doc/mupdf
+
+do-build:
+ cd ${WRKSRC} && ${SETENV} ${MAKE_ENV} jam '-sBUILD=release'
+ sed -e "s,@PREFIX@,${PREFIX}," ${FILESDIR}/mupdf.pc > ${WRKSRC}/mupdf.pc
+
+do-install:
+ ${INSTALL_PROGRAM} ${WRKSRC}/build/*/mupdf ${DESTDIR}${PREFIX}/bin
+ ${INSTALL_DATA} ${WRKSRC}/fitz/fitz.h ${DESTDIR}${PREFIX}/include
+ ${INSTALL_DATA} ${WRKSRC}/fitz/fitz_base.h ${DESTDIR}${PREFIX}/include
+ ${INSTALL_DATA} ${WRKSRC}/fitz/fitz_draw.h ${DESTDIR}${PREFIX}/include
+ ${INSTALL_DATA} ${WRKSRC}/fitz/fitz_stream.h ${DESTDIR}${PREFIX}/include
+ ${INSTALL_DATA} ${WRKSRC}/fitz/fitz_tree.h ${DESTDIR}${PREFIX}/include
+ ${INSTALL_DATA} ${WRKSRC}/mupdf/mupdf.h ${DESTDIR}${PREFIX}/include
+ ${INSTALL_LIB} ${WRKSRC}/build/*/libmupdf.a ${DESTDIR}${PREFIX}/lib
+ ${INSTALL_DATA} ${WRKSRC}/mupdf.pc ${DESTDIR}${PREFIX}/lib/pkgconfig
+ ${INSTALL_DATA} ${WRKSRC}/README ${DESTDIR}${PREFIX}/share/doc/mupdf
+
+.include "../../devel/zlib/buildlink3.mk"
+.include "../../graphics/freetype2/buildlink3.mk"
+.include "../../graphics/jpeg/buildlink3.mk"
+.include "../../mk/bsd.pkg.mk"
diff --git a/print/mupdf/PLIST b/print/mupdf/PLIST
new file mode 100644
index 00000000000..e14f8d0149b
--- /dev/null
+++ b/print/mupdf/PLIST
@@ -0,0 +1,11 @@
+@comment $NetBSD: PLIST,v 1.1.1.1 2010/02/18 10:07:32 wiz Exp $
+bin/mupdf
+include/fitz.h
+include/fitz_base.h
+include/fitz_draw.h
+include/fitz_stream.h
+include/fitz_tree.h
+include/mupdf.h
+lib/libmupdf.a
+lib/pkgconfig/mupdf.pc
+share/doc/mupdf/README
diff --git a/print/mupdf/buildlink3.mk b/print/mupdf/buildlink3.mk
new file mode 100644
index 00000000000..050d64cf3d0
--- /dev/null
+++ b/print/mupdf/buildlink3.mk
@@ -0,0 +1,14 @@
+# $NetBSD: buildlink3.mk,v 1.1.1.1 2010/02/18 10:07:32 wiz Exp $
+
+BUILDLINK_TREE+= mupdf
+
+.if !defined(MUPDF_BUILDLINK3_MK)
+MUPDF_BUILDLINK3_MK:=
+
+BUILDLINK_API_DEPENDS.mupdf+= mupdf>=0.0.937
+BUILDLINK_PKGSRCDIR.mupdf?= ../../nih/mupdf
+
+BUILDLINK_DEPMETHOD.mupdf?= build
+.endif # MUPDF_BUILDLINK3_MK
+
+BUILDLINK_TREE+= -mupdf
diff --git a/print/mupdf/distinfo b/print/mupdf/distinfo
new file mode 100644
index 00000000000..bf2a8361b6c
--- /dev/null
+++ b/print/mupdf/distinfo
@@ -0,0 +1,6 @@
+$NetBSD: distinfo,v 1.1.1.1 2010/02/18 10:07:32 wiz Exp $
+
+SHA1 (mupdf-r937.tar.gz) = 757b4070fa70c0942f0031411420df6d4a5fa26c
+RMD160 (mupdf-r937.tar.gz) = 668a7fea2b3857d875726d5b60b00d592d8299de
+Size (mupdf-r937.tar.gz) = 3611931 bytes
+SHA1 (patch-aa) = aa576dfe6591271101ca63cf3cb05c4a1eb90b79
diff --git a/print/mupdf/files/mupdf.pc b/print/mupdf/files/mupdf.pc
new file mode 100644
index 00000000000..1214ef6ba1a
--- /dev/null
+++ b/print/mupdf/files/mupdf.pc
@@ -0,0 +1,10 @@
+prefix=@PREFIX@
+exec_prefix=${prefix}
+libdir=${exec_prefix}/lib
+includedir=${prefix}/include
+
+Name: mupdf
+Description: library for PDF files
+Version: 0.0.937
+Libs: -Wl,-R${libdir} -L${libdir} -lmupdf
+Cflags: -I${includedir}
diff --git a/print/mupdf/patches/patch-aa b/print/mupdf/patches/patch-aa
new file mode 100644
index 00000000000..ff2413f852b
--- /dev/null
+++ b/print/mupdf/patches/patch-aa
@@ -0,0 +1,29 @@
+$NetBSD: patch-aa,v 1.1.1.1 2010/02/18 10:07:32 wiz Exp $
+
+--- Jamrules.orig 2010-01-21 00:27:14.000000000 +0000
++++ Jamrules
+@@ -73,6 +73,24 @@ if $(OS) = LINUX
+ if $(HAVE_OPENJPEG) { LINKLIBS += -lopenjpeg ; }
+ }
+
++if $(OS) = pkgsrc
++{
++ Echo Building for pkgsrc ;
++
++ BUILD_X11APP = true ;
++
++ CCFLAGS = -Wall -std=gnu99 -I${FT}/include/freetype2 -I${PREFIX}/include ;
++ LINKFLAGS = -L${X11BASE}/lib ${COMPILER_RPATH_FLAG}${X11BASE}/lib -L${PREFIX}/lib ${COMPILER_RPATH_FLAG}${PREFIX}/lib ;
++ LINKLIBS = -lfreetype -ljpeg -lz -lm ;
++ APPLINKLIBS = -lX11 -lXext -lpthread ;
++
++ if $(BUILD) = debug { OPTIM = -g -O0 -fno-inline ; }
++ if $(BUILD) = release { OPTIM = -O3 ; }
++
++ if $(HAVE_JBIG2DEC) { LINKLIBS += -ljbig2dec ; }
++ if $(HAVE_OPENJPEG) { LINKLIBS += -lopenjpeg ; }
++}
++
+ if $(OS) = MACOSX
+ {
+ Echo Building for MACOSX ;