summaryrefslogtreecommitdiffstats
path: root/meta/recipes-extended/libzypp
diff options
context:
space:
mode:
authorKevin Tian <kevin.tian@intel.com>2010-09-08 16:57:03 +0800
committerRichard Purdie <rpurdie@linux.intel.com>2010-09-08 14:39:00 +0100
commitc519aec68c61ae2a3822fde0c8e4616a97d2faaf (patch)
treea06515c46cc3d4886653f223911200254313f5fb /meta/recipes-extended/libzypp
parent7892add2de517a0273f64fcd0d398d96531cd5a2 (diff)
downloadpoky-c519aec68c61ae2a3822fde0c8e4616a97d2faaf.tar.gz
libzypp: workaround to pass mips build
libzypp failed due to GCC "internal compiler error: segmentation fault" error on MIPS target. The cause is about boost tribool type usage. If having assignement within conditional check as below: if ( (a = b) ) ... <a is a tribool type, b is a normal bool type> then gcc4.3.3 throws internal error. Then the workaround is to move assignement out of the conditional check. However I didn't find same case from web. We can come back to recheck this issue after upgrading to gcc4.5.0 for MIPS. If this issue is still there, we'll need more analysis to decide whether to report to gcc upstream or to libzypp upstream. This fixes [BUGID #277] Signed-off-by: Kevin Tian <kevin.tian@intel.com>
Diffstat (limited to 'meta/recipes-extended/libzypp')
-rw-r--r--meta/recipes-extended/libzypp/libzypp/mips-workaround-gcc-tribool-error.patch22
-rw-r--r--meta/recipes-extended/libzypp/libzypp_git.bb4
2 files changed, 25 insertions, 1 deletions
diff --git a/meta/recipes-extended/libzypp/libzypp/mips-workaround-gcc-tribool-error.patch b/meta/recipes-extended/libzypp/libzypp/mips-workaround-gcc-tribool-error.patch
new file mode 100644
index 0000000000..849ce3dd8b
--- /dev/null
+++ b/meta/recipes-extended/libzypp/libzypp/mips-workaround-gcc-tribool-error.patch
@@ -0,0 +1,22 @@
1# with gcc 4.3.3 and MIPS target, gcc "internal compiler error: segmentation fault" error
2# occurs when compiling Applydeltarpm.cc. I didn't find the exact reason leading to this
3# error, but it should be related to how boost tribool type is interpreted by g++. So provide
4# this mips workaround for now. We'll come back later to check whether it's still required after
5# upgrading to 4.5.0.
6#
7# Signed-off-by Kevin Tian <kevin.tian@intel.com>, 2010-09-08
8
9diff --git a/zypp/repo/Applydeltarpm.cc b/zypp/repo/Applydeltarpm.cc
10index 7b382be..0d7a1f8 100644
11--- a/zypp/repo/Applydeltarpm.cc
12+++ b/zypp/repo/Applydeltarpm.cc
13@@ -77,7 +77,8 @@ namespace zypp
14 else
15 {
16 // _last is 'indeterminate' or '!have'
17- if ( (_last = have) )
18+ _last = have;
19+ if ( _last )
20 MIL << "Found executable " << prog << endl;
21 else
22 WAR << "No executable " << prog << endl;
diff --git a/meta/recipes-extended/libzypp/libzypp_git.bb b/meta/recipes-extended/libzypp/libzypp_git.bb
index a2856d1475..44ea60d054 100644
--- a/meta/recipes-extended/libzypp/libzypp_git.bb
+++ b/meta/recipes-extended/libzypp/libzypp_git.bb
@@ -10,11 +10,13 @@ DEPENDS = "rpm boost gettext curl libxml2 zlib sat-solver expat openssl udev"
10 10
11S = "${WORKDIR}/git" 11S = "${WORKDIR}/git"
12PV = "0.0-git${SRCPV}" 12PV = "0.0-git${SRCPV}"
13PR = "r0" 13PR = "r1"
14 14
15SRC_URI = "git://gitorious.org/opensuse/libzypp.git;protocol=git \ 15SRC_URI = "git://gitorious.org/opensuse/libzypp.git;protocol=git \
16 file://no-doc.patch \ 16 file://no-doc.patch \
17 file://rpm5.patch" 17 file://rpm5.patch"
18 18
19SRC_URI_append_mips = " file://mips-workaround-gcc-tribool-error.patch"
20
19FILES_${PN} += "${libdir}/zypp ${datadir}/zypp ${datadir}/icons" 21FILES_${PN} += "${libdir}/zypp ${datadir}/zypp ${datadir}/icons"
20FILES_${PN}-dev += "${datadir}/cmake" 22FILES_${PN}-dev += "${datadir}/cmake"