summaryrefslogtreecommitdiffstats
path: root/meta
diff options
context:
space:
mode:
authorKhem Raj <raj.khem@gmail.com>2012-03-23 05:50:41 -0700
committerRichard Purdie <richard.purdie@linuxfoundation.org>2012-03-23 14:00:55 +0000
commit45bc21c2752bdfe46a2ae262fec5acd0da185853 (patch)
tree01cb7cecb90f65313d03edbe43e2e4a8f003fb54 /meta
parentbb1d7fad7ff8515939f2b5f0b540b9b09604be3c (diff)
downloadpoky-45bc21c2752bdfe46a2ae262fec5acd0da185853.tar.gz
gdb-cross-canadian: Fix linking issues when python support is enabled
gdb-cross-canadian was linking with static version of libpython and looking for build host python when run. This could be mismatch between python-nativesdk and build host provided python. So we make it consistent to always use python-nativesdk Instead of adding bunch of -L we add -rpath and -rpath-link so that gdb finds all needed libraries in SDK and does not reach out into host This should fix yocto PR# 2077 as well. (From OE-Core rev: d56177c59b5e237a501281d806724885456f0193) Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta')
-rw-r--r--meta/recipes-devtools/gdb/gdb-cross-canadian.inc7
-rw-r--r--meta/recipes-devtools/gdb/gdb-cross-canadian_7.4.bb2
2 files changed, 5 insertions, 4 deletions
diff --git a/meta/recipes-devtools/gdb/gdb-cross-canadian.inc b/meta/recipes-devtools/gdb/gdb-cross-canadian.inc
index 47d7d28a2b..2b6069883e 100644
--- a/meta/recipes-devtools/gdb/gdb-cross-canadian.inc
+++ b/meta/recipes-devtools/gdb/gdb-cross-canadian.inc
@@ -1,4 +1,5 @@
1inherit cross-canadian 1inherit cross-canadian
2inherit python-dir
2 3
3DESCRIPTION = "cross-canadian gdb for ${TARGET_ARCH} target - GNU debugger" 4DESCRIPTION = "cross-canadian gdb for ${TARGET_ARCH} target - GNU debugger"
4PN = "gdb-cross-canadian-${TRANSLATED_TARGET_ARCH}" 5PN = "gdb-cross-canadian-${TRANSLATED_TARGET_ARCH}"
@@ -14,9 +15,9 @@ do_configure_prepend() {
14cat > ${WORKDIR}/python << EOF 15cat > ${WORKDIR}/python << EOF
15#! /bin/sh 16#! /bin/sh
16case "\$2" in 17case "\$2" in
17 --includes) echo "-I${STAGING_INCDIR}/python${PYTHON_BASEVERSION}/" ;; 18 --includes) echo "-I${STAGING_INCDIR}/${PYTHON_DIR}/" ;;
18 --ldflags) echo "-L${STAGING_LIBDIR}/../python${PYTHON_BASEVERSION}/config -lpthread -ldl -lutil -lm -lpython${PYTHON_BASEVERSION}" ;; 19 --ldflags) echo "-Wl,-rpath-link,${STAGING_LIBDIR}/.. -Wl,-rpath,${libdir}/.. -lpthread -ldl -lutil -lm -lpython${PYTHON_BASEVERSION}" ;;
19 --exec-prefix) echo "/usr" ;; 20 --exec-prefix) echo "${exec_prefix}/bin" ;;
20 *) exit 1 ;; 21 *) exit 1 ;;
21esac 22esac
22exit 0 23exit 0
diff --git a/meta/recipes-devtools/gdb/gdb-cross-canadian_7.4.bb b/meta/recipes-devtools/gdb/gdb-cross-canadian_7.4.bb
index dfb7d8122a..8e68c75782 100644
--- a/meta/recipes-devtools/gdb/gdb-cross-canadian_7.4.bb
+++ b/meta/recipes-devtools/gdb/gdb-cross-canadian_7.4.bb
@@ -1,7 +1,7 @@
1require gdb-common.inc 1require gdb-common.inc
2require gdb-cross-canadian.inc 2require gdb-cross-canadian.inc
3 3
4PR = "${INC_PR}.4" 4PR = "${INC_PR}.5"
5 5
6GDBPROPREFIX = "--program-prefix='${TARGET_PREFIX}'" 6GDBPROPREFIX = "--program-prefix='${TARGET_PREFIX}'"
7EXPAT = "--with-expat" 7EXPAT = "--with-expat"