diff options
author | Nitin A Kamble <nitin.a.kamble@intel.com> | 2011-01-19 09:19:27 -0800 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2011-01-20 21:37:05 +0000 |
commit | 746173daad9fbd46dc7917b1423855d1997782c1 (patch) | |
tree | 9ee3bc41b5c4dc50c7ea8ed9df5d636a261f8cd5 /meta/recipes-extended/zypper | |
parent | cff67292a2ce9a7866bf14653b5a81d501bfb64b (diff) | |
download | poky-746173daad9fbd46dc7917b1423855d1997782c1.tar.gz |
zypper: fix build issue with gcc dso linking change
All the libraries needs to be specified explicitely with the new gcc dso
linking change patch. This was causing build errors for this
recipe. Specifying the libpthread library explicitely for linking to work
without errors.
Signed-off-by: Nitin A Kamble <nitin.a.kamble@intel.com>
Diffstat (limited to 'meta/recipes-extended/zypper')
-rw-r--r-- | meta/recipes-extended/zypper/zypper/dso_linking_change_build_fix.patch | 58 | ||||
-rw-r--r-- | meta/recipes-extended/zypper/zypper_git.bb | 4 |
2 files changed, 60 insertions, 2 deletions
diff --git a/meta/recipes-extended/zypper/zypper/dso_linking_change_build_fix.patch b/meta/recipes-extended/zypper/zypper/dso_linking_change_build_fix.patch new file mode 100644 index 0000000000..0da196f5be --- /dev/null +++ b/meta/recipes-extended/zypper/zypper/dso_linking_change_build_fix.patch | |||
@@ -0,0 +1,58 @@ | |||
1 | after gcc linking has changed, all the libraries must be explicitely specified | ||
2 | This patch avoids these linking errors: | ||
3 | |||
4 | | Linking CXX executable zypp-refresh | ||
5 | | cd /build_disk/poky_build/build0/tmp/work/i586-poky-linux/zypper-1.4.7-git0+9eb0e248e06c8d20ad054be2439149d9ede37531-r2/git/src && /build_disk/poky_build/build0/tmp/sysroots/x86_64-linux/usr/bin/cmake -E cmake_link_script CMakeFiles/zypp-refresh.dir/link.txt --verbose=1 | ||
6 | | /build_disk/poky_build/build0/tmp/sysroots/x86_64-linux/usr/bin/i586-poky-linux/i586-poky-linux-g++ -march=i586 --sysroot=/build_disk/poky_build/build0/tmp/sysroots/i586-poky-linux -fpermissive -g -O2 -Wall -Woverloaded-virtual -fstack-protector -Wl,-O1 -Wl,--hash-style=gnu -Wl,--as-needed CMakeFiles/zypp-refresh.dir/zypp-refresh.cc.o -o zypp-refresh -rdynamic -lzypp | ||
7 | | /build_disk/poky_build/build0/tmp/sysroots/x86_64-linux/usr/libexec/i586-poky-linux/gcc/i586-poky-linux/4.5.1/ld: �: invalid DSO for symbol `pthread_cancel@@GLIBC_2.0' definition | ||
8 | | /build_disk/poky_build/build0/tmp/sysroots/i586-poky-linux/lib/libpthread.so.0: could not read symbols: Bad value | ||
9 | | collect2: ld returned 1 exit status | ||
10 | | make[2]: *** [src/zypp-refresh] Error 1 | ||
11 | | make[2]: Leaving directory `/build_disk/poky_build/build0/tmp/work/i586-poky-linux/zypper-1.4.7-git0+9eb0e248e06c8d20ad054be2439149d9ede37531-r2/git' | ||
12 | | make[1]: *** [src/CMakeFiles/zypp-refresh.dir/all] Error 2 | ||
13 | |||
14 | |||
15 | | Linking CXX executable zypper | ||
16 | | cd /build_disk/poky_build/build0/tmp/work/i586-poky-linux/zypper-1.4.7-git0+9eb0e248e06c8d20ad054be2439149d9ede37531-r3/git/src && /build_disk/poky_build/build0/tmp/sysroots/x86_64-linux/usr/bin/cmake -E cmake_link_script CMakeFiles/zypper.dir/link.txt --verbose=1 | ||
17 | | /build_disk/poky_build/build0/tmp/sysroots/x86_64-linux/usr/bin/i586-poky-linux/i586-poky-linux-g++ -march=i586 --sysroot=/build_disk/poky_build/build0/tmp/sysroots/i586-poky-linux -fpermissive -g -O2 -Wall -Woverloaded-virtual -fstack-protector -Wl,-O1 -Wl,--hash-style=gnu -Wl,--as-needed CMakeFiles/zypper.dir/main.cc.o -o zypper -rdynamic libzypper_lib.a -lzypp -lreadline -laugeas -laugeas | ||
18 | | /build_disk/poky_build/build0/tmp/sysroots/x86_64-linux/usr/libexec/i586-poky-linux/gcc/i586-poky-linux/4.5.1/ld: �: invalid DSO for symbol `pthread_cancel@@GLIBC_2.0' definition | ||
19 | | /build_disk/poky_build/build0/tmp/sysroots/i586-poky-linux/lib/libpthread.so.0: could not read symbols: Bad value | ||
20 | | collect2: ld returned 1 exit status | ||
21 | | make[2]: *** [src/zypper] Error 1 | ||
22 | |||
23 | |||
24 | | Linking CXX executable zypper | ||
25 | | cd /build_disk/poky_build/build0/tmp/work/i586-poky-linux/zypper-1.4.7-git0+9eb0e248e06c8d20ad054be2439149d9ede37531-r3/git/src && /build_disk/poky_build/build0/tmp/sysroots/x86_64-linux/usr/bin/cmake -E cmake_link_script CMakeFiles/zypper.dir/link.txt --verbose=1 | ||
26 | | /build_disk/poky_build/build0/tmp/sysroots/x86_64-linux/usr/bin/i586-poky-linux/i586-poky-linux-g++ -march=i586 --sysroot=/build_disk/poky_build/build0/tmp/sysroots/i586-poky-linux -fpermissive -g -O2 -Wall -Woverloaded-virtual -fstack-protector -Wl,-O1 -Wl,--hash-style=gnu -Wl,--as-needed CMakeFiles/zypper.dir/main.cc.o -o zypper -rdynamic libzypper_lib.a -lzypp -lreadline -laugeas -laugeas -lpthread | ||
27 | | /build_disk/poky_build/build0/tmp/sysroots/x86_64-linux/usr/libexec/i586-poky-linux/gcc/i586-poky-linux/4.5.1/ld: �: invalid DSO for symbol `clock_gettime@@GLIBC_2.2' definition | ||
28 | | /build_disk/poky_build/build0/tmp/sysroots/i586-poky-linux/lib/librt.so.1: could not read symbols: Bad value | ||
29 | | collect2: ld returned 1 exit status | ||
30 | | make[2]: *** [src/zypper] Error 1 | ||
31 | |||
32 | |||
33 | Nitin A Kamble <nitin.a.kamble@intel.com> | ||
34 | Date: 2011/01/19 | ||
35 | |||
36 | |||
37 | Index: git/src/CMakeLists.txt | ||
38 | =================================================================== | ||
39 | --- git.orig/src/CMakeLists.txt 2010-12-20 00:02:02.000000000 -0800 | ||
40 | +++ git/src/CMakeLists.txt 2011-01-19 09:23:13.432758255 -0800 | ||
41 | @@ -93,7 +93,7 @@ | ||
42 | TARGET_LINK_LIBRARIES( zypper_lib ${ZYPP_LIBRARY} ${READLINE_LIBRARY} -laugeas ${AUGEAS_LIBRARY} ) | ||
43 | |||
44 | ADD_EXECUTABLE( zypper main.cc ) | ||
45 | -TARGET_LINK_LIBRARIES( zypper zypper_lib ${ZYPP_LIBRARY} ${READLINE_LIBRARY} -laugeas ${AUGEAS_LIBRARY} ) | ||
46 | +TARGET_LINK_LIBRARIES( zypper zypper_lib ${ZYPP_LIBRARY} ${READLINE_LIBRARY} -laugeas ${AUGEAS_LIBRARY} pthread rt ) | ||
47 | |||
48 | |||
49 | INSTALL( | ||
50 | @@ -115,7 +115,7 @@ | ||
51 | |||
52 | # zypp-refresh utility | ||
53 | ADD_EXECUTABLE( zypp-refresh zypp-refresh.cc ) | ||
54 | -TARGET_LINK_LIBRARIES( zypp-refresh ${ZYPP_LIBRARY} ) | ||
55 | +TARGET_LINK_LIBRARIES( zypp-refresh ${ZYPP_LIBRARY} pthread ) | ||
56 | INSTALL( | ||
57 | TARGETS zypp-refresh | ||
58 | RUNTIME DESTINATION ${INSTALL_PREFIX}/sbin | ||
diff --git a/meta/recipes-extended/zypper/zypper_git.bb b/meta/recipes-extended/zypper/zypper_git.bb index c8895e5806..b9e2e85943 100644 --- a/meta/recipes-extended/zypper/zypper_git.bb +++ b/meta/recipes-extended/zypper/zypper_git.bb | |||
@@ -6,13 +6,13 @@ LIC_FILES_CHKSUM = "file://COPYING;md5=3201406e350b39e05a82e28b5020f413" | |||
6 | 6 | ||
7 | DEPENDS = "libzypp augeas" | 7 | DEPENDS = "libzypp augeas" |
8 | RRECOMMENDS_${PN} = "procps" | 8 | RRECOMMENDS_${PN} = "procps" |
9 | PR = "r2" | 9 | PR = "r3" |
10 | 10 | ||
11 | inherit cmake | 11 | inherit cmake |
12 | 12 | ||
13 | SRC_URI = "git://gitorious.org/opensuse/zypper.git;protocol=git \ | 13 | SRC_URI = "git://gitorious.org/opensuse/zypper.git;protocol=git \ |
14 | file://cmake.patch \ | 14 | file://cmake.patch \ |
15 | " | 15 | file://dso_linking_change_build_fix.patch " |
16 | S = "${WORKDIR}/git" | 16 | S = "${WORKDIR}/git" |
17 | 17 | ||
18 | PV = "1.4.7-git${SRCPV}" | 18 | PV = "1.4.7-git${SRCPV}" |