diff options
author | Joe Slater <jslater@windriver.com> | 2017-06-15 14:35:26 -0700 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2017-06-23 11:44:13 +0100 |
commit | d3e8504ce7a25908fe5ad7973d807d199950dc9a (patch) | |
tree | 767fdefdb315ad3dabe68ec465f92d9816b06fe3 /meta/recipes-extended/ghostscript/ghostscript_9.21.bb | |
parent | a16d0f6c496f4c8c61accbabd6769839bda62f36 (diff) | |
download | poky-d3e8504ce7a25908fe5ad7973d807d199950dc9a.tar.gz |
ghostscript: move to version 9.21
Eliminate CVE patches that are now in source.
Add CUPSCONFIG to configure options.
(From OE-Core rev: 3041f94896b50a5a5d19caf0dd0e7910c730e18e)
Signed-off-by: Joe Slater <jslater@windriver.com>
to be scrunched
Signed-off-by: Joe Slater <jslater@windriver.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-extended/ghostscript/ghostscript_9.21.bb')
-rw-r--r-- | meta/recipes-extended/ghostscript/ghostscript_9.21.bb | 117 |
1 files changed, 117 insertions, 0 deletions
diff --git a/meta/recipes-extended/ghostscript/ghostscript_9.21.bb b/meta/recipes-extended/ghostscript/ghostscript_9.21.bb new file mode 100644 index 0000000000..ed0fd431a7 --- /dev/null +++ b/meta/recipes-extended/ghostscript/ghostscript_9.21.bb | |||
@@ -0,0 +1,117 @@ | |||
1 | SUMMARY = "The GPL Ghostscript PostScript/PDF interpreter" | ||
2 | DESCRIPTION = "Ghostscript is used for PostScript/PDF preview and printing. Usually as \ | ||
3 | a back-end to a program such as ghostview, it can display PostScript and PDF \ | ||
4 | documents in an X11 environment. \ | ||
5 | \ | ||
6 | Furthermore, it can render PostScript and PDF files as graphics to be printed \ | ||
7 | on non-PostScript printers. Supported printers include common \ | ||
8 | dot-matrix, inkjet and laser models. \ | ||
9 | " | ||
10 | HOMEPAGE = "http://www.ghostscript.com" | ||
11 | SECTION = "console/utils" | ||
12 | |||
13 | LICENSE = "GPLv3" | ||
14 | LIC_FILES_CHKSUM = "file://LICENSE;md5=70dc2bac4d0ce4448da873cd86b123fc" | ||
15 | |||
16 | DEPENDS = "ghostscript-native tiff jpeg fontconfig cups libpng" | ||
17 | DEPENDS_class-native = "libpng-native" | ||
18 | |||
19 | UPSTREAM_CHECK_URI = "https://github.com/ArtifexSoftware/ghostpdl-downloads/releases" | ||
20 | UPSTREAM_CHECK_REGEX = "(?P<pver>\d+(\.\d+)+)\.tar" | ||
21 | |||
22 | SRC_URI_BASE = "https://github.com/ArtifexSoftware/ghostpdl-downloads/releases/download/gs921/${BPN}-${PV}.tar.gz \ | ||
23 | file://ghostscript-9.15-parallel-make.patch \ | ||
24 | file://ghostscript-9.16-Werror-return-type.patch \ | ||
25 | file://png_mak.patch \ | ||
26 | file://do-not-check-local-libpng-source.patch \ | ||
27 | file://avoid-host-contamination.patch \ | ||
28 | file://mkdir-p.patch \ | ||
29 | " | ||
30 | |||
31 | SRC_URI = "${SRC_URI_BASE} \ | ||
32 | file://ghostscript-9.21-prevent_recompiling.patch \ | ||
33 | file://ghostscript-9.02-genarch.patch \ | ||
34 | file://objarch.h \ | ||
35 | file://cups-no-gcrypt.patch \ | ||
36 | file://CVE-2016-7977.patch \ | ||
37 | file://CVE-2017-7207.patch \ | ||
38 | file://CVE-2017-5951.patch \ | ||
39 | file://CVE-2017-7975.patch \ | ||
40 | file://CVE-2017-9216.patch \ | ||
41 | " | ||
42 | |||
43 | SRC_URI_class-native = "${SRC_URI_BASE} \ | ||
44 | file://ghostscript-9.21-native-fix-disable-system-libtiff.patch \ | ||
45 | file://base-genht.c-add-a-preprocessor-define-to-allow-fope.patch \ | ||
46 | " | ||
47 | |||
48 | SRC_URI[md5sum] = "5f213281761d2750fcf27476c404d17f" | ||
49 | SRC_URI[sha256sum] = "02bceadbc4dddeb6f2eec9c8b1623d945d355ca11b8b4df035332b217d58ce85" | ||
50 | |||
51 | EXTRA_OECONF = "--without-x --with-system-libtiff --without-jbig2dec \ | ||
52 | --with-fontpath=${datadir}/fonts \ | ||
53 | --without-libidn --with-cups-serverbin=${exec_prefix}/lib/cups \ | ||
54 | --with-cups-datadir=${datadir}/cups \ | ||
55 | CUPSCONFIG="${STAGING_BINDIR_CROSS}/cups-config" \ | ||
56 | " | ||
57 | |||
58 | EXTRA_OECONF_append_mipsarcho32 = " --with-large_color_index=0" | ||
59 | |||
60 | # Explicity disable libtiff, fontconfig, | ||
61 | # freetype, cups for ghostscript-native | ||
62 | EXTRA_OECONF_class-native = "--without-x --with-system-libtiff=no \ | ||
63 | --without-jbig2dec \ | ||
64 | --with-fontpath=${datadir}/fonts \ | ||
65 | --without-libidn --disable-fontconfig \ | ||
66 | --disable-freetype --disable-cups" | ||
67 | |||
68 | # This has been fixed upstream but for now we need to subvert the check for time.h | ||
69 | # http://bugs.ghostscript.com/show_bug.cgi?id=692443 | ||
70 | # http://bugs.ghostscript.com/show_bug.cgi?id=692426 | ||
71 | CFLAGS += "-DHAVE_SYS_TIME_H=1" | ||
72 | BUILD_CFLAGS += "-DHAVE_SYS_TIME_H=1" | ||
73 | |||
74 | inherit autotools | ||
75 | |||
76 | do_configure_prepend () { | ||
77 | mkdir -p obj | ||
78 | mkdir -p soobj | ||
79 | if [ -e ${WORKDIR}/objarch.h ]; then | ||
80 | cp ${WORKDIR}/objarch.h obj/arch.h | ||
81 | fi | ||
82 | } | ||
83 | |||
84 | do_configure_append () { | ||
85 | # copy tools from the native ghostscript build | ||
86 | if [ "${PN}" != "ghostscript-native" ]; then | ||
87 | mkdir -p obj/aux soobj | ||
88 | for i in genarch genconf mkromfs echogs gendev genht; do | ||
89 | cp ${STAGING_BINDIR_NATIVE}/ghostscript-${PV}/$i obj/aux/$i | ||
90 | done | ||
91 | fi | ||
92 | } | ||
93 | |||
94 | do_install_append () { | ||
95 | mkdir -p ${D}${datadir}/ghostscript/${PV}/ | ||
96 | cp -r ${S}/Resource ${D}${datadir}/ghostscript/${PV}/ | ||
97 | cp -r ${S}/iccprofiles ${D}${datadir}/ghostscript/${PV}/ | ||
98 | } | ||
99 | |||
100 | do_compile_class-native () { | ||
101 | mkdir -p obj | ||
102 | for i in genarch genconf mkromfs echogs gendev genht; do | ||
103 | oe_runmake obj/aux/$i | ||
104 | done | ||
105 | } | ||
106 | |||
107 | do_install_class-native () { | ||
108 | install -d ${D}${bindir}/ghostscript-${PV} | ||
109 | for i in genarch genconf mkromfs echogs gendev genht; do | ||
110 | install -m 755 obj/aux/$i ${D}${bindir}/ghostscript-${PV}/$i | ||
111 | done | ||
112 | } | ||
113 | |||
114 | BBCLASSEXTEND = "native" | ||
115 | |||
116 | # ghostscript does not supports "arc" | ||
117 | COMPATIBLE_HOST = "^(?!arc).*" | ||