summaryrefslogtreecommitdiffstats
path: root/meta/recipes-extended/ghostscript/ghostscript
diff options
context:
space:
mode:
authorRoss Burton <ross.burton@arm.com>2023-06-19 12:49:27 +0100
committerRichard Purdie <richard.purdie@linuxfoundation.org>2023-06-20 23:24:26 +0100
commit6a7a4e40d5da99fd45023860becebc6bef481d45 (patch)
tree200a664d20df5dff5366f9f80e3c70cf73d32c6b /meta/recipes-extended/ghostscript/ghostscript
parent89e2844fdcee07b69ef4aea7bd57d3d87ab1f114 (diff)
downloadpoky-6a7a4e40d5da99fd45023860becebc6bef481d45.tar.gz
ghostscript: mostly rewrite recipe
This started as a patch cleanup but escalated rapidly. Remove unneeded patches: - mkdir-p.patch isn't needed now the Makefiles appear to have the correct dependencies. - ghostscript-9.15-parallel-make.patch appears to be unneeded for the same reason - base-genht.c-add-a-preprocessor-define-to-allow-fope.patch isn't needed - cups-no-gcrypt.patch isn't needed - do-not-check-local-libpng-source.patch can be replaced by deleting the libpng/ directory, as is already done for jpeg/ - ghostscript-9.21-native-fix-disable-system-libtiff.patch is not needed when we stop doing native builds (see below) Remove the need for ghostscript-native to build and install tools that are needed at target build-time: ghostscript can do this itself. Remove the BBCLASSEXTEND and all of the native overrides. Inherit pkgconfig and explicitly tell configure to use the pkgconfig binary: unless told otherwise this configure will refuse to use an unprefixed pkgconfig in cross builds. Review DEPENDS and add missing freetype and zlib dependencies. Ghostcript will use the embedded copies of libraries over system libraries, so extend the deletion of jpeg and libpng to include expat, freetype, and cups as we want to link to our build of those. We can't delete zlib as it is explicitly used when building the native tools. Add PACKAGECONFIGs for optional libidn and libpaper dependencies. Remove HAVE_SYS_TIME_H assignments, the upstream bug was fixed in 2011. Clean up comments: there's no need to explain how to use PACKAGECONFIG, and justify the use of autotools-brokensep. (From OE-Core rev: b62e6d676ce2075a52eea729957f186cfb3bd42b) Signed-off-by: Ross Burton <ross.burton@arm.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-extended/ghostscript/ghostscript')
-rw-r--r--meta/recipes-extended/ghostscript/ghostscript/avoid-host-contamination.patch3
-rw-r--r--meta/recipes-extended/ghostscript/ghostscript/base-genht.c-add-a-preprocessor-define-to-allow-fope.patch42
-rw-r--r--meta/recipes-extended/ghostscript/ghostscript/cups-no-gcrypt.patch37
-rw-r--r--meta/recipes-extended/ghostscript/ghostscript/do-not-check-local-libpng-source.patch31
-rw-r--r--meta/recipes-extended/ghostscript/ghostscript/ghostscript-9.15-parallel-make.patch28
-rw-r--r--meta/recipes-extended/ghostscript/ghostscript/ghostscript-9.21-native-fix-disable-system-libtiff.patch47
-rw-r--r--meta/recipes-extended/ghostscript/ghostscript/mkdir-p.patch50
7 files changed, 1 insertions, 237 deletions
diff --git a/meta/recipes-extended/ghostscript/ghostscript/avoid-host-contamination.patch b/meta/recipes-extended/ghostscript/ghostscript/avoid-host-contamination.patch
index e8cb16c36b..15c7eb5a77 100644
--- a/meta/recipes-extended/ghostscript/ghostscript/avoid-host-contamination.patch
+++ b/meta/recipes-extended/ghostscript/ghostscript/avoid-host-contamination.patch
@@ -5,8 +5,7 @@ Subject: [PATCH 04/10] avoid host contamination
5 5
6Remove hardcode path refer to host to avoid host contamination. 6Remove hardcode path refer to host to avoid host contamination.
7 7
8Upstream-Status: Inappropriate [embedded specific] 8Upstream-Status: Pending
9
10Signed-off-by: Kai Kang <kai.kang@windriver.com> 9Signed-off-by: Kai Kang <kai.kang@windriver.com>
11 10
12Rebase to 9.23 11Rebase to 9.23
diff --git a/meta/recipes-extended/ghostscript/ghostscript/base-genht.c-add-a-preprocessor-define-to-allow-fope.patch b/meta/recipes-extended/ghostscript/ghostscript/base-genht.c-add-a-preprocessor-define-to-allow-fope.patch
deleted file mode 100644
index 7d80066a80..0000000000
--- a/meta/recipes-extended/ghostscript/ghostscript/base-genht.c-add-a-preprocessor-define-to-allow-fope.patch
+++ /dev/null
@@ -1,42 +0,0 @@
1From 9ca6f795409b988d38dd98bc2a6ecb68a9392312 Mon Sep 17 00:00:00 2001
2From: Hongxu Jia <hongxu.jia@windriver.com>
3Date: Thu, 29 Mar 2018 16:37:40 +0800
4Subject: [PATCH 10/10] base/genht.c: add a preprocessor define to allow fopen
5 calling
6
7The commit in upstream:
8http://git.ghostscript.com/?p=ghostpdl.git;a=commitdiff;h=773c69e46e70bdd5482676437dafd2ca83397643
9
10Replace all fopen calls with gp_fopen and add a preprocessor define so
11that any unintential calls directly to fopen will cause an error.
12
13Only exceptions are those in the platform specific code, and mkromfs.c.
14This patch add a preprocessor define to allow fopen calling in
15base/genht.c.
16
17Upstream-Status: Pending
18
19Rebase to 9.23
20Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
21---
22 base/genht.c | 4 ++++
23 1 file changed, 4 insertions(+)
24
25diff --git a/base/genht.c b/base/genht.c
26index e597e72..e96bfb5 100644
27--- a/base/genht.c
28+++ b/base/genht.c
29@@ -16,6 +16,10 @@
30
31 /* Generate C code for compiling halftones into ROM. */
32 #include "malloc_.h"
33+
34+/* prevent gp.h from defining fopen */
35+#define fopen fopen
36+
37 #include "stdio_.h"
38 #include "string_.h"
39 #include "gscdefs.h"
40--
411.8.3.1
42
diff --git a/meta/recipes-extended/ghostscript/ghostscript/cups-no-gcrypt.patch b/meta/recipes-extended/ghostscript/ghostscript/cups-no-gcrypt.patch
deleted file mode 100644
index 4c9bb22fa2..0000000000
--- a/meta/recipes-extended/ghostscript/ghostscript/cups-no-gcrypt.patch
+++ /dev/null
@@ -1,37 +0,0 @@
1From 9129eb7fa9dc160d64a7d9df9279a3b1dae4d793 Mon Sep 17 00:00:00 2001
2From: Jackie Huang <jackie.huang@windriver.com>
3Date: Thu, 29 Mar 2018 16:16:18 +0800
4Subject: [PATCH 08/10] cups no gcrypt
5
6Don't build-depend on libgcrypt, as nothing is used from it
7
8Backported from
9http://www.cups.org/strfiles.php/3308/cups-no-gcrypt.patch
10
11This addresses the cryto dependency seen during build.
12
13Upstream-Status: Backport
14
15Signed-off-by: Jackie Huang <jackie.huang@windriver.com>
16
17Rebase to 9.23
18Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
19---
20 cups/libs/cups/http-private.h | 1 -
21 1 file changed, 1 deletion(-)
22
23diff --git a/cups/libs/cups/http-private.h b/cups/libs/cups/http-private.h
24index 99a85c3..a674852 100644
25--- a/cups/libs/cups/http-private.h
26+++ b/cups/libs/cups/http-private.h
27@@ -80,7 +80,6 @@ typedef int socklen_t;
28 # elif defined HAVE_GNUTLS
29 # include <gnutls/gnutls.h>
30 # include <gnutls/x509.h>
31-# include <gcrypt.h>
32 # elif defined(HAVE_CDSASSL)
33 # include <CoreFoundation/CoreFoundation.h>
34 # include <Security/Security.h>
35--
361.8.3.1
37
diff --git a/meta/recipes-extended/ghostscript/ghostscript/do-not-check-local-libpng-source.patch b/meta/recipes-extended/ghostscript/ghostscript/do-not-check-local-libpng-source.patch
deleted file mode 100644
index 13e71c824f..0000000000
--- a/meta/recipes-extended/ghostscript/ghostscript/do-not-check-local-libpng-source.patch
+++ /dev/null
@@ -1,31 +0,0 @@
1From 108a7d3f79af8c669af129bd87401402e76edfa9 Mon Sep 17 00:00:00 2001
2From: Hongxu Jia <hongxu.jia@windriver.com>
3Date: Mon, 18 Jan 2016 01:00:30 -0500
4Subject: [PATCH] configure.ac: do not check local png source
5
6In oe-core, it did not need to compile local libpng
7source in ghostscript, so do not check local png
8source, and directly check the existance of shared
9libpng library.
10
11Upstream-Status: Inappropriate [OE-Core specific]
12
13Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
14
15---
16 configure.ac | 2 +-
17 1 file changed, 1 insertion(+), 1 deletion(-)
18
19diff --git a/configure.ac b/configure.ac
20index bb57825..389c473 100644
21--- a/configure.ac
22+++ b/configure.ac
23@@ -1441,7 +1441,7 @@ else
24 PNGDEVS=''
25 PNGDEVS_ALL='png48 png16m pnggray pngmono pngmonod png256 png16 pngalpha png16malpha'
26 AC_MSG_CHECKING([for local png library source])
27- if test -f $srcdir/libpng/pngread.c; then
28+ if false; then
29 AC_MSG_RESULT([yes])
30 SHARE_LIBPNG=0
31 LIBPNGDIR=$srcdir/libpng
diff --git a/meta/recipes-extended/ghostscript/ghostscript/ghostscript-9.15-parallel-make.patch b/meta/recipes-extended/ghostscript/ghostscript/ghostscript-9.15-parallel-make.patch
deleted file mode 100644
index 5b57da2a97..0000000000
--- a/meta/recipes-extended/ghostscript/ghostscript/ghostscript-9.15-parallel-make.patch
+++ /dev/null
@@ -1,28 +0,0 @@
1From 04a86a613e0f9bfbbad99874f72217f75e8c53a3 Mon Sep 17 00:00:00 2001
2From: Robert Yang <liezhi.yang@windriver.com>
3Date: Thu, 29 Mar 2018 15:59:05 +0800
4Subject: [PATCH] contrib.mak: fix for parallel build
5
6Upstream-Status: Pending
7
8Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
9
10Rebase to 9.23
11Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
12
13---
14 contrib/contrib.mak | 1 +
15 1 file changed, 1 insertion(+)
16
17diff --git a/contrib/contrib.mak b/contrib/contrib.mak
18index 2edee7a..c9100e8 100644
19--- a/contrib/contrib.mak
20+++ b/contrib/contrib.mak
21@@ -1241,6 +1241,7 @@ $(DEVOBJ)gdevalps.$(OBJ) : $(JAPSRC)gdevalps.c $(PDEVH) \
22 ### ----------------- Additional .upp files ---------------- ###
23
24 extra-upp-install: install-libdata
25+ mkdir -p $(DESTDIR)$(gsdatadir)$(D)lib
26 for f in $(CONTRIBSRC)uniprint$(D)*.upp; do \
27 $(INSTALL_DATA) $$f $(DESTDIR)$(gsdatadir)$(D)lib || exit 1; \
28 done
diff --git a/meta/recipes-extended/ghostscript/ghostscript/ghostscript-9.21-native-fix-disable-system-libtiff.patch b/meta/recipes-extended/ghostscript/ghostscript/ghostscript-9.21-native-fix-disable-system-libtiff.patch
deleted file mode 100644
index a382c7f891..0000000000
--- a/meta/recipes-extended/ghostscript/ghostscript/ghostscript-9.21-native-fix-disable-system-libtiff.patch
+++ /dev/null
@@ -1,47 +0,0 @@
1From 0124b1c29b9cfe46d73ae82ce023dd7c5b055744 Mon Sep 17 00:00:00 2001
2From: Hongxu Jia <hongxu.jia@windriver.com>
3Date: Thu, 29 Mar 2018 16:36:12 +0800
4Subject: [PATCH 09/10] ghostscript-native:fix disable-system-libtiff
5
6Modify configure to add the check to make sure
7ghostscrip could work while system-libtiff is
8disabled.
9
10Upstream-Status: Pending
11
12Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
13
14Rebase to ghostscript 9.25.
15
16Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
17Signed-off-by: Jagadeesh Krishnanjanappa <jkrishnanjanappa@mvista.com>
18---
19 configure.ac | 5 +++++
20 1 file changed, 5 insertions(+)
21
22diff --git a/configure.ac b/configure.ac
23index 80a60b1..f3e9efb 100644
24--- a/configure.ac
25+++ b/configure.ac
26@@ -1319,6 +1319,7 @@ AC_TRY_COMPILE([], [return 0;],
27 CFLAGS=$CGLAGS_STORE
28
29 if test x"$SHARE_LIBTIFF" = x"0" ; then
30+ if test -e $LIBTIFFDIR/configure; then
31 echo "Running libtiff configure script..."
32 olddir=`pwd`
33 if ! test -d "$LIBTIFFCONFDIR" ; then
34@@ -1337,6 +1338,10 @@ if test x"$SHARE_LIBTIFF" = x"0" ; then
35
36 echo
37 echo "Continuing with Ghostscript configuration..."
38+ else
39+ AC_MSG_NOTICE([Could not find local copy of libtiff.
40+Disabling tiff output devices.])
41+ fi
42 fi
43
44 AC_SUBST(SHARE_LIBTIFF)
45--
461.8.3.1
47
diff --git a/meta/recipes-extended/ghostscript/ghostscript/mkdir-p.patch b/meta/recipes-extended/ghostscript/ghostscript/mkdir-p.patch
deleted file mode 100644
index 3e6d3e3c48..0000000000
--- a/meta/recipes-extended/ghostscript/ghostscript/mkdir-p.patch
+++ /dev/null
@@ -1,50 +0,0 @@
1From 2b23026f8e2a352417fb1c4da94bf69b19bef267 Mon Sep 17 00:00:00 2001
2From: Joe Slater <joe.slater@windriver.com>
3Date: Thu, 29 Mar 2018 16:04:32 +0800
4Subject: [PATCH 05/10] ghostscript: allow directories to be created more than
5 once
6
7When doing parallel builds, we might try to create directories
8more than once. This should not cause an error.
9
10Upstream-Status: Pending
11
12Signed-off-by: Joe Slater <joe.slater@windriver.com>
13
14Rebase to 9.23
15Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
16---
17 base/unix-end.mak | 17 ++++++++---------
18 1 file changed, 8 insertions(+), 9 deletions(-)
19
20diff --git a/base/unix-end.mak b/base/unix-end.mak
21index 9ce599a..feff5a6 100644
22--- a/base/unix-end.mak
23+++ b/base/unix-end.mak
24@@ -17,15 +17,14 @@
25 UNIX_END_MAK=$(GLSRC)unix-end.mak $(TOP_MAKEFILES)
26 # Define the rule for building standard configurations.
27 directories: $(UNIX_END_MAK)
28- @if test "$(BINDIR)" != "" -a ! -d $(BINDIR); then mkdir $(BINDIR); fi
29- @if test "$(GLGENDIR)" != "" -a ! -d $(GLGENDIR); then mkdir $(GLGENDIR); fi
30- @if test "$(GLOBJDIR)" != "" -a ! -d $(GLOBJDIR); then mkdir $(GLOBJDIR); fi
31- @if test "$(DEVGENDIR)" != "" -a ! -d $(DEVGENDIR); then mkdir $(DEVGENDIR); fi
32- @if test "$(DEVOBJDIR)" != "" -a ! -d $(DEVOBJDIR); then mkdir $(DEVOBJDIR); fi
33- @if test "$(AUXDIR)" != "" -a ! -d $(AUXDIR); then mkdir $(AUXDIR); fi
34- @if test "$(PSGENDIR)" != "" -a ! -d $(PSGENDIR); then mkdir $(PSGENDIR); fi
35- @if test "$(PSGENDIR)" != "" -a ! -d $(PSGENDIR)/cups; then mkdir $(PSGENDIR)/cups; fi
36- @if test "$(PSOBJDIR)" != "" -a ! -d $(PSOBJDIR); then mkdir $(PSOBJDIR); fi
37+ @if test "$(BINDIR)" != "" -a ! -d $(BINDIR); then mkdir -p $(BINDIR); fi
38+ @if test "$(GLGENDIR)" != "" -a ! -d $(GLGENDIR); then mkdir -p $(GLGENDIR); fi
39+ @if test "$(GLOBJDIR)" != "" -a ! -d $(GLOBJDIR); then mkdir -p $(GLOBJDIR); fi
40+ @if test "$(DEVGENDIR)" != "" -a ! -d $(DEVGENDIR); then mkdir -p $(DEVGENDIR); fi
41+ @if test "$(DEVOBJDIR)" != "" -a ! -d $(DEVOBJDIR); then mkdir -p $(DEVOBJDIR); fi
42+ @if test "$(AUXDIR)" != "" -a ! -d $(AUXDIR); then mkdir -p $(AUXDIR); fi
43+ @if test "$(PSGENDIR)" != "" -a ! -d $(PSGENDIR)/cups; then mkdir -p $(PSGENDIR)/cups; fi
44+ @if test "$(PSOBJDIR)" != "" -a ! -d $(PSOBJDIR); then mkdir -p $(PSOBJDIR); fi
45
46
47 gs: .gssubtarget $(UNIX_END_MAK)
48--
491.8.3.1
50