diff --git a/graphics/xpdf/Makefile b/graphics/xpdf/Makefile index 59d19a35b810..55b3f9d49233 100644 --- a/graphics/xpdf/Makefile +++ b/graphics/xpdf/Makefile @@ -25,15 +25,12 @@ LIB_DEPENDS= t1.5:${PORTSDIR}/devel/t1lib \ freetype.9:${PORTSDIR}/print/freetype2 RUN_DEPENDS= ${LOCALBASE}/share/ghostscript/fonts/n021003l.pfb:${PORTSDIR}/print/gsfonts -USE_X_PREFIX= yes -USE_MOTIF= yes - USE_GMAKE= yes USE_AUTOTOOLS= autoconf:259 CONFIGURE_TARGET= --build=${MACHINE_ARCH}-portbld-freebsd${OSREL} CONFIGURE_ENV= CPPFLAGS="-I${LOCALBASE}/include" \ LDFLAGS="-L${LOCALBASE}/lib" -CONFIGURE_ARGS= --with-gzip --enable-opi --with-x \ +CONFIGURE_ARGS= --with-gzip --enable-opi \ --with-t1-library="${LOCALBASE}/lib" \ --with-t1-includes="${LOCALBASE}/include" \ --with-freetype2-library="${LOCALBASE}/lib" \ @@ -47,10 +44,21 @@ MAN1= pdffonts.1 \ pdfinfo.1 \ pdftoppm.1 \ pdftops.1 \ - pdftotext.1 \ - xpdf.1 + pdftotext.1 MAN5= xpdfrc.5 +.if defined(WITHOUT_X11) +PKGNAMESUFFIX+= -nox11 +CONFIGURE_ARGS+= --without-x +PLIST_SUB+= X11='@comment ' +.else +CONFIGURE_ARGS+= --with-x +USE_X_PREFIX= yes +USE_MOTIF= yes +MAN1+= xpdf.1 +PLIST_SUB+= X11='' +.endif + post-install: .if !defined(NOPORTDOCS) @${MKDIR} ${DOCSDIR} diff --git a/graphics/xpdf/files/patch-Makefile.in b/graphics/xpdf/files/patch-Makefile.in new file mode 100644 index 000000000000..f80b065c109d --- /dev/null +++ b/graphics/xpdf/files/patch-Makefile.in @@ -0,0 +1,20 @@ +--- Makefile.in.orig Thu Dec 1 17:04:10 2005 ++++ Makefile.in Thu Dec 1 17:04:31 2005 +@@ -82,7 +82,7 @@ + $(INSTALL_PROGRAM) xpdf/pdftotext$(EXE) $(DESTDIR)@bindir@/pdftotext$(EXE) + $(INSTALL_PROGRAM) xpdf/pdfinfo$(EXE) $(DESTDIR)@bindir@/pdfinfo$(EXE) + $(INSTALL_PROGRAM) xpdf/pdffonts$(EXE) $(DESTDIR)@bindir@/pdffonts$(EXE) +-@X@ $(INSTALL_PROGRAM) xpdf/pdftoppm$(EXE) $(DESTDIR)@bindir@/pdftoppm$(EXE) ++ $(INSTALL_PROGRAM) xpdf/pdftoppm$(EXE) $(DESTDIR)@bindir@/pdftoppm$(EXE) + $(INSTALL_PROGRAM) xpdf/pdfimages$(EXE) $(DESTDIR)@bindir@/pdfimages$(EXE) + -mkdir -p $(DESTDIR)@mandir@/man1 + @X@ $(INSTALL_DATA) $(srcdir)/doc/xpdf.1 $(DESTDIR)@mandir@/man1/xpdf.1 +@@ -90,7 +90,7 @@ + $(INSTALL_DATA) $(srcdir)/doc/pdftotext.1 $(DESTDIR)@mandir@/man1/pdftotext.1 + $(INSTALL_DATA) $(srcdir)/doc/pdfinfo.1 $(DESTDIR)@mandir@/man1/pdfinfo.1 + $(INSTALL_DATA) $(srcdir)/doc/pdffonts.1 $(DESTDIR)@mandir@/man1/pdffonts.1 +-@X@ $(INSTALL_DATA) $(srcdir)/doc/pdftoppm.1 $(DESTDIR)@mandir@/man1/pdftoppm.1 ++ $(INSTALL_DATA) $(srcdir)/doc/pdftoppm.1 $(DESTDIR)@mandir@/man1/pdftoppm.1 + $(INSTALL_DATA) $(srcdir)/doc/pdfimages.1 $(DESTDIR)@mandir@/man1/pdfimages.1 + -mkdir -p $(DESTDIR)@mandir@/man5 + $(INSTALL_DATA) $(srcdir)/doc/xpdfrc.5 $(DESTDIR)@mandir@/man5/xpdfrc.5 diff --git a/graphics/xpdf/files/patch-configure b/graphics/xpdf/files/patch-configure new file mode 100644 index 000000000000..934043de6972 --- /dev/null +++ b/graphics/xpdf/files/patch-configure @@ -0,0 +1,15 @@ +--- configure.orig Thu Dec 1 17:06:03 2005 ++++ configure Thu Dec 1 17:06:25 2005 +@@ -11776,8 +11776,8 @@ + { echo "$as_me:$LINENO: WARNING: Couldn't find FreeType" >&5 + echo "$as_me: WARNING: Couldn't find FreeType" >&2;}; + fi +- { echo "$as_me:$LINENO: WARNING: -- You will be able to compile pdftops, pdftotext, +- pdfinfo, pdffonts, and pdfimages, but not xpdf or pdftoppm" >&5 +-echo "$as_me: WARNING: -- You will be able to compile pdftops, pdftotext, +- pdfinfo, pdffonts, and pdfimages, but not xpdf or pdftoppm" >&2;} ++ { echo "$as_me:$LINENO: WARNING: -- You will be able to compile pdftoppm, pdftops, pdftotext, ++ pdfinfo, pdffonts, and pdfimages, but not xpdf" >&5 ++echo "$as_me: WARNING: -- You will be able to compile pdftoppm, pdftops, pdftotext, ++ pdfinfo, pdffonts, and pdfimages, but not xpdf" >&2;} + fi diff --git a/graphics/xpdf/files/patch-configure.in b/graphics/xpdf/files/patch-configure.in new file mode 100644 index 000000000000..9af9af0fa657 --- /dev/null +++ b/graphics/xpdf/files/patch-configure.in @@ -0,0 +1,11 @@ +--- configure.in.orig Thu Dec 1 17:05:11 2005 ++++ configure.in Thu Dec 1 17:05:25 2005 +@@ -341,6 +341,6 @@ + if test "x$smr_have_freetype2_library" != xyes; then + AC_MSG_WARN([Couldn't find FreeType]); + fi +- AC_MSG_WARN([-- You will be able to compile pdftops, pdftotext, +- pdfinfo, pdffonts, and pdfimages, but not xpdf or pdftoppm]) ++ AC_MSG_WARN([-- You will be able to compile pdftoppm, pdftops, pdftotext, ++ pdfinfo, pdffonts, and pdfimages, but not xpdf]) + fi diff --git a/graphics/xpdf/files/patch-xpdf::Makefile.in b/graphics/xpdf/files/patch-xpdf::Makefile.in new file mode 100644 index 000000000000..38859e5e6bfa --- /dev/null +++ b/graphics/xpdf/files/patch-xpdf::Makefile.in @@ -0,0 +1,11 @@ +--- xpdf/Makefile.in.orig Thu Dec 1 17:10:20 2005 ++++ xpdf/Makefile.in Thu Dec 1 17:10:34 2005 +@@ -109,7 +109,7 @@ + pdffonts$(EXE) pdftoppm$(EXE) pdfimages$(EXE) + + all-no-x: pdftops$(EXE) pdftotext$(EXE) pdfinfo$(EXE) pdffonts$(EXE) \ +- pdfimages$(EXE) ++ pdftoppm$(EXE) pdfimages$(EXE) + + #------------------------------------------------------------------------ + diff --git a/graphics/xpdf/pkg-plist b/graphics/xpdf/pkg-plist index ba887c6b2e00..9ea6607410e2 100644 --- a/graphics/xpdf/pkg-plist +++ b/graphics/xpdf/pkg-plist @@ -4,7 +4,7 @@ bin/pdfinfo bin/pdftoppm bin/pdftops bin/pdftotext -bin/xpdf +%%X11%%bin/xpdf etc/xpdfrc %%PORTDOCS%%%%DOCSDIR%%/ANNOUNCE %%PORTDOCS%%%%DOCSDIR%%/CHANGES