diff options
author | Andrea Adami <andrea.adami@gmail.com> | 2012-04-24 00:16:12 +0000 |
---|---|---|
committer | Koen Kooi <koen@dominion.thruhere.net> | 2012-04-24 08:07:41 +0200 |
commit | e360922f652af30c4222f447b5145706df375bfc (patch) | |
tree | d5e04a44f11594206903d713fdbc3dc6cc6ccb7d | |
parent | a2c1414b58723f6ec387ceb43b7575fd4f21d90a (diff) | |
download | meta-openembedded-e360922f652af30c4222f447b5145706df375bfc.tar.gz |
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>
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 000000000..c2369cd8c --- /dev/null +++ b/meta-initramfs/recipes-devtools/klibc/klibc-1.5.25/kernel_3.2__aligned_u64.patch | |||
@@ -0,0 +1,46 @@ | |||
1 | From 7f47891c1678874cccca66cd25e6a13486c86d78 Mon Sep 17 00:00:00 2001 | ||
2 | From: =?utf8?q?Maciej=20=C5=BBenczykowski?= <zenczykowski@gmail.com> | ||
3 | Date: Sun, 6 Nov 2011 14:33:40 -0800 | ||
4 | Subject: [PATCH] [klibc] include: [sys/types.h] -> linux/types.h and | ||
5 | __aligned_u64 | ||
6 | |||
7 | When building klibc 1.5.25 against linux/master (ie. post 3.1) I'm seeing: | ||
8 | |||
9 | klibc/generated/include/linux/if_packet.h:176: error: expected | ||
10 | specifier-qualifier-list before '__aligned_u64' | ||
11 | |||
12 | which seems to come from upstream commits: | ||
13 | 0d4691ce112be025019999df5f2a5e00c03f03c2 remotes/linux/master~90^2~408 (origin) | ||
14 | 96c131842aab45b5d139d0bcb417796819f5ee92 remotes/linux/master~90^2~169 | ||
15 | (change from aligned_u64 to __aligned_u64) | ||
16 | |||
17 | and collides with klibc/usr/include/sys/types.h | ||
18 | |||
19 | /* Keeps linux/types.h from getting included elsewhere */ | ||
20 | #define _LINUX_TYPES_H | ||
21 | |||
22 | not defining __aligned_u64 like the kernel's include/linux/types.h does. | ||
23 | |||
24 | Signed-off-by: maximilian attems <max@stro.at> | ||
25 | --- | ||
26 | usr/include/sys/types.h | 4 ++++ | ||
27 | 1 files changed, 4 insertions(+), 0 deletions(-) | ||
28 | |||
29 | diff --git a/usr/include/sys/types.h b/usr/include/sys/types.h | ||
30 | index 6780ed1..3a4c738 100644 | ||
31 | --- a/usr/include/sys/types.h | ||
32 | +++ b/usr/include/sys/types.h | ||
33 | @@ -100,6 +100,10 @@ typedef uint16_t __sum16; | ||
34 | typedef uint32_t __sum32; | ||
35 | typedef uint64_t __sum64; | ||
36 | |||
37 | +#define __aligned_u64 __u64 __attribute__((aligned(8))) | ||
38 | +#define __aligned_be64 __be64 __attribute__((aligned(8))) | ||
39 | +#define __aligned_le64 __le64 __attribute__((aligned(8))) | ||
40 | + | ||
41 | /* | ||
42 | * Some headers seem to require this... | ||
43 | */ | ||
44 | -- | ||
45 | 1.7.6.5 | ||
46 | |||
diff --git a/meta-initramfs/recipes-devtools/klibc/klibc.inc b/meta-initramfs/recipes-devtools/klibc/klibc.inc index 0f7cbbe96..6a15e0cd8 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}" | |||
12 | # debugsources.list: No such file or directory: | 12 | # debugsources.list: No such file or directory: |
13 | INHIBIT_PACKAGE_DEBUG_SPLIT = "1" | 13 | INHIBIT_PACKAGE_DEBUG_SPLIT = "1" |
14 | 14 | ||
15 | INC_PR = "r2" | 15 | INC_PR = "r3" |
16 | 16 | ||
17 | KLIBC_ARCH = '${TARGET_ARCH}' | 17 | KLIBC_ARCH = '${TARGET_ARCH}' |
18 | KLIBC_ARCH_armeb = 'arm' | 18 | KLIBC_ARCH_armeb = 'arm' |
@@ -34,6 +34,7 @@ SRC_URI += "file://fstype-sane-vfat-and-jffs2-for-1.5.patch \ | |||
34 | file://dash_readopt.patch \ | 34 | file://dash_readopt.patch \ |
35 | file://wc.patch \ | 35 | file://wc.patch \ |
36 | file://staging.patch \ | 36 | file://staging.patch \ |
37 | file://kernel_3.2__aligned_u64.patch \ | ||
37 | " | 38 | " |
38 | 39 | ||
39 | S = "${WORKDIR}/git" | 40 | 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 8a5062841..ae437539a 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" | |||
2 | 2 | ||
3 | export INST = "${D}" | 3 | export INST = "${D}" |
4 | 4 | ||
5 | do_compile_prepend() { | ||
6 | |||
7 | # after kernel 3.1 the headers are moved in /generated | ||
8 | if [ ! -e ${STAGING_KERNEL_DIR}/arch/${TARGET_ARCH}/include/asm/bitsperlong.h ] | ||
9 | then | ||
10 | ln -sf ${STAGING_KERNEL_DIR}/arch/${TARGET_ARCH}/include/generated/asm/bitsperlong.h ${STAGING_KERNEL_DIR}/arch/${TARGET_ARCH}/include/asm/bitsperlong.h | ||
11 | ln -sf ${STAGING_KERNEL_DIR}/arch/${TARGET_ARCH}/include/generated/asm/errno.h ${STAGING_KERNEL_DIR}/arch/${TARGET_ARCH}/include/asm/errno.h | ||
12 | ln -sf ${STAGING_KERNEL_DIR}/arch/${TARGET_ARCH}/include/generated/asm/ioctl.h ${STAGING_KERNEL_DIR}/arch/${TARGET_ARCH}/include/asm/ioctl.h | ||
13 | ln -sf ${STAGING_KERNEL_DIR}/arch/${TARGET_ARCH}/include/generated/asm/poll.h ${STAGING_KERNEL_DIR}/arch/${TARGET_ARCH}/include/asm/poll.h | ||
14 | fi | ||
15 | |||
16 | } | ||
17 | |||
5 | do_install() { | 18 | do_install() { |
6 | 19 | ||
7 | oe_runmake install | 20 | oe_runmake install |