Mon Jan 6 07:23:26 2020 UTC ()
(print/ghostscript-agpl) Delete garbage from DESTDIR


(mef)
diff -r1.49 -r1.50 pkgsrc/print/ghostscript-agpl/Makefile

cvs diff -r1.49 -r1.50 pkgsrc/print/ghostscript-agpl/Makefile (switch to unified diff)

--- pkgsrc/print/ghostscript-agpl/Makefile 2020/01/03 23:56:09 1.49
+++ pkgsrc/print/ghostscript-agpl/Makefile 2020/01/06 07:23:26 1.50
@@ -1,124 +1,125 @@ @@ -1,124 +1,125 @@
1# $NetBSD: Makefile,v 1.49 2020/01/03 23:56:09 sevan Exp $ 1# $NetBSD: Makefile,v 1.50 2020/01/06 07:23:26 mef Exp $
2 2
3DISTNAME= ghostscript-${GS_VERSION} 3DISTNAME= ghostscript-${GS_VERSION}
4PKGNAME= ${DISTNAME:S/ghostscript/ghostscript-agpl/} 4PKGNAME= ${DISTNAME:S/ghostscript/ghostscript-agpl/}
5PKGREVISION= 2 5PKGREVISION= 2
6CATEGORIES= print 6CATEGORIES= print
7MASTER_SITES= ${MASTER_SITE_GITHUB:=ArtifexSoftware/} 7MASTER_SITES= ${MASTER_SITE_GITHUB:=ArtifexSoftware/}
8GITHUB_PROJECT= ghostpdl-downloads 8GITHUB_PROJECT= ghostpdl-downloads
9GITHUB_RELEASE= gs${GS_VERSION:S/.//} 9GITHUB_RELEASE= gs${GS_VERSION:S/.//}
10EXTRACT_SUFX= .tar.xz 10EXTRACT_SUFX= .tar.xz
11 11
12MAINTAINER= pkgsrc-users@NetBSD.org 12MAINTAINER= pkgsrc-users@NetBSD.org
13HOMEPAGE= https://ghostscript.com/ 13HOMEPAGE= https://ghostscript.com/
14COMMENT= Postscript interpreter 14COMMENT= Postscript interpreter
15 15
16# Upstream calls this "GPL Ghostscript", which is confusing; 16# Upstream calls this "GPL Ghostscript", which is confusing;
17# see https://bugs.ghostscript.com/show_bug.cgi?id=700877 17# see https://bugs.ghostscript.com/show_bug.cgi?id=700877
18# Plus adobe verbatim for Resources/CMap. 18# Plus adobe verbatim for Resources/CMap.
19LICENSE= gnu-agpl-v3 19LICENSE= gnu-agpl-v3
20 20
21.include "Makefile.common" 21.include "Makefile.common"
22 22
23DEPENDS+= ghostscript-fonts>=6.0:../../fonts/ghostscript-fonts 23DEPENDS+= ghostscript-fonts>=6.0:../../fonts/ghostscript-fonts
24 24
25USE_LANGUAGES+= c c++ 25USE_LANGUAGES+= c c++
26USE_TOOLS+= gmake perl:run lex pkg-config 26USE_TOOLS+= gmake perl:run lex pkg-config
27GNU_CONFIGURE= yes 27GNU_CONFIGURE= yes
28UNLIMIT_RESOURCES+= datasize # gsromfs1.c 28UNLIMIT_RESOURCES+= datasize # gsromfs1.c
29 29
30BUILD_TARGET= so 30BUILD_TARGET= so
31INSTALL_TARGET= soinstall 31INSTALL_TARGET= soinstall
32 32
33CONFIGURE_ARGS+= --enable-openjpeg 33CONFIGURE_ARGS+= --enable-openjpeg
34CONFIGURE_ARGS+= --with-system-libtiff 34CONFIGURE_ARGS+= --with-system-libtiff
35CONFIGURE_ENV+= LPLIBDIR=${PREFIX}/lib 35CONFIGURE_ENV+= LPLIBDIR=${PREFIX}/lib
36CONFIGURE_ENV.HPUX+= ac_cv_func_fopen64=no 36CONFIGURE_ENV.HPUX+= ac_cv_func_fopen64=no
37 37
38REPLACE_PERL+= toolbin/localcluster/clusterpush.pl 38REPLACE_PERL+= toolbin/localcluster/clusterpush.pl
39REPLACE_PERL+= toolbin/checkdeps.pl 39REPLACE_PERL+= toolbin/checkdeps.pl
40REPLACE_PERL+= toolbin/pscet_status.pl 40REPLACE_PERL+= toolbin/pscet_status.pl
41REPLACE_PERL+= toolbin/performance.pl 41REPLACE_PERL+= toolbin/performance.pl
42REPLACE_PERL+= toolbin/squeeze2html.pl 42REPLACE_PERL+= toolbin/squeeze2html.pl
43REPLACE_PERL+= toolbin/bugsByEngineer.pl 43REPLACE_PERL+= toolbin/bugsByEngineer.pl
44REPLACE_PERL+= toolbin/htmldiff.pl 44REPLACE_PERL+= toolbin/htmldiff.pl
45 45
46GS_RESOURCEDIR= ${PREFIX}/share/ghostscript/${PKGVERSION}/Resource 46GS_RESOURCEDIR= ${PREFIX}/share/ghostscript/${PKGVERSION}/Resource
47# MESSAGE file substitution 47# MESSAGE file substitution
48MESSAGE_SUBST+= GS_RESOURCEDIR=${GS_RESOURCEDIR} 48MESSAGE_SUBST+= GS_RESOURCEDIR=${GS_RESOURCEDIR}
49 49
50.include "../../mk/bsd.prefs.mk" 50.include "../../mk/bsd.prefs.mk"
51.include "../../mk/compiler.mk" 51.include "../../mk/compiler.mk"
52 52
53# \todo Remove "a4" as that is not valid according to pkglint. 53# \todo Remove "a4" as that is not valid according to pkglint.
54.if defined(PAPERSIZE) && (${PAPERSIZE} == "A4" || ${PAPERSIZE} == "a4") 54.if defined(PAPERSIZE) && (${PAPERSIZE} == "A4" || ${PAPERSIZE} == "a4")
55BUILD_DEFS+= PAPERSIZE 55BUILD_DEFS+= PAPERSIZE
56CFLAGS+= -DA4 56CFLAGS+= -DA4
57.endif 57.endif
58 58
59REQD_DIRS+= share/ghostscript 59REQD_DIRS+= share/ghostscript
60 60
61SUBST_CLASSES+= resdir 61SUBST_CLASSES+= resdir
62SUBST_STAGE.resdir= post-extract 62SUBST_STAGE.resdir= post-extract
63SUBST_MESSAGE.resdir= Fixing resource directory path 63SUBST_MESSAGE.resdir= Fixing resource directory path
64SUBST_FILES.resdir= Resource/Init/gs_res.ps 64SUBST_FILES.resdir= Resource/Init/gs_res.ps
65SUBST_SED.resdir= -e "s|/Resource/|${GS_RESOURCEDIR}/|g" 65SUBST_SED.resdir= -e "s|/Resource/|${GS_RESOURCEDIR}/|g"
66 66
67# On Linux-*-x86_64, there was an error message: 67# On Linux-*-x86_64, there was an error message:
68# gp_unix.o: relocation R_X86_64_32 against `a local symbol' can not be 68# gp_unix.o: relocation R_X86_64_32 against `a local symbol' can not be
69# used when making a shared object; recompile with -fPIC 69# used when making a shared object; recompile with -fPIC
70.if !empty(PKGSRC_COMPILER:Mgcc) || !empty(PKGSRC_COMPILER:Mclang) 70.if !empty(PKGSRC_COMPILER:Mgcc) || !empty(PKGSRC_COMPILER:Mclang)
71CFLAGS+= -fPIC 71CFLAGS+= -fPIC
72.endif 72.endif
73 73
74# Not ideal but too many files hardcode _XOPEN_SOURCE=500. 74# Not ideal but too many files hardcode _XOPEN_SOURCE=500.
75.if !empty(CC_VERSION:Mgcc-[6-9]*) || !empty(PKGSRC_COMPILER:Mclang) 75.if !empty(CC_VERSION:Mgcc-[6-9]*) || !empty(PKGSRC_COMPILER:Mclang)
76CPPFLAGS.SunOS+= -D_XOPEN_SOURCE=600 -D__EXTENSIONS__ 76CPPFLAGS.SunOS+= -D_XOPEN_SOURCE=600 -D__EXTENSIONS__
77.else 77.else
78CPPFLAGS.SunOS+= -D__C99FEATURES__ 78CPPFLAGS.SunOS+= -D__C99FEATURES__
79.endif 79.endif
80 80
81# Interim IRIX build fix, the real problem is that fontconfig.pc doesn't 81# Interim IRIX build fix, the real problem is that fontconfig.pc doesn't
82# require linking against libiconv when it should do so. 82# require linking against libiconv when it should do so.
83BUILDLINK_TRANSFORM.IRIX+= l:fontconfig:fontconfig:iconv 83BUILDLINK_TRANSFORM.IRIX+= l:fontconfig:fontconfig:iconv
84 84
85.include "options.mk" 85.include "options.mk"
86 86
87post-extract: 87post-extract:
88 ${MKDIR} ${WRKSRC}/bin 88 ${MKDIR} ${WRKSRC}/bin
89 ${MKDIR} ${WRKSRC}/obj 89 ${MKDIR} ${WRKSRC}/obj
90 ${RM} -rf ${WRKSRC}/freetype 90 ${RM} -rf ${WRKSRC}/freetype
91 ${RM} -rf ${WRKSRC}/jbig2dec 91 ${RM} -rf ${WRKSRC}/jbig2dec
92 ${RM} -rf ${WRKSRC}/jpeg 92 ${RM} -rf ${WRKSRC}/jpeg
93 ${RM} -rf ${WRKSRC}/lcms2 93 ${RM} -rf ${WRKSRC}/lcms2
94 ${RM} -rf ${WRKSRC}/lcms2mt 94 ${RM} -rf ${WRKSRC}/lcms2mt
95 ${RM} -rf ${WRKSRC}/libpng 95 ${RM} -rf ${WRKSRC}/libpng
96 ${RM} -rf ${WRKSRC}/openjpeg 96 ${RM} -rf ${WRKSRC}/openjpeg
97 ${RM} -rf ${WRKSRC}/tiff 97 ${RM} -rf ${WRKSRC}/tiff
98 ${RM} -rf ${WRKSRC}/zlib 98 ${RM} -rf ${WRKSRC}/zlib
99 99
100# To allow outside customization, rename cidfmap 100# To allow outside customization, rename cidfmap
101# (if you look at inside of the file, it is logically empty) 101# (if you look at inside of the file, it is logically empty)
102.if !empty(PKG_OPTIONS:Mdisable-compile-inits) 102.if !empty(PKG_OPTIONS:Mdisable-compile-inits)
103 (cd ${WRKSRC}/Resource/Init/; ${MV} cidfmap cidfmap.dist) 103 (cd ${WRKSRC}/Resource/Init/; ${MV} cidfmap cidfmap.dist)
104.endif 104.endif
105 105
106post-install: 106post-install:
107 ${LN} -sf gsc ${DESTDIR}${PREFIX}/bin/gs 107 ${LN} -sf gsc ${DESTDIR}${PREFIX}/bin/gs
 108 ${RM} -f ${DESTDIR}${PREFIX}/share/ghostscript/${PKGVERSION_NOREV}/Resource/Init/gs_ttf.ps.orig
108 109
109.include "../../devel/libidn/buildlink3.mk" 110.include "../../devel/libidn/buildlink3.mk"
110.include "../../devel/zlib/buildlink3.mk" 111.include "../../devel/zlib/buildlink3.mk"
111BUILDLINK_API_DEPENDS.freetype2+= freetype2>=2.10.0 112BUILDLINK_API_DEPENDS.freetype2+= freetype2>=2.10.0
112.include "../../graphics/freetype2/buildlink3.mk" 113.include "../../graphics/freetype2/buildlink3.mk"
113# XXX: Strictly speaking jbig2dec>=0.16, however now jbig2dec is only checked 114# XXX: Strictly speaking jbig2dec>=0.16, however now jbig2dec is only checked
114# XXX: via pkg-config and jbig2dec-0.17 is the first version that provides a 115# XXX: via pkg-config and jbig2dec-0.17 is the first version that provides a
115# XXX: .pc file. 116# XXX: .pc file.
116BUILDLINK_API_DEPENDS.jbig2dec+= jbig2dec>=0.17 117BUILDLINK_API_DEPENDS.jbig2dec+= jbig2dec>=0.17
117.include "../../graphics/jbig2dec/buildlink3.mk" 118.include "../../graphics/jbig2dec/buildlink3.mk"
118.include "../../graphics/lcms2/buildlink3.mk" 119.include "../../graphics/lcms2/buildlink3.mk"
119.include "../../graphics/openjpeg/buildlink3.mk" 120.include "../../graphics/openjpeg/buildlink3.mk"
120.include "../../graphics/png/buildlink3.mk" 121.include "../../graphics/png/buildlink3.mk"
121.include "../../graphics/tiff/buildlink3.mk" 122.include "../../graphics/tiff/buildlink3.mk"
122.include "../../print/libpaper/buildlink3.mk" 123.include "../../print/libpaper/buildlink3.mk"
123.include "../../mk/jpeg.buildlink3.mk" 124.include "../../mk/jpeg.buildlink3.mk"
124.include "../../mk/bsd.pkg.mk" 125.include "../../mk/bsd.pkg.mk"