summaryrefslogtreecommitdiffstats
path: root/meta/packages/linux-libc-headers
diff options
context:
space:
mode:
Diffstat (limited to 'meta/packages/linux-libc-headers')
-rw-r--r--meta/packages/linux-libc-headers/linux-libc-headers-2.6.18/arm-syscall-define.patch22
-rw-r--r--meta/packages/linux-libc-headers/linux-libc-headers_2.6.18.bb70
2 files changed, 92 insertions, 0 deletions
diff --git a/meta/packages/linux-libc-headers/linux-libc-headers-2.6.18/arm-syscall-define.patch b/meta/packages/linux-libc-headers/linux-libc-headers-2.6.18/arm-syscall-define.patch
new file mode 100644
index 0000000000..ec5a87d2a3
--- /dev/null
+++ b/meta/packages/linux-libc-headers/linux-libc-headers-2.6.18/arm-syscall-define.patch
@@ -0,0 +1,22 @@
1# define the _syscall macros, needed to build util-linux
2
3Index: linux-2.6.18/include/asm-arm/unistd.h
4===================================================================
5--- linux-2.6.18.orig/include/asm-arm/unistd.h 2006-10-02 18:05:31.000000000 +0200
6+++ linux-2.6.18/include/asm-arm/unistd.h 2006-10-02 18:05:47.000000000 +0200
7@@ -376,9 +376,6 @@
8 #undef __NR_ipc
9 #endif
10
11-#ifdef __KERNEL__
12-#include <linux/linkage.h>
13-
14 #define __sys2(x) #x
15 #define __sys1(x) __sys2(x)
16
17@@ -580,5 +577,4 @@
18 */
19 #define cond_syscall(x) asm(".weak\t" #x "\n\t.set\t" #x ",sys_ni_syscall")
20
21-#endif /* __KERNEL__ */
22 #endif /* __ASM_ARM_UNISTD_H */
diff --git a/meta/packages/linux-libc-headers/linux-libc-headers_2.6.18.bb b/meta/packages/linux-libc-headers/linux-libc-headers_2.6.18.bb
new file mode 100644
index 0000000000..8e1c5dc3e8
--- /dev/null
+++ b/meta/packages/linux-libc-headers/linux-libc-headers_2.6.18.bb
@@ -0,0 +1,70 @@
1require linux-libc-headers.inc
2
3INHIBIT_DEFAULT_DEPS = "1"
4DEPENDS = "unifdef-native"
5PR = "r1"
6
7SRC_URI = "${KERNELORG_MIRROR}/pub/linux/kernel/v2.6/linux-2.6.18.tar.bz2 \
8 file://arm-syscall-define.patch;patch=1"
9
10S = "${WORKDIR}/linux-2.6.18"
11
12set_arch() {
13 case ${TARGET_ARCH} in
14 alpha*) ARCH=alpha ;;
15 arm*) ARCH=arm ;;
16 cris*) ARCH=cris ;;
17 hppa*) ARCH=parisc ;;
18 i*86*) ARCH=i386 ;;
19 ia64*) ARCH=ia64 ;;
20 mips*) ARCH=mips ;;
21 m68k*) ARCH=m68k ;;
22 powerpc*) ARCH=powerpc ;;
23 s390*) ARCH=s390 ;;
24 sh*) ARCH=sh ;;
25 sparc64*) ARCH=sparc64 ;;
26 sparc*) ARCH=sparc ;;
27 x86_64*) ARCH=x86_64 ;;
28 esac
29}
30
31do_configure() {
32 set_arch
33 oe_runmake allnoconfig ARCH=${ARCH}
34}
35
36do_compile () {
37}
38
39do_install() {
40 set_arch
41 oe_runmake headers_install INSTALL_HDR_PATH=${D}/usr ARCH=${ARCH}
42}
43
44do_install_append_arm() {
45 cp include/asm-arm/procinfo.h ${D}${includedir}/asm
46}
47
48STAGE_TEMP="${WORKDIR}/temp-staging"
49
50do_stage () {
51 set_arch
52 rm -rf ${STAGE_TEMP}
53 mkdir -p ${STAGE_TEMP}
54 oe_runmake headers_install INSTALL_HDR_PATH=${STAGE_TEMP}/usr ARCH=${ARCH}
55 if [ "${ARCH}" == "arm" ]; then
56 cp include/asm-arm/procinfo.h ${STAGE_TEMP}${includedir}/asm
57 fi
58 install -d ${STAGING_INCDIR}
59 rm -rf ${STAGING_INCDIR}/linux ${STAGING_INCDIR}/asm ${STAGING_INCDIR}/asm-generic
60 cp -pfLR ${STAGE_TEMP}${includedir}/linux ${STAGING_INCDIR}/
61 cp -pfLR ${STAGE_TEMP}${includedir}/asm ${STAGING_INCDIR}/
62 cp -pfLR ${STAGE_TEMP}${includedir}/asm-generic ${STAGING_INCDIR}/
63 rm -rf ${CROSS_DIR}/${TARGET_SYS}/include/linux
64 rm -rf ${CROSS_DIR}/${TARGET_SYS}/include/asm
65 rm -rf ${CROSS_DIR}/${TARGET_SYS}/include/asm-generic
66 install -d ${CROSS_DIR}/${TARGET_SYS}/include
67 cp -pfLR ${STAGE_TEMP}${includedir}/linux ${CROSS_DIR}/${TARGET_SYS}/include/
68 cp -pfLR ${STAGE_TEMP}${includedir}/asm ${CROSS_DIR}/${TARGET_SYS}/include/
69 cp -pfLR ${STAGE_TEMP}${includedir}/asm-generic ${CROSS_DIR}/${TARGET_SYS}/include/
70}