summaryrefslogtreecommitdiffstats
path: root/meta/recipes-bsp/libacpi/files
diff options
context:
space:
mode:
Diffstat (limited to 'meta/recipes-bsp/libacpi/files')
-rw-r--r--meta/recipes-bsp/libacpi/files/ldflags.patch41
-rw-r--r--meta/recipes-bsp/libacpi/files/libacpi_fix_for_x32.patch47
-rw-r--r--meta/recipes-bsp/libacpi/files/makefile-fix.patch47
-rw-r--r--meta/recipes-bsp/libacpi/files/use_correct_strip_in_cross_environment.patch23
4 files changed, 158 insertions, 0 deletions
diff --git a/meta/recipes-bsp/libacpi/files/ldflags.patch b/meta/recipes-bsp/libacpi/files/ldflags.patch
new file mode 100644
index 0000000000..a7424c39da
--- /dev/null
+++ b/meta/recipes-bsp/libacpi/files/ldflags.patch
@@ -0,0 +1,41 @@
1libacpi: Remove QA warning: No GNU_HASH in the elf binary
2
3Upstream-Status: Inappropriate [other]
4 Useful within bitbake environment only.
5
6Signed-off-by: Muhammad Shakeel <muhammad_shakeel@mentor.com>
7
8---
9 Makefile | 3 ++-
10 config.mk | 1 +
11 2 files changed, 3 insertions(+), 1 deletion(-)
12
13--- libacpi-0.2.orig/Makefile
14+++ libacpi-0.2/Makefile
15@@ -19,6 +19,7 @@ options:
16 @echo "CFLAGS = ${CFLAGS}"
17 @echo "CC = ${CC}"
18 @echo "SOFLAGS = ${SOFLAGS}"
19+ @echo "LDFLAGS = ${LDFLAGS}"
20 @echo "LD = ${LD}"
21
22 .c.o:
23@@ -34,7 +35,7 @@ libacpi.a: ${OBJ}
24
25 libacpi.so: ${OBJ}
26 @echo LD $@
27- @${CC} ${SOFLAGS} -o $@.${SOVERSION} ${OBJ}
28+ @${CC} ${SOFLAGS} ${LDFLAGS} -o $@.${SOVERSION} ${OBJ}
29
30 test-libacpi: ${OBJ_test}
31 @echo LD $@
32--- libacpi-0.2.orig/config.mk
33+++ libacpi-0.2/config.mk
34@@ -10,6 +10,7 @@ MANPREFIX = ${PREFIX}/share/man
35 SOFLAGS = -shared -Wl,-soname,${SONAME}
36 CFLAGS += -fPIC -g --pedantic -Wall -Wextra
37 ARFLAGS = cr
38+LDFLAGS =
39
40 # Compiler and linker
41 CC = cc
diff --git a/meta/recipes-bsp/libacpi/files/libacpi_fix_for_x32.patch b/meta/recipes-bsp/libacpi/files/libacpi_fix_for_x32.patch
new file mode 100644
index 0000000000..2fed344ba5
--- /dev/null
+++ b/meta/recipes-bsp/libacpi/files/libacpi_fix_for_x32.patch
@@ -0,0 +1,47 @@
1Upstream-Status: Pending
2
3Fix libacpi for x32
4
5 libacpi doesn't use base_libdir for install. This patch adds
6 base_libdir support so that x32 libraries are installed properly.
7
8Patch Received from: H.J. Lu <hjl.tools@gmail.com>
9
10Signed-Off-By: Nitin A Kamble <nitin.a.kamble@intel.com> 2011/12/05
11
12Index: libacpi-0.2/Makefile
13===================================================================
14--- libacpi-0.2.orig/Makefile
15+++ libacpi-0.2/Makefile
16@@ -8,6 +8,10 @@ SRC_test = test-libacpi.c libacpi.c list
17 OBJ = ${SRC:.c=.o}
18 OBJ_test = ${SRC_test:.c=.o}
19
20+ifndef base_libdir
21+base_libdir=/lib
22+endif
23+
24 all: options libacpi.a libacpi.so test-libacpi
25
26 options:
27@@ -42,13 +46,13 @@ install: all
28 @mkdir -p ${DESTDIR}${PREFIX}/include
29 @cp -f libacpi.h ${DESTDIR}${PREFIX}/include
30 @chmod 644 ${DESTDIR}${PREFIX}/include/libacpi.h
31- @echo installing library to ${DESTDIR}${PREFIX}/lib
32- @mkdir -p ${DESTDIR}${PREFIX}/lib
33- @cp -f libacpi.a ${DESTDIR}${PREFIX}/lib
34- @chmod 644 ${DESTDIR}${PREFIX}/lib/libacpi.a
35- @cp -f ${SONAME} ${DESTDIR}${PREFIX}/lib/
36- @chmod 644 ${DESTDIR}${PREFIX}/lib/${SONAME}
37- @ln -s ${SONAME} ${DESTDIR}${PREFIX}/lib/libacpi.so
38+ @echo installing library to ${DESTDIR}${PREFIX}${base_libdir}
39+ @mkdir -p ${DESTDIR}${PREFIX}${base_libdir}
40+ @cp -f libacpi.a ${DESTDIR}${PREFIX}${base_libdir}
41+ @chmod 644 ${DESTDIR}${PREFIX}${base_libdir}/libacpi.a
42+ @cp -f ${SONAME} ${DESTDIR}${PREFIX}${base_libdir}/
43+ @chmod 644 ${DESTDIR}${PREFIX}${base_libdir}/${SONAME}
44+ @ln -s ${SONAME} ${DESTDIR}${PREFIX}${base_libdir}/libacpi.so
45 @echo installing test-libacpi to ${DESTDIR}${PREFIX}/bin
46 @mkdir -p ${DESTDIR}${PREFIX}/bin
47 @cp -f test-libacpi ${DESTDIR}${PREFIX}/bin
diff --git a/meta/recipes-bsp/libacpi/files/makefile-fix.patch b/meta/recipes-bsp/libacpi/files/makefile-fix.patch
new file mode 100644
index 0000000000..c34ef34e09
--- /dev/null
+++ b/meta/recipes-bsp/libacpi/files/makefile-fix.patch
@@ -0,0 +1,47 @@
1Upstream-Status: Pending
2
3---
4 Makefile | 6 +++---
5 config.mk | 3 ++-
6 2 files changed, 5 insertions(+), 4 deletions(-)
7
8Index: libacpi-0.2/Makefile
9===================================================================
10--- libacpi-0.2.orig/Makefile 2007-07-29 14:09:34.000000000 +0200
11+++ libacpi-0.2/Makefile 2008-09-26 10:34:53.000000000 +0200
12@@ -25,16 +25,16 @@ ${OBJ}: config.mk libacpi.h
13
14 libacpi.a: ${OBJ}
15 @echo AR $@
16- @${AR} $@ ${OBJ}
17+ ${AR} ${ARFLAGS} $@ ${OBJ}
18 @${RANLIB} $@
19
20 libacpi.so: ${OBJ}
21 @echo LD $@
22- @${LD} ${SOFLAGS} -o $@.${SOVERSION} ${OBJ}
23+ @${CC} ${SOFLAGS} -o $@.${SOVERSION} ${OBJ}
24
25 test-libacpi: ${OBJ_test}
26 @echo LD $@
27- @${LD} -o $@ ${OBJ_test} ${LDFLAGS}
28+ @${CC} -o $@ ${OBJ_test} ${LDFLAGS}
29 @strip $@
30
31 install: all
32Index: libacpi-0.2/config.mk
33===================================================================
34--- libacpi-0.2.orig/config.mk 2007-07-29 14:09:34.000000000 +0200
35+++ libacpi-0.2/config.mk 2008-09-26 10:34:33.000000000 +0200
36@@ -9,9 +9,10 @@ MANPREFIX = ${PREFIX}/share/man
37 # flags
38 SOFLAGS = -shared -Wl,-soname,${SONAME}
39 CFLAGS += -fPIC -g --pedantic -Wall -Wextra
40+ARFLAGS = cr
41
42 # Compiler and linker
43 CC = cc
44 LD = ${CC}
45-AR = ar cr
46+AR = ar
47 RANLIB = ranlib
diff --git a/meta/recipes-bsp/libacpi/files/use_correct_strip_in_cross_environment.patch b/meta/recipes-bsp/libacpi/files/use_correct_strip_in_cross_environment.patch
new file mode 100644
index 0000000000..bca75fb472
--- /dev/null
+++ b/meta/recipes-bsp/libacpi/files/use_correct_strip_in_cross_environment.patch
@@ -0,0 +1,23 @@
1Upstream-Status: Pending
2
3Used the cross strip instead of host strip to avoid this build error:
4
5| strip: Unable to recognise the format of the input file `test-libacpi'
6| make: *** [test-libacpi] Error 1
7| ERROR: oe_runmake failed
8
9Signed-Off-By: Nitin A Kamble <nitin.a.kamble@intel.com> 2011/12/07
10
11Index: libacpi-0.2/Makefile
12===================================================================
13--- libacpi-0.2.orig/Makefile
14+++ libacpi-0.2/Makefile
15@@ -39,7 +39,7 @@ libacpi.so: ${OBJ}
16 test-libacpi: ${OBJ_test}
17 @echo LD $@
18 @${CC} -o $@ ${OBJ_test} ${LDFLAGS}
19- @strip $@
20+ @${STRIP} $@
21
22 install: all
23 @echo installing header to ${DESTDIR}${PREFIX}/include