| @@ -1,110 +1,111 @@ | | | @@ -1,110 +1,111 @@ |
1 | # $NetBSD: Makefile,v 1.96 2013/03/13 09:37:11 adam Exp $ | | 1 | # $NetBSD: Makefile,v 1.97 2013/03/14 05:34:35 dholland Exp $ |
2 | | | 2 | |
3 | DISTNAME= ghostscript-${GS_VERSION} | | 3 | DISTNAME= ghostscript-${GS_VERSION} |
| | | 4 | PKGREVISION= 1 |
4 | CATEGORIES= print | | 5 | CATEGORIES= print |
5 | MASTER_SITES= ${MASTER_SITE_SOURCEFORGE:=ghostscript/} | | 6 | MASTER_SITES= ${MASTER_SITE_SOURCEFORGE:=ghostscript/} |
6 | MASTER_SITES+= http://ghostscript.com/releases/ | | 7 | MASTER_SITES+= http://ghostscript.com/releases/ |
7 | EXTRACT_SUFX= .tar.bz2 | | 8 | EXTRACT_SUFX= .tar.bz2 |
8 | | | 9 | |
9 | MAINTAINER= pkgsrc-users@NetBSD.org | | 10 | MAINTAINER= pkgsrc-users@NetBSD.org |
10 | HOMEPAGE= http://ghostscript.sourceforge.net/ | | 11 | HOMEPAGE= http://ghostscript.sourceforge.net/ |
11 | COMMENT= Postscript interpreter | | 12 | COMMENT= Postscript interpreter |
12 | | | 13 | |
13 | # Plus adobe verbatim for Resources/CMap. | | 14 | # Plus adobe verbatim for Resources/CMap. |
14 | LICENSE= gnu-agpl-v3 | | 15 | LICENSE= gnu-agpl-v3 |
15 | | | 16 | |
16 | .include "Makefile.common" | | 17 | .include "Makefile.common" |
17 | | | 18 | |
18 | DEPENDS+= ghostscript-fonts>=6.0:../../fonts/ghostscript-fonts | | 19 | DEPENDS+= ghostscript-fonts>=6.0:../../fonts/ghostscript-fonts |
19 | | | 20 | |
20 | CONFLICTS+= ghostscript-afpl-[0-9]* | | 21 | CONFLICTS+= ghostscript-afpl-[0-9]* |
21 | CONFLICTS+= ghostscript-esp{,-nox11}-[0-9]* | | 22 | CONFLICTS+= ghostscript-esp{,-nox11}-[0-9]* |
22 | CONFLICTS+= ghostscript-gnu{,-nox11,-x11}-[0-9]* | | 23 | CONFLICTS+= ghostscript-gnu{,-nox11,-x11}-[0-9]* |
23 | | | 24 | |
24 | USE_LANGUAGES+= c c++ | | 25 | USE_LANGUAGES+= c c++ |
25 | USE_TOOLS+= gmake perl:run lex pkg-config | | 26 | USE_TOOLS+= gmake perl:run lex pkg-config |
26 | GNU_CONFIGURE= yes | | 27 | GNU_CONFIGURE= yes |
27 | CONFIGURE_ARGS+= --with-system-libtiff | | 28 | CONFIGURE_ARGS+= --with-system-libtiff |
28 | UNLIMIT_RESOURCES+= datasize # gsromfs1.c | | 29 | UNLIMIT_RESOURCES+= datasize # gsromfs1.c |
29 | | | 30 | |
30 | BUILD_TARGET= so | | 31 | BUILD_TARGET= so |
31 | INSTALL_TARGET= soinstall | | 32 | INSTALL_TARGET= soinstall |
32 | CONFIGURE_ARGS+= -with-omni=no # otherwise pulls in libstdc++ | | 33 | CONFIGURE_ARGS+= -with-omni=no # otherwise pulls in libstdc++ |
33 | | | 34 | |
34 | REPLACE_PERL+= toolbin/localcluster/clusterpush.pl | | 35 | REPLACE_PERL+= toolbin/localcluster/clusterpush.pl |
35 | REPLACE_PERL+= toolbin/checkdeps.pl | | 36 | REPLACE_PERL+= toolbin/checkdeps.pl |
36 | REPLACE_PERL+= toolbin/pscet_status.pl | | 37 | REPLACE_PERL+= toolbin/pscet_status.pl |
37 | REPLACE_PERL+= toolbin/performance.pl | | 38 | REPLACE_PERL+= toolbin/performance.pl |
38 | REPLACE_PERL+= toolbin/squeeze2html.pl | | 39 | REPLACE_PERL+= toolbin/squeeze2html.pl |
39 | REPLACE_PERL+= toolbin/bugsByEngineer.pl | | 40 | REPLACE_PERL+= toolbin/bugsByEngineer.pl |
40 | REPLACE_PERL+= toolbin/htmldiff.pl | | 41 | REPLACE_PERL+= toolbin/htmldiff.pl |
41 | | | 42 | |
42 | GS_RESOURCEDIR= ${PREFIX}/share/ghostscript/${PKGVERSION}/Resource | | 43 | GS_RESOURCEDIR= ${PREFIX}/share/ghostscript/${PKGVERSION}/Resource |
43 | # MESSAGE file substitution | | 44 | # MESSAGE file substitution |
44 | MESSAGE_SUBST+= GS_RESOURCEDIR=${GS_RESOURCEDIR} | | 45 | MESSAGE_SUBST+= GS_RESOURCEDIR=${GS_RESOURCEDIR} |
45 | | | 46 | |
46 | # XXX make sure the local jpeg headers are found before those pulled | | 47 | # XXX make sure the local jpeg headers are found before those pulled |
47 | # in indirectly by cups bl3 | | 48 | # in indirectly by cups bl3 |
48 | CPPFLAGS+= -Ijpeg | | 49 | CPPFLAGS+= -Ijpeg |
49 | | | 50 | |
50 | .include "../../mk/bsd.prefs.mk" | | 51 | .include "../../mk/bsd.prefs.mk" |
51 | .include "../../mk/compiler.mk" | | 52 | .include "../../mk/compiler.mk" |
52 | | | 53 | |
53 | .if defined(PAPERSIZE) && (${PAPERSIZE} == "A4" || ${PAPERSIZE} == "a4") | | 54 | .if defined(PAPERSIZE) && (${PAPERSIZE} == "A4" || ${PAPERSIZE} == "a4") |
54 | CFLAGS+= -DA4 | | 55 | CFLAGS+= -DA4 |
55 | .endif | | 56 | .endif |
56 | | | 57 | |
57 | REQD_DIRS+= share/ghostscript | | 58 | REQD_DIRS+= share/ghostscript |
58 | | | 59 | |
59 | SUBST_CLASSES+= resdir | | 60 | SUBST_CLASSES+= resdir |
60 | SUBST_STAGE.resdir= post-extract | | 61 | SUBST_STAGE.resdir= post-extract |
61 | SUBST_MESSAGE.resdir= Fixing resource directory path | | 62 | SUBST_MESSAGE.resdir= Fixing resource directory path |
62 | SUBST_FILES.resdir= Resource/Init/gs_res.ps | | 63 | SUBST_FILES.resdir= Resource/Init/gs_res.ps |
63 | SUBST_SED.resdir= -e "s|/Resource/|${GS_RESOURCEDIR}/|g" | | 64 | SUBST_SED.resdir= -e "s|/Resource/|${GS_RESOURCEDIR}/|g" |
64 | | | 65 | |
65 | .if ${OPSYS} == "HPUX" | | 66 | .if ${OPSYS} == "HPUX" |
66 | CONFIGURE_ENV+= ac_cv_func_fopen64=no | | 67 | CONFIGURE_ENV+= ac_cv_func_fopen64=no |
67 | .endif | | 68 | .endif |
68 | | | 69 | |
69 | # On Linux-*-x86_64, there was an error message: | | 70 | # On Linux-*-x86_64, there was an error message: |
70 | # gp_unix.o: relocation R_X86_64_32 against `a local symbol' can not be | | 71 | # gp_unix.o: relocation R_X86_64_32 against `a local symbol' can not be |
71 | # used when making a shared object; recompile with -fPIC | | 72 | # used when making a shared object; recompile with -fPIC |
72 | .if !empty(PKGSRC_COMPILER:Mgcc) || !empty(PKGSRC_COMPILER:Mclang) | | 73 | .if !empty(PKGSRC_COMPILER:Mgcc) || !empty(PKGSRC_COMPILER:Mclang) |
73 | CFLAGS+= -fPIC | | 74 | CFLAGS+= -fPIC |
74 | .endif | | 75 | .endif |
75 | | | 76 | |
76 | # Interim IRIX build fix, the real problem is that fontconfig.pc doesn't | | 77 | # Interim IRIX build fix, the real problem is that fontconfig.pc doesn't |
77 | # require linking against libiconv when it should do so. | | 78 | # require linking against libiconv when it should do so. |
78 | .if ${OPSYS} == "IRIX" | | 79 | .if ${OPSYS} == "IRIX" |
79 | BUILDLINK_TRANSFORM+= l:fontconfig:fontconfig:iconv | | 80 | BUILDLINK_TRANSFORM+= l:fontconfig:fontconfig:iconv |
80 | .endif | | 81 | .endif |
81 | | | 82 | |
82 | CONFIGURE_ENV+= LPLIBDIR=${PREFIX}/lib | | 83 | CONFIGURE_ENV+= LPLIBDIR=${PREFIX}/lib |
83 | | | 84 | |
84 | .include "options.mk" | | 85 | .include "options.mk" |
85 | | | 86 | |
86 | post-extract: | | 87 | post-extract: |
87 | ${MKDIR} ${WRKSRC}/bin | | 88 | ${MKDIR} ${WRKSRC}/bin |
88 | ${MKDIR} ${WRKSRC}/obj | | 89 | ${MKDIR} ${WRKSRC}/obj |
89 | ${RM} -rf ${WRKSRC}/freetype | | 90 | ${RM} -rf ${WRKSRC}/freetype |
90 | ${RM} -rf ${WRKSRC}/jpeg | | 91 | ${RM} -rf ${WRKSRC}/jpeg |
91 | # ${RM} -rf ${WRKSRC}/lcms2 | | 92 | # ${RM} -rf ${WRKSRC}/lcms2 |
92 | ${RM} -rf ${WRKSRC}/libpng | | 93 | ${RM} -rf ${WRKSRC}/libpng |
93 | ${RM} -rf ${WRKSRC}/zlib | | 94 | ${RM} -rf ${WRKSRC}/zlib |
94 | | | 95 | |
95 | # To allow outside customization, rename cidfmap | | 96 | # To allow outside customization, rename cidfmap |
96 | # (if you look at inside of the file, it is logically empty) | | 97 | # (if you look at inside of the file, it is logically empty) |
97 | .if !empty(PKG_OPTIONS:Mdisable-compile-inits) | | 98 | .if !empty(PKG_OPTIONS:Mdisable-compile-inits) |
98 | (cd ${WRKSRC}/Resource/Init/; ${MV} cidfmap cidfmap.dist) | | 99 | (cd ${WRKSRC}/Resource/Init/; ${MV} cidfmap cidfmap.dist) |
99 | .endif | | 100 | .endif |
100 | | | 101 | |
101 | post-install: | | 102 | post-install: |
102 | ${LN} -sf gsc ${DESTDIR}${PREFIX}/bin/gs | | 103 | ${LN} -sf gsc ${DESTDIR}${PREFIX}/bin/gs |
103 | | | 104 | |
104 | .include "../../devel/zlib/buildlink3.mk" | | 105 | .include "../../devel/zlib/buildlink3.mk" |
105 | .include "../../graphics/freetype2/buildlink3.mk" | | 106 | .include "../../graphics/freetype2/buildlink3.mk" |
106 | #.include "../../graphics/lcms2/buildlink3.mk" | | 107 | #.include "../../graphics/lcms2/buildlink3.mk" |
107 | .include "../../graphics/png/buildlink3.mk" | | 108 | .include "../../graphics/png/buildlink3.mk" |
108 | .include "../../graphics/tiff/buildlink3.mk" | | 109 | .include "../../graphics/tiff/buildlink3.mk" |
109 | .include "../../print/libpaper/buildlink3.mk" | | 110 | .include "../../print/libpaper/buildlink3.mk" |
110 | .include "../../mk/bsd.pkg.mk" | | 111 | .include "../../mk/bsd.pkg.mk" |