Skip to contentSkip to conversation

sjf2410-linux-native: Do not include sys/io.h

PATCH New Khem Raj 1 participant 4 messages Aug 6, 2019

lore
Share & tools
lore

Khem Raj

author
#0 lore raw

PATCH 1/4 sjf2410-linux-native: Do not include sys/io.h

This file is non-existent on non-x86 build hosts Fixes
ppt.c:8:10: fatal error: sys/io.h: No such file or directory

 #include <sys/io.h>
          ^~~~~~~~~~
---
 .../0001-ppt.c-Do-not-include-sys-io.h.patch  | 28 +++++++++++++++++++
 .../sjf2410-linux-native_svn.bb               |  4 ++-
 2 files changed, 31 insertions(+), 1 deletion(-)
 create mode 100644 meta-oe/recipes-support/samsung-soc-utils/files/0001-ppt.c-Do-not-include-sys-io.h.patch
meta-oe/recipes-support/samsung-soc-utils/files/0001-ppt.c-Do-not-include-sys-io.h.patch new file +28 -0
new file mode 100644
index 0000000000..4e6c250415
@@ -0,0 +1,28 @@
+From fd244ae648789591f0fb79e74d2b8f6c5b15d6e8 Mon Sep 17 00:00:00 2001
+From: Khem Raj <[email protected]>
+Date: Tue, 6 Aug 2019 00:47:14 +0000
+Subject: [PATCH] ppt.c: Do not include sys/io.h
+
+newer versions of glibc has removed it
+
+Upstream-Status: Pending
+Signed-off-by: Khem Raj <[email protected]>
+---
+ ppt.c | 1 -
+ 1 file changed, 1 deletion(-)
+
+diff --git a/ppt.c b/ppt.c
+index 0bae2d0..0ef279f 100644
+--- a/ppt.c
++++ b/ppt.c
+@@ -5,7 +5,6 @@
+ #else
+ #include <unistd.h>
+ #include <stdlib.h>
+-#include <sys/io.h>
+ #include <linux/parport.h>
+ #include <linux/ppdev.h>
+ #include <sys/ioctl.h>
+-- 
+2.17.1
+
meta-oe/recipes-support/samsung-soc-utils/sjf2410-linux-native_svn.bb +3 -1
index 2d5935dd3c..c56c8b9dd8 100644
@@ -7,7 +7,9 @@ SRCREV = "4268"
 PV = "0.1+svnr${SRCPV}"
 PR = "r1"
 
-SRC_URI = "svn://svn.openmoko.org/trunk/src/host/;module=sjf2410-linux;protocol=http"
+SRC_URI = "svn://svn.openmoko.org/trunk/src/host/;module=sjf2410-linux;protocol=http \
+           file://0001-ppt.c-Do-not-include-sys-io.h.patch \
+          "
 S = "${WORKDIR}/sjf2410-linux"
 
 inherit native deploy
Signature · 1 line
2.22.0
author
#1 lore raw

PATCH 2/4 gradm: Upgrade to 3.1-201903191516 release

Pass empty LIBS to build, otherwise its computed using uname logic which does not work in cross builds [1]

Rename recipe to have snapshot number in PV otherwise its not easy to identify upgrade

[1] https://cvsweb.grsecurity.net/?p=gradm.git;a=commitdiff;h=ef7ff56de7d31b4db1604f0a10fc2c5541a1bff7

---
 .../gradm/{gradm_3.1.bb => gradm_3.1-201903191516.bb}     | 8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)
 rename meta-oe/recipes-support/gradm/{gradm_3.1.bb => gradm_3.1-201903191516.bb} (84%)
meta-oe/recipes-support/gradm/gradm_3.1-201903191516.bb renamed from meta-oe/recipes-support/gradm/gradm_3.1.bb +5 -3
similarity index 84%
rename from meta-oe/recipes-support/gradm/gradm_3.1.bb
rename to meta-oe/recipes-support/gradm/gradm_3.1-201903191516.bb
index a7d0607f8d..7ed46f82c5 100644
@@ -11,12 +11,12 @@ LICENSE = "GPL-2.0"
 LIC_FILES_CHKSUM = "file://LICENSE;md5=4641e94ec96f98fabc56ff9cc48be14b"
 DEPENDS = "flex-native bison-native ${@bb.utils.contains('DISTRO_FEATURES', 'pam', 'libpam', '', d)}"
 
-SRC_URI = "http://grsecurity.net/stable/${BP}-201507191652.tar.gz \
+SRC_URI = "http://grsecurity.net/stable/${BP}.tar.gz \
            file://0001-Makefile-remove-strip.patch \
            file://0001-Makefile-Append-instead-of-overriding-LDFLAGS.patch \
            "
-SRC_URI[md5sum] = "ecec72d3a9b6d84c00eda97957b707b6"
-SRC_URI[sha256sum] = "2f14c357bf0459e502a4e108b76c3f6240aa484762d07bb1687796b9b9297a50"
+SRC_URI[md5sum] = "5099c715433981d5a3eed8ded7c5bbc0"
+SRC_URI[sha256sum] = "d3a0b6383ff97a2054941d71133c737efae66afdd8eef59346c031ae15c75ff3"
 
 S = "${WORKDIR}/gradm"
 
@@ -24,6 +24,7 @@ inherit autotools-brokensep
 
 do_compile() {
     oe_runmake 'CC=${CC}'                               \
+               'LIBS='                                  \
                'OPT_FLAGS=${CFLAGS}'                    \
                'LLEX=${STAGING_BINDIR_NATIVE}/lex'      \
                'FLEX=${STAGING_BINDIR_NATIVE}/flex'     \
@@ -34,6 +35,7 @@ do_compile() {
 do_install() {
     oe_runmake 'CC=${CC}'                               \
                'DESTDIR=${D}'                           \
+               'LIBS='                                  \
                'LLEX=${STAGING_BINDIR_NATIVE}/lex'      \
                'FLEX=${STAGING_BINDIR_NATIVE}/flex'     \
                'BISON=${STAGING_BINDIR_NATIVE}/bison'   \
Signature · 1 line
2.22.0
author
#2 lore raw

PATCH 3/4 pmdk: Fix packaging errors when building on non-x86 host

In reply to Khem Raj

Fixes
ERROR: QA Issue: pmdk: Files/directories were installed but not shipped in any package:
/usr/x86_64-linux-gnu
/usr/lib/pmdk_debug/libpmemobj.so.1
/usr/lib/pmdk_debug/libpmemblk.so.1
/usr/lib/pmdk_debug/libvmem.so.1
/usr/lib/pmdk_debug/libvmmalloc.so
/usr/lib/pmdk_debug/libpmempool.so

....

/usr/x86_64-linux-gnu/include/libpmemobj/iterator_base.h /usr/x86_64-linux-gnu/include/libpmemobj/tx_base.h /usr/x86_64-linux-gnu/include/libpmemobj/base.h /usr/x86_64-linux-gnu/include/libpmemobj/lists_atomic_base.h

---
 meta-oe/recipes-extended/pmdk/pmdk_1.6.bb | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
meta-oe/recipes-extended/pmdk/pmdk_1.6.bb +2 -2
index c20bdf6d1e..c8688b2c63 100644
@@ -35,14 +35,14 @@ do_install() {
 	oe_runmake prefix=${prefix} DESTDIR=${D} install
 
 	# Remove uneeded files
-	rm -rf ${D}/usr/lib64/pmdk_debug
+	rm -rf ${D}/usr/${baselib}/pmdk_debug
 }
 
 # Include these by default otherwise the SDK is not very useful
 FILES_${PN} += "${bindir}/pmempool ${bindir}/daxio"
 FILES_${PN} += "${libdir}/*so*"
 FILES_${PN} += "${libdir}/pkgconfig/*.pc"
-FILES_${PN} += "${includedir}/libpmemobj++/* ${includedir}/libpmemobj/*"
+FILES_${PN} += "${includedir}/libpmemobj++/* ${includedir}/libpmemobj/* /usr/*/include/"
 FILES_${PN} += "/usr/etc"
 FILES_${PN} += "/usr/share"
 
Signature · 1 line
2.22.0
author
#3 lore raw

PATCH 4/4 kpatch: Pass ARCH from environment

In reply to Khem Raj

If not passed then it computes arch from uname and uname will be wrong on cross compiles when target != host

---
 meta-oe/recipes-kernel/kpatch/kpatch.inc | 1 +
 1 file changed, 1 insertion(+)
meta-oe/recipes-kernel/kpatch/kpatch.inc +1 -0
index cd819f31f8..e6c4f64ce1 100644
@@ -16,6 +16,7 @@ EXTRA_OEMAKE = " \
 	MANDIR=${D}${mandir}/man1 \
 	SYSTEMDDIR=${D}${systemd_system_unitdir} \
 	DESTDIR=${D} \
+	ARCH=${TARGET_ARCH} \
 	BUILDMOD=no \
 	CC='${CC}' \
 	"
Signature · 1 line
2.22.0