Here's a patch to build xpdf against xenocara, handling Freetype 2.2.x changes.

Note that because the Freetype people didn't care about backward compatibility, this won't work with Freetype 2.1.9 as currently found in XF4.

--
Matthieu Herrb
Index: Makefile
===================================================================
RCS file: /cvs/OpenBSD/ports/textproc/xpdf/Makefile,v
retrieving revision 1.53
diff -u -r1.53 Makefile
--- Makefile    3 Aug 2006 23:55:11 -0000       1.53
+++ Makefile    6 Jan 2007 18:48:06 -0000
@@ -3,10 +3,11 @@
 COMMENT=       "PDF viewer for X"
 
 DISTNAME=      xpdf-3.01
-PKGNAME=       ${DISTNAME}p1
+PKGNAME=       ${DISTNAME}p2
 CATEGORIES=    textproc x11
 
 MASTER_SITES=  ftp://ftp.foolabs.com/pub/xpdf/
+MASTER_SITES0= http://freetype.sourceforge.net/freetype2/patches/
 
 HOMEPAGE=      http://www.foolabs.com/xpdf/
 
@@ -22,6 +23,10 @@
 PERMIT_DISTFILES_FTP=  Yes
 WANTLIB=               ICE SM X11 Xext Xp Xpm Xt c freetype m pthread \
                        stdc++ 
+
+PATCHFILES=            xpdf-3.01-noftinternals.patch:0
+PATCH_DIST_STRIP=      -p1
+
 
 USE_X11=       Yes
 USE_GMAKE=     Yes
Index: distinfo
===================================================================
RCS file: /cvs/OpenBSD/ports/textproc/xpdf/distinfo,v
retrieving revision 1.9
diff -u -r1.9 distinfo
--- distinfo    9 Sep 2005 17:34:53 -0000       1.9
+++ distinfo    6 Jan 2007 18:48:06 -0000
@@ -1,4 +1,8 @@
+MD5 (xpdf-3.01-noftinternals.patch) = 6acd0925240e9b7e7f917cd6cf28ab61
 MD5 (xpdf-3.01.tar.gz) = e004c69c7dddef165d768b1362b44268
+RMD160 (xpdf-3.01-noftinternals.patch) = 
3e7a8a04cf5ad8a154f7708107a2821bd197c1d3
 RMD160 (xpdf-3.01.tar.gz) = d734065ce12db8d0c37d9d0ac0ca7c287be59442
+SHA1 (xpdf-3.01-noftinternals.patch) = d7227a6f41de7a12ebb1eb55c5566cd5e5e5358c
 SHA1 (xpdf-3.01.tar.gz) = 472cbf0f3df4e20a3ab7ada2e704b4e10d1d385b
+SIZE (xpdf-3.01-noftinternals.patch) = 2772
 SIZE (xpdf-3.01.tar.gz) = 599778
Index: patches/patch-configure_in
===================================================================
RCS file: patches/patch-configure_in
diff -N patches/patch-configure_in
--- /dev/null   1 Jan 1970 00:00:00 -0000
+++ patches/patch-configure_in  6 Jan 2007 18:48:06 -0000
@@ -0,0 +1,11 @@
+--- configure.in.orig  Wed Aug 17 07:34:30 2005
++++ configure.in       Sat Jan  6 19:34:08 2007
+@@ -304,7 +304,7 @@ dnl ##### Check for FreeType 2.x.
+ dnl ##### (Note: FT_Get_Name_Index was added in FT 2.0.5, and is
+ dnl ##### the reason that Xpdf requires 2.0.5+.)
+ smr_CHECK_LIB(freetype2, freetype, [FreeType2 font rasterizer - version 
2.0.5+],
+-              FT_Get_Name_Index, ft2build.h, -lm)
++              FT_Get_Name_Index, ft2build.h, -lm -lz)
+ AC_SUBST(freetype2_LIBS)
+ AC_SUBST(freetype2_CFLAGS)
+ if test "x$smr_have_freetype2_library" = xyes; then
Index: patches/patch-xpdf_Makefile_in
===================================================================
RCS file: /cvs/OpenBSD/ports/textproc/xpdf/patches/patch-xpdf_Makefile_in,v
retrieving revision 1.5
diff -u -r1.5 patch-xpdf_Makefile_in
--- patches/patch-xpdf_Makefile_in      25 Jan 2004 06:02:40 -0000      1.5
+++ patches/patch-xpdf_Makefile_in      6 Jan 2007 18:48:06 -0000
@@ -1,6 +1,6 @@
 $OpenBSD: patch-xpdf_Makefile_in,v 1.5 2004/01/25 06:02:40 brad Exp $
---- xpdf/Makefile.in.orig      2004-01-21 20:26:45.000000000 -0500
-+++ xpdf/Makefile.in   2004-01-24 23:55:40.000000000 -0500
+--- xpdf/Makefile.in.orig      Wed Aug 17 07:34:31 2005
++++ xpdf/Makefile.in   Sat Jan  6 19:44:49 2007
 @@ -19,7 +19,7 @@ FOFILIBDIR = ../fofi
  SPLASHSRCDIR = $(srcdir)/../splash
  SPLASHLIBDIR = ../splash
@@ -19,3 +19,21 @@
  
  CXX = @CXX@
  
+@@ -124,7 +124,7 @@ XPDF_OBJS = Annot.o Array.o BuiltinFont.
+       XPDFCore.o XPDFTree.o XPDFViewer.o XpdfPluginAPI.o XRef.o \
+       xpdf.o
+ XPDF_LIBS = -L$(GOOLIBDIR) -lGoo $(SPLASHLIBS) $(T1LIBS) $(FTLIBS) \
+-      $(XLIBS) $(OTHERLIBS) -lm
++      $(XLIBS) $(OTHERLIBS) -lm -lz
+ 
+ xpdf$(EXE): $(XPDF_OBJS) $(GOOLIBDIR)/$(LIBPREFIX)Goo.a
+       $(CXX) $(CXXFLAGS) $(LDFLAGS) -o xpdf$(EXE) $(XPDF_OBJS) $(XPDF_LIBS)
+@@ -204,7 +204,7 @@ PDFTOPPM_OBJS = Annot.o Array.o BuiltinF
+       SecurityHandler.o SplashOutputDev.o Stream.o TextOutputDev.o \
+       UnicodeMap.o UnicodeTypeTable.o XpdfPluginAPI.o XRef.o pdftoppm.o
+ PDFTOPPM_LIBS = -L$(GOOLIBDIR) -lGoo $(SPLASHLIBS) $(T1LIBS) $(FTLIBS) \
+-      $(OTHERLIBS) -lm
++      $(OTHERLIBS) -lm -lz
+ 
+ pdftoppm$(EXE): $(PDFTOPPM_OBJS) $(GOOLIBDIR)/$(LIBPREFIX)Goo.a
+       $(CXX) $(CXXFLAGS) $(LDFLAGS) -o pdftoppm$(EXE) $(PDFTOPPM_OBJS) \

Reply via email to