Skip to contentSkip to conversation

ghostscript: add patches to make it run cross compile platform V2

PATCH Applied Kang Kai 2 participants 5 messages May 21, 2011 – Jun 1, 2011

lore
Share & tools
lore

Kang Kai

author
#0 lore raw

cover ghostscript: add patches to make it run cross compile platform V2

From: Kang Kai <[email protected]>

Hi Richard,

I update the patches with your opinion, thanks!

When test lsb on ppc find that gs can't run. The root cause is gs determines some target configuration on build system. According to the document of ghostscript,
http://pages.cs.wisc.edu/~ghost/doc/cvs/Make.htm#Cross-compiling
when cross compile ghostscript need some manual work.
So import patches from WindRiver Linux to make sure ghostscript can be cross compiled, and spit the patches into arch/[so]obj.h source files.

The following changes since commit 7706d5d844db2725f4118207d90e302679eacdfe:

linux-yocto/meta-yocto: fix gcc 4.6.0 compilation failures (2011-05-19 17:33:50 -0700)

are available in the git repository at:
git://git.pokylinux.org/poky-contrib.git kangkai/distro
http://git.pokylinux.org/cgit.cgi//log/?h=kangkai/distro

Kang Kai (1):
ghostscript: fix run failure on mpc8315e

 meta/recipes-extended/ghostscript/arm/objarch.h    |   40 +++++++++++++++++++
 meta/recipes-extended/ghostscript/arm/soobjarch.h  |   40 +++++++++++++++++++
 .../ghostscript/ghostscript-9.02-genarch.patch     |   27 +++++++++++++
 .../ghostscript/ghostscript_9.02.bb                |   22 +++++++++-
 meta/recipes-extended/ghostscript/i586/objarch.h   |   41 ++++++++++++++++++++
 meta/recipes-extended/ghostscript/i586/soobjarch.h |   41 ++++++++++++++++++++
 meta/recipes-extended/ghostscript/mips/objarch.h   |   40 +++++++++++++++++++
 meta/recipes-extended/ghostscript/mips/soobjarch.h |   40 +++++++++++++++++++
 .../recipes-extended/ghostscript/powerpc/objarch.h |   40 +++++++++++++++++++
 .../ghostscript/powerpc/soobjarch.h                |   40 +++++++++++++++++++
 meta/recipes-extended/ghostscript/x86_64/objarch.h |   40 +++++++++++++++++++
 .../ghostscript/x86_64/soobjarch.h                 |   40 +++++++++++++++++++
 12 files changed, 448 insertions(+), 3 deletions(-)
 create mode 100644 meta/recipes-extended/ghostscript/arm/objarch.h
 create mode 100644 meta/recipes-extended/ghostscript/arm/soobjarch.h
 create mode 100644 meta/recipes-extended/ghostscript/ghostscript/ghostscript-9.02-genarch.patch
 create mode 100644 meta/recipes-extended/ghostscript/i586/objarch.h
 create mode 100644 meta/recipes-extended/ghostscript/i586/soobjarch.h
 create mode 100644 meta/recipes-extended/ghostscript/mips/objarch.h
 create mode 100644 meta/recipes-extended/ghostscript/mips/soobjarch.h
 create mode 100644 meta/recipes-extended/ghostscript/powerpc/objarch.h
 create mode 100644 meta/recipes-extended/ghostscript/powerpc/soobjarch.h
 create mode 100644 meta/recipes-extended/ghostscript/x86_64/objarch.h
 create mode 100644 meta/recipes-extended/ghostscript/x86_64/soobjarch.h
Signature · 1 line
1.7.5.1.300.gc565c
author
#1 lore raw

PATCH 1/1 ghostscript: fix run failure on mpc8315e

From: Kang Kai <[email protected]>

When run gs on mpc8315, it fails with:
GPL Ghostscript 9.02: ./psi/interp.c(291): Fatal error -20 in gs_interp_init! It is caused by cross compile.

Accoding to the ghostscript document on:
http://pages.cs.wisc.edu/~ghost/doc/cvs/Make.htm#Cross-compiling
it needs some manual work, so import patches from WindRiver Linux.

Update to using oe way to add arch.h, thanks to Richard.

---
 meta/recipes-extended/ghostscript/arm/objarch.h    |   40 +++++++++++++++++++
 meta/recipes-extended/ghostscript/arm/soobjarch.h  |   40 +++++++++++++++++++
 .../ghostscript/ghostscript-9.02-genarch.patch     |   27 +++++++++++++
 .../ghostscript/ghostscript_9.02.bb                |   22 +++++++++-
 meta/recipes-extended/ghostscript/i586/objarch.h   |   41 ++++++++++++++++++++
 meta/recipes-extended/ghostscript/i586/soobjarch.h |   41 ++++++++++++++++++++
 meta/recipes-extended/ghostscript/mips/objarch.h   |   40 +++++++++++++++++++
 meta/recipes-extended/ghostscript/mips/soobjarch.h |   40 +++++++++++++++++++
 .../recipes-extended/ghostscript/powerpc/objarch.h |   40 +++++++++++++++++++
 .../ghostscript/powerpc/soobjarch.h                |   40 +++++++++++++++++++
 meta/recipes-extended/ghostscript/x86_64/objarch.h |   40 +++++++++++++++++++
 .../ghostscript/x86_64/soobjarch.h                 |   40 +++++++++++++++++++
 12 files changed, 448 insertions(+), 3 deletions(-)
 create mode 100644 meta/recipes-extended/ghostscript/arm/objarch.h
 create mode 100644 meta/recipes-extended/ghostscript/arm/soobjarch.h
 create mode 100644 meta/recipes-extended/ghostscript/ghostscript/ghostscript-9.02-genarch.patch
 create mode 100644 meta/recipes-extended/ghostscript/i586/objarch.h
 create mode 100644 meta/recipes-extended/ghostscript/i586/soobjarch.h
 create mode 100644 meta/recipes-extended/ghostscript/mips/objarch.h
 create mode 100644 meta/recipes-extended/ghostscript/mips/soobjarch.h
 create mode 100644 meta/recipes-extended/ghostscript/powerpc/objarch.h
 create mode 100644 meta/recipes-extended/ghostscript/powerpc/soobjarch.h
 create mode 100644 meta/recipes-extended/ghostscript/x86_64/objarch.h
 create mode 100644 meta/recipes-extended/ghostscript/x86_64/soobjarch.h
meta/recipes-extended/ghostscript/arm/objarch.h new file +40 -0
new file mode 100644
index 0000000..e8772cd
@@ -0,0 +1,40 @@
+/* Parameters derived from machine and compiler architecture. */
+/* This file is generated mechanically by genarch.c. */
+
+	 /* ---------------- Scalar alignments ---------------- */
+
+#define ARCH_ALIGN_SHORT_MOD 2
+#define ARCH_ALIGN_INT_MOD 4
+#define ARCH_ALIGN_LONG_MOD 4
+#define ARCH_ALIGN_PTR_MOD 4
+#define ARCH_ALIGN_FLOAT_MOD 4
+#define ARCH_ALIGN_DOUBLE_MOD 8
+
+	 /* ---------------- Scalar sizes ---------------- */
+
+#define ARCH_LOG2_SIZEOF_CHAR 0
+#define ARCH_LOG2_SIZEOF_SHORT 1
+#define ARCH_LOG2_SIZEOF_INT 2
+#define ARCH_LOG2_SIZEOF_LONG 2
+#define ARCH_LOG2_SIZEOF_LONG_LONG 3
+#define ARCH_SIZEOF_GX_COLOR_INDEX 8
+#define ARCH_SIZEOF_PTR 4
+#define ARCH_SIZEOF_FLOAT 4
+#define ARCH_SIZEOF_DOUBLE 8
+#define ARCH_FLOAT_MANTISSA_BITS 24
+#define ARCH_DOUBLE_MANTISSA_BITS 53
+
+	 /* ---------------- Unsigned max values ---------------- */
+
+#define ARCH_MAX_UCHAR ((unsigned char)0xff + (unsigned char)0)
+#define ARCH_MAX_USHORT ((unsigned short)0xffff + (unsigned short)0)
+#define ARCH_MAX_UINT ((unsigned int)~0 + (unsigned int)0)
+#define ARCH_MAX_ULONG ((unsigned long)~0L + (unsigned long)0)
+
+	 /* ---------------- Miscellaneous ---------------- */
+
+#define ARCH_IS_BIG_ENDIAN 0
+#define ARCH_PTRS_ARE_SIGNED 0
+#define ARCH_FLOATS_ARE_IEEE 1
+#define ARCH_ARITH_RSHIFT 2
+#define ARCH_DIV_NEG_POS_TRUNCATES 1
meta/recipes-extended/ghostscript/arm/soobjarch.h new file +40 -0
new file mode 100644
index 0000000..e8772cd
@@ -0,0 +1,40 @@
+/* Parameters derived from machine and compiler architecture. */
+/* This file is generated mechanically by genarch.c. */
+
+	 /* ---------------- Scalar alignments ---------------- */
+
+#define ARCH_ALIGN_SHORT_MOD 2
+#define ARCH_ALIGN_INT_MOD 4
+#define ARCH_ALIGN_LONG_MOD 4
+#define ARCH_ALIGN_PTR_MOD 4
+#define ARCH_ALIGN_FLOAT_MOD 4
+#define ARCH_ALIGN_DOUBLE_MOD 8
+
+	 /* ---------------- Scalar sizes ---------------- */
+
+#define ARCH_LOG2_SIZEOF_CHAR 0
+#define ARCH_LOG2_SIZEOF_SHORT 1
+#define ARCH_LOG2_SIZEOF_INT 2
+#define ARCH_LOG2_SIZEOF_LONG 2
+#define ARCH_LOG2_SIZEOF_LONG_LONG 3
+#define ARCH_SIZEOF_GX_COLOR_INDEX 8
+#define ARCH_SIZEOF_PTR 4
+#define ARCH_SIZEOF_FLOAT 4
+#define ARCH_SIZEOF_DOUBLE 8
+#define ARCH_FLOAT_MANTISSA_BITS 24
+#define ARCH_DOUBLE_MANTISSA_BITS 53
+
+	 /* ---------------- Unsigned max values ---------------- */
+
+#define ARCH_MAX_UCHAR ((unsigned char)0xff + (unsigned char)0)
+#define ARCH_MAX_USHORT ((unsigned short)0xffff + (unsigned short)0)
+#define ARCH_MAX_UINT ((unsigned int)~0 + (unsigned int)0)
+#define ARCH_MAX_ULONG ((unsigned long)~0L + (unsigned long)0)
+
+	 /* ---------------- Miscellaneous ---------------- */
+
+#define ARCH_IS_BIG_ENDIAN 0
+#define ARCH_PTRS_ARE_SIGNED 0
+#define ARCH_FLOATS_ARE_IEEE 1
+#define ARCH_ARITH_RSHIFT 2
+#define ARCH_DIV_NEG_POS_TRUNCATES 1
meta/recipes-extended/ghostscript/ghostscript/ghostscript-9.02-genarch.patch new file +27 -0
new file mode 100644
index 0000000..149f9fc
@@ -0,0 +1,27 @@
+Import patch from windriver linux for cross compilation, and split patches
+into oe way under different directories such as i586, powerpc etc according 
+to Richard's opinion.
+
+Upstream-status: Pending
+
+Signed-off-by: Kang Kai <[email protected]>
+
+# Author: Chi Xu <[email protected]>
+# Date: Feb 26 2010
+# Summary: Generate arch.h for ppc32
+#
+
+diff -Nru ghostscript-8.64.orig/base/lib.mak ghostscript-8.64/base/lib.mak
+--- ghostscript-8.64.orig/base/lib.mak	2010-02-10 10:30:02.000000000 +0800
++++ ghostscript-8.64/base/lib.mak	2010-02-10 10:56:21.000000000 +0800
+@@ -50,8 +50,8 @@
+ stdpre_h=$(GLSRC)stdpre.h $(stdpn_h)
+ stdint__h=$(GLSRC)stdint_.h $(std_h)
+
+-$(GLGEN)arch.h : $(GENARCH_XE)
+-	$(EXP)$(GENARCH_XE) $(GLGEN)arch.h
++##$(GLGEN)arch.h : $(GENARCH_XE)
++##	$(EXP)$(GENARCH_XE) $(GLGEN)arch.h
+
+ # Platform interfaces
+
meta/recipes-extended/ghostscript/ghostscript_9.02.bb +19 -3
index dcdedad..e3d32dd 100644
@@ -15,22 +15,32 @@ SECTION = "console/utils"
 LICENSE = "GPLv3"
 LIC_FILES_CHKSUM = "file://LICENSE;md5=d151214b3131251dfc9d858593acbd24"
 
-PR = "r0"
+PR = "r1"
 
-DEPENDS = "tiff ${PN}-native"
+DEPENDS = "${PN}-native tiff jpeg fontconfig cups"
 DEPENDS_virtclass-native = ""
 
 SRC_URI = "http://downloads.ghostscript.com/public/ghostscript-${PV}.tar.bz2 \
            file://ghostscript-9.02-prevent_recompiling.patch \
+           file://ghostscript-9.02-genarch.patch \
+           file://objarch.h \
+           file://soobjarch.h \
            "
 
 SRC_URI[md5sum] = "f67151444bd56a7904579fc75a083dd6"
 SRC_URI[sha256sum] = "03ea2cad13a36f8f9160912012b79619a826e7148fada6d3531feb25409ee05a"
 
-EXTRA_OECONF = "--with-system-libtiff --without-jbig2dec --without-jasper --x-includes=${STAGING_DIR_HOST}/usr/include/X11 --x-libraries=${STAGING_DIR_HOST}/usr/lib"
+EXTRA_OECONF = "--without-x --with-system-libtiff --without-jbig2dec --without-jasper --with-fontpath=${datadir}/fonts"
 
 inherit autotools
 
+do_configure_prepend () {
+     mkdir -p obj
+     mkdir -p soobj
+     cp ${WORKDIR}/objarch.h obj/arch.h
+     cp ${WORKDIR}/soobjarch.h soobj/arch.h
+}
+
 do_configure () {
     oe_runconf
 
@@ -42,6 +52,12 @@ do_configure () {
     done
 }
 
+do_install_append () {
+    mkdir -p ${D}${datadir}/ghostscript/${PV}/
+    cp -r Resource ${D}${datadir}/ghostscript/${PV}/
+    cp -r iccprofiles ${D}${datadir}/ghostscript/${PV}/
+}
+
 python do_patch_virtclass-native () {
     pass
 }
meta/recipes-extended/ghostscript/i586/objarch.h new file +41 -0

41 lines not on this page · raw message

meta/recipes-extended/ghostscript/i586/soobjarch.h new file +41 -0

41 lines not on this page · raw message

meta/recipes-extended/ghostscript/mips/objarch.h new file +40 -0
new file mode 100644
index 0000000..359097f
@@ -0,0 +1,40 @@
+/* Parameters derived from machine and compiler architecture. */
+/* This file is generated mechanically by genarch.c. */
+
+	 /* ---------------- Scalar alignments ---------------- */
+
+#define ARCH_ALIGN_SHORT_MOD 2
+#define ARCH_ALIGN_INT_MOD 4
+#define ARCH_ALIGN_LONG_MOD 4
+#define ARCH_ALIGN_PTR_MOD 4
+#define ARCH_ALIGN_FLOAT_MOD 4
+#define ARCH_ALIGN_DOUBLE_MOD 8
+
+	 /* ---------------- Scalar sizes ---------------- */
+
+#define ARCH_LOG2_SIZEOF_CHAR 0
+#define ARCH_LOG2_SIZEOF_SHORT 1
+#define ARCH_LOG2_SIZEOF_INT 2
+#define ARCH_LOG2_SIZEOF_LONG 2
+#define ARCH_LOG2_SIZEOF_LONG_LONG 3
+#define ARCH_SIZEOF_GX_COLOR_INDEX 8
+#define ARCH_SIZEOF_PTR 4
+#define ARCH_SIZEOF_FLOAT 4
+#define ARCH_SIZEOF_DOUBLE 8
+#define ARCH_FLOAT_MANTISSA_BITS 24
+#define ARCH_DOUBLE_MANTISSA_BITS 53
+
+	 /* ---------------- Unsigned max values ---------------- */
+
+#define ARCH_MAX_UCHAR ((unsigned char)0xff + (unsigned char)0)
+#define ARCH_MAX_USHORT ((unsigned short)0xffff + (unsigned short)0)
+#define ARCH_MAX_UINT ((unsigned int)~0 + (unsigned int)0)
+#define ARCH_MAX_ULONG ((unsigned long)~0L + (unsigned long)0)
+
+	 /* ---------------- Miscellaneous ---------------- */
+
+#define ARCH_IS_BIG_ENDIAN 1
+#define ARCH_PTRS_ARE_SIGNED 0
+#define ARCH_FLOATS_ARE_IEEE 1
+#define ARCH_ARITH_RSHIFT 2
+#define ARCH_DIV_NEG_POS_TRUNCATES 1
meta/recipes-extended/ghostscript/mips/soobjarch.h new file +40 -0
new file mode 100644
index 0000000..359097f
@@ -0,0 +1,40 @@
+/* Parameters derived from machine and compiler architecture. */
+/* This file is generated mechanically by genarch.c. */
+
+	 /* ---------------- Scalar alignments ---------------- */
+
+#define ARCH_ALIGN_SHORT_MOD 2
+#define ARCH_ALIGN_INT_MOD 4
+#define ARCH_ALIGN_LONG_MOD 4
+#define ARCH_ALIGN_PTR_MOD 4
+#define ARCH_ALIGN_FLOAT_MOD 4
+#define ARCH_ALIGN_DOUBLE_MOD 8
+
+	 /* ---------------- Scalar sizes ---------------- */
+
+#define ARCH_LOG2_SIZEOF_CHAR 0
+#define ARCH_LOG2_SIZEOF_SHORT 1
+#define ARCH_LOG2_SIZEOF_INT 2
+#define ARCH_LOG2_SIZEOF_LONG 2
+#define ARCH_LOG2_SIZEOF_LONG_LONG 3
+#define ARCH_SIZEOF_GX_COLOR_INDEX 8
+#define ARCH_SIZEOF_PTR 4
+#define ARCH_SIZEOF_FLOAT 4
+#define ARCH_SIZEOF_DOUBLE 8
+#define ARCH_FLOAT_MANTISSA_BITS 24
+#define ARCH_DOUBLE_MANTISSA_BITS 53
+
+	 /* ---------------- Unsigned max values ---------------- */
+
+#define ARCH_MAX_UCHAR ((unsigned char)0xff + (unsigned char)0)
+#define ARCH_MAX_USHORT ((unsigned short)0xffff + (unsigned short)0)
+#define ARCH_MAX_UINT ((unsigned int)~0 + (unsigned int)0)
+#define ARCH_MAX_ULONG ((unsigned long)~0L + (unsigned long)0)
+
+	 /* ---------------- Miscellaneous ---------------- */
+
+#define ARCH_IS_BIG_ENDIAN 1
+#define ARCH_PTRS_ARE_SIGNED 0
+#define ARCH_FLOATS_ARE_IEEE 1
+#define ARCH_ARITH_RSHIFT 2
+#define ARCH_DIV_NEG_POS_TRUNCATES 1
meta/recipes-extended/ghostscript/powerpc/objarch.h new file +40 -0
new file mode 100644
index 0000000..359097f
@@ -0,0 +1,40 @@
+/* Parameters derived from machine and compiler architecture. */
+/* This file is generated mechanically by genarch.c. */
+
+	 /* ---------------- Scalar alignments ---------------- */
+
+#define ARCH_ALIGN_SHORT_MOD 2
+#define ARCH_ALIGN_INT_MOD 4
+#define ARCH_ALIGN_LONG_MOD 4
+#define ARCH_ALIGN_PTR_MOD 4
+#define ARCH_ALIGN_FLOAT_MOD 4
+#define ARCH_ALIGN_DOUBLE_MOD 8
+
+	 /* ---------------- Scalar sizes ---------------- */
+
+#define ARCH_LOG2_SIZEOF_CHAR 0
+#define ARCH_LOG2_SIZEOF_SHORT 1
+#define ARCH_LOG2_SIZEOF_INT 2
+#define ARCH_LOG2_SIZEOF_LONG 2
+#define ARCH_LOG2_SIZEOF_LONG_LONG 3
+#define ARCH_SIZEOF_GX_COLOR_INDEX 8
+#define ARCH_SIZEOF_PTR 4
+#define ARCH_SIZEOF_FLOAT 4
+#define ARCH_SIZEOF_DOUBLE 8
+#define ARCH_FLOAT_MANTISSA_BITS 24
+#define ARCH_DOUBLE_MANTISSA_BITS 53
+
+	 /* ---------------- Unsigned max values ---------------- */
+
+#define ARCH_MAX_UCHAR ((unsigned char)0xff + (unsigned char)0)
+#define ARCH_MAX_USHORT ((unsigned short)0xffff + (unsigned short)0)
+#define ARCH_MAX_UINT ((unsigned int)~0 + (unsigned int)0)
+#define ARCH_MAX_ULONG ((unsigned long)~0L + (unsigned long)0)
+
+	 /* ---------------- Miscellaneous ---------------- */
+
+#define ARCH_IS_BIG_ENDIAN 1
+#define ARCH_PTRS_ARE_SIGNED 0
+#define ARCH_FLOATS_ARE_IEEE 1
+#define ARCH_ARITH_RSHIFT 2
+#define ARCH_DIV_NEG_POS_TRUNCATES 1
meta/recipes-extended/ghostscript/powerpc/soobjarch.h new file +40 -0
new file mode 100644
index 0000000..359097f
@@ -0,0 +1,40 @@
+/* Parameters derived from machine and compiler architecture. */
+/* This file is generated mechanically by genarch.c. */
+
+	 /* ---------------- Scalar alignments ---------------- */
+
+#define ARCH_ALIGN_SHORT_MOD 2
+#define ARCH_ALIGN_INT_MOD 4
+#define ARCH_ALIGN_LONG_MOD 4
+#define ARCH_ALIGN_PTR_MOD 4
+#define ARCH_ALIGN_FLOAT_MOD 4
+#define ARCH_ALIGN_DOUBLE_MOD 8
+
+	 /* ---------------- Scalar sizes ---------------- */
+
+#define ARCH_LOG2_SIZEOF_CHAR 0
+#define ARCH_LOG2_SIZEOF_SHORT 1
+#define ARCH_LOG2_SIZEOF_INT 2
+#define ARCH_LOG2_SIZEOF_LONG 2
+#define ARCH_LOG2_SIZEOF_LONG_LONG 3
+#define ARCH_SIZEOF_GX_COLOR_INDEX 8
+#define ARCH_SIZEOF_PTR 4
+#define ARCH_SIZEOF_FLOAT 4
+#define ARCH_SIZEOF_DOUBLE 8
+#define ARCH_FLOAT_MANTISSA_BITS 24
+#define ARCH_DOUBLE_MANTISSA_BITS 53
+
+	 /* ---------------- Unsigned max values ---------------- */
+
+#define ARCH_MAX_UCHAR ((unsigned char)0xff + (unsigned char)0)
+#define ARCH_MAX_USHORT ((unsigned short)0xffff + (unsigned short)0)
+#define ARCH_MAX_UINT ((unsigned int)~0 + (unsigned int)0)
+#define ARCH_MAX_ULONG ((unsigned long)~0L + (unsigned long)0)
+
+	 /* ---------------- Miscellaneous ---------------- */
+
+#define ARCH_IS_BIG_ENDIAN 1
+#define ARCH_PTRS_ARE_SIGNED 0
+#define ARCH_FLOATS_ARE_IEEE 1
+#define ARCH_ARITH_RSHIFT 2
+#define ARCH_DIV_NEG_POS_TRUNCATES 1
meta/recipes-extended/ghostscript/x86_64/objarch.h new file +40 -0
new file mode 100644
index 0000000..a05de29
@@ -0,0 +1,40 @@
+/* Parameters derived from machine and compiler architecture. */
+/* This file is generated mechanically by genarch.c. */
+
+	 /* ---------------- Scalar alignments ---------------- */
+
+#define ARCH_ALIGN_SHORT_MOD 2
+#define ARCH_ALIGN_INT_MOD 4
+#define ARCH_ALIGN_LONG_MOD 8
+#define ARCH_ALIGN_PTR_MOD 8
+#define ARCH_ALIGN_FLOAT_MOD 4
+#define ARCH_ALIGN_DOUBLE_MOD 8
+
+	 /* ---------------- Scalar sizes ---------------- */
+
+#define ARCH_LOG2_SIZEOF_CHAR 0
+#define ARCH_LOG2_SIZEOF_SHORT 1
+#define ARCH_LOG2_SIZEOF_INT 2
+#define ARCH_LOG2_SIZEOF_LONG 3
+#define ARCH_LOG2_SIZEOF_LONG_LONG 3
+#define ARCH_SIZEOF_GX_COLOR_INDEX 8
+#define ARCH_SIZEOF_PTR 8
+#define ARCH_SIZEOF_FLOAT 4
+#define ARCH_SIZEOF_DOUBLE 8
+#define ARCH_FLOAT_MANTISSA_BITS 24
+#define ARCH_DOUBLE_MANTISSA_BITS 53
+
+	 /* ---------------- Unsigned max values ---------------- */
+
+#define ARCH_MAX_UCHAR ((unsigned char)0xff + (unsigned char)0)
+#define ARCH_MAX_USHORT ((unsigned short)0xffff + (unsigned short)0)
+#define ARCH_MAX_UINT ((unsigned int)~0 + (unsigned int)0)
+#define ARCH_MAX_ULONG ((unsigned long)~0L + (unsigned long)0)
+
+	 /* ---------------- Miscellaneous ---------------- */
+
+#define ARCH_IS_BIG_ENDIAN 0
+#define ARCH_PTRS_ARE_SIGNED 0
+#define ARCH_FLOATS_ARE_IEEE 1
+#define ARCH_ARITH_RSHIFT 2
+#define ARCH_DIV_NEG_POS_TRUNCATES 1
meta/recipes-extended/ghostscript/x86_64/soobjarch.h new file +40 -0
new file mode 100644
index 0000000..a05de29
@@ -0,0 +1,40 @@
+/* Parameters derived from machine and compiler architecture. */
+/* This file is generated mechanically by genarch.c. */
+
+	 /* ---------------- Scalar alignments ---------------- */
+
+#define ARCH_ALIGN_SHORT_MOD 2
+#define ARCH_ALIGN_INT_MOD 4
+#define ARCH_ALIGN_LONG_MOD 8
+#define ARCH_ALIGN_PTR_MOD 8
+#define ARCH_ALIGN_FLOAT_MOD 4
+#define ARCH_ALIGN_DOUBLE_MOD 8
+
+	 /* ---------------- Scalar sizes ---------------- */
+
+#define ARCH_LOG2_SIZEOF_CHAR 0
+#define ARCH_LOG2_SIZEOF_SHORT 1
+#define ARCH_LOG2_SIZEOF_INT 2
+#define ARCH_LOG2_SIZEOF_LONG 3
+#define ARCH_LOG2_SIZEOF_LONG_LONG 3
+#define ARCH_SIZEOF_GX_COLOR_INDEX 8
+#define ARCH_SIZEOF_PTR 8
+#define ARCH_SIZEOF_FLOAT 4
+#define ARCH_SIZEOF_DOUBLE 8
+#define ARCH_FLOAT_MANTISSA_BITS 24
+#define ARCH_DOUBLE_MANTISSA_BITS 53
+
+	 /* ---------------- Unsigned max values ---------------- */
+
+#define ARCH_MAX_UCHAR ((unsigned char)0xff + (unsigned char)0)
+#define ARCH_MAX_USHORT ((unsigned short)0xffff + (unsigned short)0)
+#define ARCH_MAX_UINT ((unsigned int)~0 + (unsigned int)0)
+#define ARCH_MAX_ULONG ((unsigned long)~0L + (unsigned long)0)
+
+	 /* ---------------- Miscellaneous ---------------- */
+
+#define ARCH_IS_BIG_ENDIAN 0
+#define ARCH_PTRS_ARE_SIGNED 0
+#define ARCH_FLOATS_ARE_IEEE 1
+#define ARCH_ARITH_RSHIFT 2
+#define ARCH_DIV_NEG_POS_TRUNCATES 1
Signature · 1 line
1.7.5.1.300.gc565c
Applied
#2 lore raw
In reply to Kang Kai
Quoted 37 lines · Kang Kai

From: Kang Kai<[email protected]>

Hi Richard,

I update the patches with your opinion, thanks!

When test lsb on ppc find that gs can't run. The root cause is gs determines some target configuration on build system. According to the document of ghostscript,
http://pages.cs.wisc.edu/~ghost/doc/cvs/Make.htm#Cross-compiling
when cross compile ghostscript need some manual work.
So import patches from WindRiver Linux to make sure ghostscript can be cross compiled, and spit the patches into arch/[so]obj.h source files.

The following changes since commit 7706d5d844db2725f4118207d90e302679eacdfe:

   linux-yocto/meta-yocto: fix gcc 4.6.0 compilation failures (2011-05-19 17:33:50 -0700)

are available in the git repository at:
git://git.pokylinux.org/poky-contrib.git kangkai/distro
http://git.pokylinux.org/cgit.cgi//log/?h=kangkai/distro

Kang Kai (1):
ghostscript: fix run failure on mpc8315e

  meta/recipes-extended/ghostscript/arm/objarch.h    |   40 +++++++++++++++++++
  meta/recipes-extended/ghostscript/arm/soobjarch.h  |   40 +++++++++++++++++++
  .../ghostscript/ghostscript-9.02-genarch.patch     |   27 +++++++++++++
  .../ghostscript/ghostscript_9.02.bb                |   22 +++++++++-
  meta/recipes-extended/ghostscript/i586/objarch.h   |   41 ++++++++++++++++++++
  meta/recipes-extended/ghostscript/i586/soobjarch.h |   41 ++++++++++++++++++++
  meta/recipes-extended/ghostscript/mips/objarch.h   |   40 +++++++++++++++++++
  meta/recipes-extended/ghostscript/mips/soobjarch.h |   40 +++++++++++++++++++
  .../recipes-extended/ghostscript/powerpc/objarch.h |   40 +++++++++++++++++++
  .../ghostscript/powerpc/soobjarch.h                |   40 +++++++++++++++++++
  meta/recipes-extended/ghostscript/x86_64/objarch.h |   40 +++++++++++++++++++
  .../ghostscript/x86_64/soobjarch.h                 |   40 +++++++++++++++++++
  12 files changed, 448 insertions(+), 3 deletions(-)
Quoted 12 lines

create mode 100644 meta/recipes-extended/ghostscript/arm/objarch.h
create mode 100644 meta/recipes-extended/ghostscript/arm/soobjarch.h
create mode 100644 meta/recipes-extended/ghostscript/ghostscript/ghostscript-9.02-genarch.patch create mode 100644 meta/recipes-extended/ghostscript/i586/objarch.h
create mode 100644 meta/recipes-extended/ghostscript/i586/soobjarch.h
create mode 100644 meta/recipes-extended/ghostscript/mips/objarch.h
create mode 100644 meta/recipes-extended/ghostscript/mips/soobjarch.h
create mode 100644 meta/recipes-extended/ghostscript/powerpc/objarch.h
create mode 100644 meta/recipes-extended/ghostscript/powerpc/soobjarch.h
create mode 100644 meta/recipes-extended/ghostscript/x86_64/objarch.h
create mode 100644 meta/recipes-extended/ghostscript/x86_64/soobjarch.h

Merged into oe-core and poky

Thanks

Sau!

#3 lore raw
In reply to Kang Kai
Quoted 13 lines · Kang Kai

From: Kang Kai<[email protected]>

Hi Richard,

I update the patches with your opinion, thanks!

When test lsb on ppc find that gs can't run. The root cause is gs determines some target configuration on build system. According to the document of ghostscript,
http://pages.cs.wisc.edu/~ghost/doc/cvs/Make.htm#Cross-compiling
when cross compile ghostscript need some manual work.
So import patches from WindRiver Linux to make sure ghostscript can be cross compiled, and spit the patches into arch/[so]obj.h source files.

Quoted 4 lines

The following changes since commit 7706d5d844db2725f4118207d90e302679eacdfe:

   linux-yocto/meta-yocto: fix gcc 4.6.0 compilation failures (2011-05-19 17:33:50 -0700)

Kang Kai:

I think I must have merged the working patch, when I started to test with your enable ghostscipt patch I got a fetch error on ghostscript, I think we some how missed the changes you made for obarch.h and soobjarch.h

I get the following error:ERROR: Logfile of failure stored in:

/intel/poky/builds/world/tmp/work/i686-linux/ghostscript-native-9.02-r1/temp/log.do_fetch.11982
Log data follows:
| ERROR: Function 'Fetcher failure for URL: 'file://objarch.h'. Unable to fetch URL file://objarch.h from any source.' failed | ERROR: Function 'Fetcher failure for URL: 'file://objarch.h'. Unable to fetch URL file://objarch.h from any source.' failed
NOTE: package ghostscript-native-9.02-r1: task do_fetch: Failed
ERROR: Task 343 (virtual:native:/intel/poky/distro/meta/recipes-extended/ghostscript/ghostscript_9.02.bb, do_fetch) failed with exit code '1'

Please review your ghostscript and verify that it is correct.

Thanks
Sau!

Quoted 32 lines

are available in the git repository at:
git://git.pokylinux.org/poky-contrib.git kangkai/distro
http://git.pokylinux.org/cgit.cgi//log/?h=kangkai/distro

Kang Kai (1):
ghostscript: fix run failure on mpc8315e

  meta/recipes-extended/ghostscript/arm/objarch.h    |   40 +++++++++++++++++++
  meta/recipes-extended/ghostscript/arm/soobjarch.h  |   40 +++++++++++++++++++
  .../ghostscript/ghostscript-9.02-genarch.patch     |   27 +++++++++++++
  .../ghostscript/ghostscript_9.02.bb                |   22 +++++++++-
  meta/recipes-extended/ghostscript/i586/objarch.h   |   41 ++++++++++++++++++++
  meta/recipes-extended/ghostscript/i586/soobjarch.h |   41 ++++++++++++++++++++
  meta/recipes-extended/ghostscript/mips/objarch.h   |   40 +++++++++++++++++++
  meta/recipes-extended/ghostscript/mips/soobjarch.h |   40 +++++++++++++++++++
  .../recipes-extended/ghostscript/powerpc/objarch.h |   40 +++++++++++++++++++
  .../ghostscript/powerpc/soobjarch.h                |   40 +++++++++++++++++++
  meta/recipes-extended/ghostscript/x86_64/objarch.h |   40 +++++++++++++++++++
  .../ghostscript/x86_64/soobjarch.h                 |   40 +++++++++++++++++++
  12 files changed, 448 insertions(+), 3 deletions(-)

create mode 100644 meta/recipes-extended/ghostscript/arm/objarch.h
create mode 100644 meta/recipes-extended/ghostscript/arm/soobjarch.h
create mode 100644 meta/recipes-extended/ghostscript/ghostscript/ghostscript-9.02-genarch.patch create mode 100644 meta/recipes-extended/ghostscript/i586/objarch.h
create mode 100644 meta/recipes-extended/ghostscript/i586/soobjarch.h
create mode 100644 meta/recipes-extended/ghostscript/mips/objarch.h
create mode 100644 meta/recipes-extended/ghostscript/mips/soobjarch.h
create mode 100644 meta/recipes-extended/ghostscript/powerpc/objarch.h
create mode 100644 meta/recipes-extended/ghostscript/powerpc/soobjarch.h
create mode 100644 meta/recipes-extended/ghostscript/x86_64/objarch.h
create mode 100644 meta/recipes-extended/ghostscript/x86_64/soobjarch.h

author
#4 lore raw
Quoted 14 lines · Saul Wold
Quoted 13 lines · Kang Kai

From: Kang Kai<[email protected]>

Hi Richard,

I update the patches with your opinion, thanks!

When test lsb on ppc find that gs can't run. The root cause is gs determines some target configuration on build system. According to the document of ghostscript,
http://pages.cs.wisc.edu/~ghost/doc/cvs/Make.htm#Cross-compiling
when cross compile ghostscript need some manual work.
So import patches from WindRiver Linux to make sure ghostscript can be cross compiled, and spit the patches into arch/[so]obj.h source files.

Quoted 5 lines
Quoted 4 lines

The following changes since commit 7706d5d844db2725f4118207d90e302679eacdfe:

linux-yocto/meta-yocto: fix gcc 4.6.0 compilation failures (2011-05-19 17:33:50 -0700)

Hi Saul,

Quoted 5 lines

I think I must have merged the working patch, when I started to test with your enable ghostscipt patch I got a fetch error on ghostscript, I think we some how missed the changes you made for obarch.h and soobjarch.h

I get the following error:ERROR: Logfile of failure stored in:

Quoted 7 lines

/intel/poky/builds/world/tmp/work/i686-linux/ghostscript-native-9.02-r1/temp/log.do_fetch.11982

Log data follows:
| ERROR: Function 'Fetcher failure for URL: 'file://objarch.h'. Unable to fetch URL file://objarch.h from any source.' failed | ERROR: Function 'Fetcher failure for URL: 'file://objarch.h'. Unable to fetch URL file://objarch.h from any source.' failed
NOTE: package ghostscript-native-9.02-r1: task do_fetch: Failed
ERROR: Task 343 (virtual:native:/intel/poky/distro/meta/recipes-extended/ghostscript/ghostscript_9.02.bb, do_fetch) failed with exit code '1'

The reason cause failure is your build machine arch is "i686" not provided by ghostscript source files. And run 'cp i586 i686' will fix this issue.

But I am not sure this is the right solution, it should not be affected by build machine. For example, if somebody build yocto on a i486 machine, it will fail too.

Maybe I need to remove the native package dependency just like what is done in oe's gs recipe and send it later.

Thanks & Regards,
Kai

Quoted 46 lines

Please review your ghostscript and verify that it is correct.

Thanks
Sau!

Quoted 39 lines

are available in the git repository at:
git://git.pokylinux.org/poky-contrib.git kangkai/distro
http://git.pokylinux.org/cgit.cgi//log/?h=kangkai/distro

Kang Kai (1):
ghostscript: fix run failure on mpc8315e

meta/recipes-extended/ghostscript/arm/objarch.h | 40 +++++++++++++++++++ meta/recipes-extended/ghostscript/arm/soobjarch.h | 40
+++++++++++++++++++
.../ghostscript/ghostscript-9.02-genarch.patch | 27 +++++++++++++ .../ghostscript/ghostscript_9.02.bb | 22 +++++++++- meta/recipes-extended/ghostscript/i586/objarch.h | 41
++++++++++++++++++++
meta/recipes-extended/ghostscript/i586/soobjarch.h | 41
++++++++++++++++++++
meta/recipes-extended/ghostscript/mips/objarch.h | 40
+++++++++++++++++++
meta/recipes-extended/ghostscript/mips/soobjarch.h | 40
+++++++++++++++++++
.../recipes-extended/ghostscript/powerpc/objarch.h | 40
+++++++++++++++++++
.../ghostscript/powerpc/soobjarch.h | 40 +++++++++++++++++++ meta/recipes-extended/ghostscript/x86_64/objarch.h | 40
+++++++++++++++++++
.../ghostscript/x86_64/soobjarch.h | 40 +++++++++++++++++++

12 files changed, 448 insertions(+), 3 deletions(-)

create mode 100644 meta/recipes-extended/ghostscript/arm/objarch.h
create mode 100644 meta/recipes-extended/ghostscript/arm/soobjarch.h
create mode 100644 meta/recipes-extended/ghostscript/ghostscript/ghostscript-9.02-genarch.patch create mode 100644 meta/recipes-extended/ghostscript/i586/objarch.h
create mode 100644 meta/recipes-extended/ghostscript/i586/soobjarch.h
create mode 100644 meta/recipes-extended/ghostscript/mips/objarch.h
create mode 100644 meta/recipes-extended/ghostscript/mips/soobjarch.h
create mode 100644 meta/recipes-extended/ghostscript/powerpc/objarch.h
create mode 100644 meta/recipes-extended/ghostscript/powerpc/soobjarch.h
create mode 100644 meta/recipes-extended/ghostscript/x86_64/objarch.h
create mode 100644 meta/recipes-extended/ghostscript/x86_64/soobjarch.h