aboutsummaryrefslogtreecommitdiffstats
path: root/meta-initramfs/recipes-devtools/klibc
diff options
context:
space:
mode:
authorAndrea Adami <andrea.adami@gmail.com>2012-04-24 00:16:12 +0000
committerKoen Kooi <koen@dominion.thruhere.net>2012-04-24 08:07:41 +0200
commite360922f652af30c4222f447b5145706df375bfc (patch)
treed5e04a44f11594206903d713fdbc3dc6cc6ccb7d /meta-initramfs/recipes-devtools/klibc
parenta2c1414b58723f6ec387ceb43b7575fd4f21d90a (diff)
downloadmeta-openembedded-contrib-e360922f652af30c4222f447b5145706df375bfc.tar.gz
meta-openembedded-contrib-e360922f652af30c4222f447b5145706df375bfc.tar.bz2
meta-openembedded-contrib-e360922f652af30c4222f447b5145706df375bfc.zip
klibc_1.5.25: add patches to build with 3.2 kernel headers
* kernel_3.2__aligned_u64.patch is already upstream * hack around the missing headers (now in /generated/asm) * bump INC_PR * waiting for klibc_2.0 release Signed-off-by: Andrea Adami <andrea.adami@gmail.com> Signed-off-by: Koen Kooi <koen@dominion.thruhere.net>
Diffstat (limited to 'meta-initramfs/recipes-devtools/klibc')
-rw-r--r--meta-initramfs/recipes-devtools/klibc/klibc-1.5.25/kernel_3.2__aligned_u64.patch46
-rw-r--r--meta-initramfs/recipes-devtools/klibc/klibc.inc3
-rw-r--r--meta-initramfs/recipes-devtools/klibc/klibc_1.5.25.bb13
3 files changed, 61 insertions, 1 deletions
diff --git a/meta-initramfs/recipes-devtools/klibc/klibc-1.5.25/kernel_3.2__aligned_u64.patch b/meta-initramfs/recipes-devtools/klibc/klibc-1.5.25/kernel_3.2__aligned_u64.patch
new file mode 100644
index 0000000000..c2369cd8cf
--- /dev/null
+++ b/meta-initramfs/recipes-devtools/klibc/klibc-1.5.25/kernel_3.2__aligned_u64.patch
@@ -0,0 +1,46 @@
+From 7f47891c1678874cccca66cd25e6a13486c86d78 Mon Sep 17 00:00:00 2001
+From: =?utf8?q?Maciej=20=C5=BBenczykowski?= <zenczykowski@gmail.com>
+Date: Sun, 6 Nov 2011 14:33:40 -0800
+Subject: [PATCH] [klibc] include: [sys/types.h] -> linux/types.h and
+ __aligned_u64
+
+When building klibc 1.5.25 against linux/master (ie. post 3.1) I'm seeing:
+
+klibc/generated/include/linux/if_packet.h:176: error: expected
+specifier-qualifier-list before '__aligned_u64'
+
+which seems to come from upstream commits:
+0d4691ce112be025019999df5f2a5e00c03f03c2 remotes/linux/master~90^2~408 (origin)
+96c131842aab45b5d139d0bcb417796819f5ee92 remotes/linux/master~90^2~169
+ (change from aligned_u64 to __aligned_u64)
+
+and collides with klibc/usr/include/sys/types.h
+
+/* Keeps linux/types.h from getting included elsewhere */
+#define _LINUX_TYPES_H
+
+not defining __aligned_u64 like the kernel's include/linux/types.h does.
+
+Signed-off-by: maximilian attems <max@stro.at>
+---
+ usr/include/sys/types.h | 4 ++++
+ 1 files changed, 4 insertions(+), 0 deletions(-)
+
+diff --git a/usr/include/sys/types.h b/usr/include/sys/types.h
+index 6780ed1..3a4c738 100644
+--- a/usr/include/sys/types.h
++++ b/usr/include/sys/types.h
+@@ -100,6 +100,10 @@ typedef uint16_t __sum16;
+ typedef uint32_t __sum32;
+ typedef uint64_t __sum64;
+
++#define __aligned_u64 __u64 __attribute__((aligned(8)))
++#define __aligned_be64 __be64 __attribute__((aligned(8)))
++#define __aligned_le64 __le64 __attribute__((aligned(8)))
++
+ /*
+ * Some headers seem to require this...
+ */
+--
+1.7.6.5
+
diff --git a/meta-initramfs/recipes-devtools/klibc/klibc.inc b/meta-initramfs/recipes-devtools/klibc/klibc.inc
index 0f7cbbe965..6a15e0cd8e 100644
--- a/meta-initramfs/recipes-devtools/klibc/klibc.inc
+++ b/meta-initramfs/recipes-devtools/klibc/klibc.inc
@@ -12,7 +12,7 @@ PACKAGE_ARCH = "${MACHINE_ARCH}"
# debugsources.list: No such file or directory:
INHIBIT_PACKAGE_DEBUG_SPLIT = "1"
-INC_PR = "r2"
+INC_PR = "r3"
KLIBC_ARCH = '${TARGET_ARCH}'
KLIBC_ARCH_armeb = 'arm'
@@ -34,6 +34,7 @@ SRC_URI += "file://fstype-sane-vfat-and-jffs2-for-1.5.patch \
file://dash_readopt.patch \
file://wc.patch \
file://staging.patch \
+ file://kernel_3.2__aligned_u64.patch \
"
S = "${WORKDIR}/git"
diff --git a/meta-initramfs/recipes-devtools/klibc/klibc_1.5.25.bb b/meta-initramfs/recipes-devtools/klibc/klibc_1.5.25.bb
index 8a50628417..ae437539ae 100644
--- a/meta-initramfs/recipes-devtools/klibc/klibc_1.5.25.bb
+++ b/meta-initramfs/recipes-devtools/klibc/klibc_1.5.25.bb
@@ -2,6 +2,19 @@ PR = "${INC_PR}.0"
export INST = "${D}"
+do_compile_prepend() {
+
+ # after kernel 3.1 the headers are moved in /generated
+ if [ ! -e ${STAGING_KERNEL_DIR}/arch/${TARGET_ARCH}/include/asm/bitsperlong.h ]
+ then
+ ln -sf ${STAGING_KERNEL_DIR}/arch/${TARGET_ARCH}/include/generated/asm/bitsperlong.h ${STAGING_KERNEL_DIR}/arch/${TARGET_ARCH}/include/asm/bitsperlong.h
+ ln -sf ${STAGING_KERNEL_DIR}/arch/${TARGET_ARCH}/include/generated/asm/errno.h ${STAGING_KERNEL_DIR}/arch/${TARGET_ARCH}/include/asm/errno.h
+ ln -sf ${STAGING_KERNEL_DIR}/arch/${TARGET_ARCH}/include/generated/asm/ioctl.h ${STAGING_KERNEL_DIR}/arch/${TARGET_ARCH}/include/asm/ioctl.h
+ ln -sf ${STAGING_KERNEL_DIR}/arch/${TARGET_ARCH}/include/generated/asm/poll.h ${STAGING_KERNEL_DIR}/arch/${TARGET_ARCH}/include/asm/poll.h
+ fi
+
+}
+
do_install() {
oe_runmake install