Skip to contentSkip to conversation

Andreas Oberritter : gdb: build with expat, add missing RRECOMMENDS_gdbserver

oe-commits New Martin Jansa 4 participants 11 messages Apr 4, 2012 – Apr 10, 2012 1 message not in the archive

lore
Share & tools
lore

A message that is not in the archive (sent off-list or not yet received): 20120403131537.5CE3310218@opal

#1 lore raw
Quoted 10 lines · On Tue, Apr 03, 2012 at 01:15:37PM +0000, [email protected] wrote:
Module: openembedded-core.git
Branch: master
Commit: 38ee88e3b32b7444d7f1eb64f1b4f69a48fe0458
URL:    http://git.openembedded.org/?p=openembedded-core.git&a=commit;h=38ee88e3b32b7444d7f1eb64f1b4f69a48fe0458
Author: Andreas Oberritter <[email protected]>
Date:   Tue Apr  3 00:23:55 2012 +0200

gdb: build with expat, add missing RRECOMMENDS_gdbserver

Quoted 8 lines

* Fixes communication between gdbserver and gdb-cross by using the same expat settings for both recipes.
* Adds missing build dependencies for expat/expat-native.
* Adds missing glibc-thread-db runtime recommendation to gdbserver, which was set only for gdb.

Here it's trying to use host's expat when building target gdb and fails...

| checking for libexpat... no
| configure: error: expat is missing or unusable
| make[1]: *** [configure-gdb] Error 1
| make[1]: Leaving directory `/OE/shr-core/tmp-eglibc/work/armv7a-vfp-neon-oe-linux-gnueabi/gdb/gdb-7.4-r7.0/build-arm-oe-linux-gnueabi'
| make: *** [all] Error 2
| ERROR: oe_runmake failed

NOTE: package gdb-7.4-r7.0: task do_compile: Failed
ERROR: Task 3561 (/OE/shr-core/openembedded-core/meta/recipes-devtools/gdb/gdb_7.4.bb, do_compile) failed with exit code '1'

from config.log:
configure:10704: checking for libexpat
configure:10723: arm-oe-linux-gnueabi-gcc -march=armv7-a -fno-tree-vectorize -mthumb-interwork -mfloat-abi=softfp -mfpu=neon -mtune=cortex-a8 --sysroot=/OE/shr-core/tmp-eglibc/sysroots/om-gta04 -o conftest -O2 -pipe -g -feliminate-unused-debug-types -Wl,-O1 -Wl,--hash-style=gnu -Wl,--as-needed conftest.c -ldl -lncurses -lz -lm /usr/lib/libexpat.so >&5
/OE/shr-core/tmp-eglibc/sysroots/x86_64-linux/usr/libexec/armv7a-vfp-neon-oe-linux-gnueabi/gcc/arm-oe-linux-gnueabi/4.6.4/ld: error: /usr/lib/libexpat.so: incompatible target conftest.c:98: error: undefined reference to 'XML_ParserCreate'
collect2: ld returned 1 exit status

Cheers,

Quoted 88 lines

---

 meta/recipes-devtools/gdb/gdb-common.inc           |    8 +++++---
 .../recipes-devtools/gdb/gdb-cross-canadian_7.4.bb |    1 -
 meta/recipes-devtools/gdb/gdb-cross.inc            |    2 +-
 meta/recipes-devtools/gdb/gdb-cross_7.4.bb         |    1 -
 4 files changed, 6 insertions(+), 6 deletions(-)
meta/recipes-devtools/gdb/gdb-common.inc +5 -3
index 0833a03..a8fca6f 100644
@@ -2,7 +2,7 @@ DESCRIPTION = "gdb - GNU debugger"
 HOMEPAGE = "http://www.gnu.org/software/gdb/"
 LICENSE="GPLv3+"
 SECTION = "devel"
-DEPENDS = "ncurses readline ${LTTNGUST}"
+DEPENDS = "expat ncurses readline ${LTTNGUST}"
 
 LTTNGUST = "lttng-ust"
 LTTNGUST_libc-uclibc = ""
@@ -11,7 +11,7 @@ LTTNGUST_mipsel = ""
 LTTNGUST_mips64 = ""
 LTTNGUST_mips64el = ""
 
-INC_PR = "r6"
+INC_PR = "r7"
 
 LIC_FILES_CHKSUM = "file://COPYING;md5=59530bdf33659b29e73d4adb9f9f6552 \
 		file://COPYING.LIB;md5=9f604d8a4f8e74f4f5140845a21b6674 \
@@ -36,7 +36,7 @@ B = "${WORKDIR}/build-${TARGET_SYS}"
 
 EXTRA_OEMAKE = "'SUBDIRS=intl mmalloc libiberty opcodes bfd sim gdb etc utils'"
 
-EXPAT = "--without-expat"
+EXPAT = "--with-expat"
 
 EXTRA_OECONF = "--disable-gdbtk --disable-tui --disable-x \
                 --with-curses --disable-multilib --with-system-readline --disable-sim \
@@ -63,4 +63,6 @@ do_install_append() {
 
 RRECOMMENDS_gdb_append_linux = " glibc-thread-db "
 RRECOMMENDS_gdb_append_linux-gnueabi = " glibc-thread-db "
+RRECOMMENDS_gdbserver_append_linux = " glibc-thread-db "
+RRECOMMENDS_gdbserver_append_linux-gnueabi = " glibc-thread-db "
 
meta/recipes-devtools/gdb/gdb-cross-canadian_7.4.bb +0 -1
index 8e68c75..b2f39ce 100644
@@ -4,6 +4,5 @@ require gdb-cross-canadian.inc
 PR = "${INC_PR}.5"
 
 GDBPROPREFIX = "--program-prefix='${TARGET_PREFIX}'"
-EXPAT = "--with-expat"
 
 S = "${WORKDIR}/${BPN}-${PV}"
meta/recipes-devtools/gdb/gdb-cross.inc +1 -1
index 20db86b..588a208 100644
@@ -1,6 +1,6 @@
 require gdb-common.inc
 
-DEPENDS = "ncurses-native"
+DEPENDS = "expat-native ncurses-native"
 
 #EXTRA_OEMAKE += "LDFLAGS='${BUILD_LDFLAGS}'"
 
meta/recipes-devtools/gdb/gdb-cross_7.4.bb +0 -1
index eaf8f36..a14d0ba 100644
@@ -1,7 +1,6 @@
 require gdb-cross.inc
 
 SRC_URI += "file://sim-install-6.6.patch"
-EXPAT = "--with-expat"
 
 PR = "${INC_PR}.0"
 

_______________________________________________
Openembedded-commits mailing list
[email protected]
http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-commits

Signature · 1 line
Martin 'JaMa' Jansa     jabber: [email protected]
#2 lore raw
Quoted 31 lines · Martin Jansa
Quoted 10 lines · On Tue, Apr 03, 2012 at 01:15:37PM +0000, [email protected] wrote:
Module: openembedded-core.git
Branch: master
Commit: 38ee88e3b32b7444d7f1eb64f1b4f69a48fe0458
URL:    http://git.openembedded.org/?p=openembedded-core.git&a=commit;h=38ee88e3b32b7444d7f1eb64f1b4f69a48fe0458
Author: Andreas Oberritter <[email protected]>
Date:   Tue Apr  3 00:23:55 2012 +0200

gdb: build with expat, add missing RRECOMMENDS_gdbserver

Quoted 8 lines

* Fixes communication between gdbserver and gdb-cross by using the same expat settings for both recipes.
* Adds missing build dependencies for expat/expat-native.
* Adds missing glibc-thread-db runtime recommendation to gdbserver, which was set only for gdb.

Here it's trying to use host's expat when building target gdb and fails...

| checking for libexpat... no
| configure: error: expat is missing or unusable
| make[1]: *** [configure-gdb] Error 1
| make[1]: Leaving directory `/OE/shr-core/tmp-eglibc/work/armv7a-vfp-neon-oe-linux-gnueabi/gdb/gdb-7.4-r7.0/build-arm-oe-linux-gnueabi'
| make: *** [all] Error 2
| ERROR: oe_runmake failed

NOTE: package gdb-7.4-r7.0: task do_compile: Failed
ERROR: Task 3561 (/OE/shr-core/openembedded-core/meta/recipes-devtools/gdb/gdb_7.4.bb, do_compile) failed with exit code '1'

Quoted 6 lines

from config.log:
configure:10704: checking for libexpat
configure:10723: arm-oe-linux-gnueabi-gcc -march=armv7-a -fno-tree-vectorize -mthumb-interwork -mfloat-abi=softfp -mfpu=neon -mtune=cortex-a8 --sysroot=/OE/shr-core/tmp-eglibc/sysroots/om-gta04 -o conftest -O2 -pipe -g -feliminate-unused-debug-types -Wl,-O1 -Wl,--hash-style=gnu -Wl,--as-needed conftest.c -ldl -lncurses -lz -lm /usr/lib/libexpat.so >&5
/OE/shr-core/tmp-eglibc/sysroots/x86_64-linux/usr/libexec/armv7a-vfp-neon-oe-linux-gnueabi/gcc/arm-oe-linux-gnueabi/4.6.4/ld: error: /usr/lib/libexpat.so: incompatible target conftest.c:98: error: undefined reference to 'XML_ParserCreate'
collect2: ld returned 1 exit status

Does "bitbake expat" help? Here I have:

configure:10704: checking for libexpat
configure:10723: mipsel-oe-linux-gcc -mel -mabi=32 -mhard-float -march=mips32 --sysroot=/home/obi/src/git/opendreambox-2.1/tmp/sysroots/dm7020hd -o conftest -Os -pipe -g -feliminate-unused-debug-types -Wl,-O1 -Wl,--as-needed conftest.c -ldl -lncurses -lz -lm -lexpat >&5
configure:10723: $? = 0
configure:10733: result: yes

Regards,
Andreas

#3 lore raw
Quoted 32 lines · Andreas Oberritter
Quoted 31 lines · Martin Jansa
Quoted 10 lines · On Tue, Apr 03, 2012 at 01:15:37PM +0000, [email protected] wrote:
Module: openembedded-core.git
Branch: master
Commit: 38ee88e3b32b7444d7f1eb64f1b4f69a48fe0458
URL:    http://git.openembedded.org/?p=openembedded-core.git&a=commit;h=38ee88e3b32b7444d7f1eb64f1b4f69a48fe0458
Author: Andreas Oberritter <[email protected]>
Date:   Tue Apr  3 00:23:55 2012 +0200

gdb: build with expat, add missing RRECOMMENDS_gdbserver

Quoted 8 lines

* Fixes communication between gdbserver and gdb-cross by using the same expat settings for both recipes.
* Adds missing build dependencies for expat/expat-native.
* Adds missing glibc-thread-db runtime recommendation to gdbserver, which was set only for gdb.

Here it's trying to use host's expat when building target gdb and fails...

| checking for libexpat... no
| configure: error: expat is missing or unusable
| make[1]: *** [configure-gdb] Error 1
| make[1]: Leaving directory `/OE/shr-core/tmp-eglibc/work/armv7a-vfp-neon-oe-linux-gnueabi/gdb/gdb-7.4-r7.0/build-arm-oe-linux-gnueabi'
| make: *** [all] Error 2
| ERROR: oe_runmake failed

NOTE: package gdb-7.4-r7.0: task do_compile: Failed
ERROR: Task 3561 (/OE/shr-core/openembedded-core/meta/recipes-devtools/gdb/gdb_7.4.bb, do_compile) failed with exit code '1'

Quoted 8 lines
Quoted 6 lines

from config.log:
configure:10704: checking for libexpat
configure:10723: arm-oe-linux-gnueabi-gcc -march=armv7-a -fno-tree-vectorize -mthumb-interwork -mfloat-abi=softfp -mfpu=neon -mtune=cortex-a8 --sysroot=/OE/shr-core/tmp-eglibc/sysroots/om-gta04 -o conftest -O2 -pipe -g -feliminate-unused-debug-types -Wl,-O1 -Wl,--hash-style=gnu -Wl,--as-needed conftest.c -ldl -lncurses -lz -lm /usr/lib/libexpat.so >&5
/OE/shr-core/tmp-eglibc/sysroots/x86_64-linux/usr/libexec/armv7a-vfp-neon-oe-linux-gnueabi/gcc/arm-oe-linux-gnueabi/4.6.4/ld: error: /usr/lib/libexpat.so: incompatible target conftest.c:98: error: undefined reference to 'XML_ParserCreate'
collect2: ld returned 1 exit status

Does "bitbake expat" help? Here I have:

expat was built already, so no doesn't help.

-EXPAT = "--with-expat"
+EXPAT = "--with-expat --with-libexpat-prefix=${STAGING_DIR_HOST}"

helps..

Quoted 13 lines

configure:10704: checking for libexpat
configure:10723: mipsel-oe-linux-gcc -mel -mabi=32 -mhard-float -march=mips32 --sysroot=/home/obi/src/git/opendreambox-2.1/tmp/sysroots/dm7020hd -o conftest -Os -pipe -g -feliminate-unused-debug-types -Wl,-O1 -Wl,--as-needed conftest.c -ldl -lncurses -lz -lm -lexpat >&5
configure:10723: $? = 0
configure:10733: result: yes

Regards,
Andreas

_______________________________________________
Openembedded-core mailing list
[email protected]
http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-core

Signature · 1 line
Martin 'JaMa' Jansa     jabber: [email protected]
#4 lore raw
Quoted 48 lines · Martin Jansa
Quoted 32 lines · Andreas Oberritter
Quoted 31 lines · Martin Jansa
Quoted 10 lines · On Tue, Apr 03, 2012 at 01:15:37PM +0000, [email protected] wrote:
Module: openembedded-core.git
Branch: master
Commit: 38ee88e3b32b7444d7f1eb64f1b4f69a48fe0458
URL:    http://git.openembedded.org/?p=openembedded-core.git&a=commit;h=38ee88e3b32b7444d7f1eb64f1b4f69a48fe0458
Author: Andreas Oberritter <[email protected]>
Date:   Tue Apr  3 00:23:55 2012 +0200

gdb: build with expat, add missing RRECOMMENDS_gdbserver

Quoted 8 lines

* Fixes communication between gdbserver and gdb-cross by using the same expat settings for both recipes.
* Adds missing build dependencies for expat/expat-native.
* Adds missing glibc-thread-db runtime recommendation to gdbserver, which was set only for gdb.

Here it's trying to use host's expat when building target gdb and fails...

| checking for libexpat... no
| configure: error: expat is missing or unusable
| make[1]: *** [configure-gdb] Error 1
| make[1]: Leaving directory `/OE/shr-core/tmp-eglibc/work/armv7a-vfp-neon-oe-linux-gnueabi/gdb/gdb-7.4-r7.0/build-arm-oe-linux-gnueabi'
| make: *** [all] Error 2
| ERROR: oe_runmake failed

NOTE: package gdb-7.4-r7.0: task do_compile: Failed
ERROR: Task 3561 (/OE/shr-core/openembedded-core/meta/recipes-devtools/gdb/gdb_7.4.bb, do_compile) failed with exit code '1'

Quoted 8 lines
Quoted 6 lines

from config.log:
configure:10704: checking for libexpat
configure:10723: arm-oe-linux-gnueabi-gcc -march=armv7-a -fno-tree-vectorize -mthumb-interwork -mfloat-abi=softfp -mfpu=neon -mtune=cortex-a8 --sysroot=/OE/shr-core/tmp-eglibc/sysroots/om-gta04 -o conftest -O2 -pipe -g -feliminate-unused-debug-types -Wl,-O1 -Wl,--hash-style=gnu -Wl,--as-needed conftest.c -ldl -lncurses -lz -lm /usr/lib/libexpat.so >&5
/OE/shr-core/tmp-eglibc/sysroots/x86_64-linux/usr/libexec/armv7a-vfp-neon-oe-linux-gnueabi/gcc/arm-oe-linux-gnueabi/4.6.4/ld: error: /usr/lib/libexpat.so: incompatible target conftest.c:98: error: undefined reference to 'XML_ParserCreate'
collect2: ld returned 1 exit status

Does "bitbake expat" help? Here I have:

expat was built already, so no doesn't help.

(quoted diff) +1 -1
-EXPAT = "--with-expat"
+EXPAT = "--with-expat --with-libexpat-prefix=${STAGING_DIR_HOST}"
Quoted 1 line

helps..

OK. Can you please submit an incremental patch? I wonder why it didn't happen on my system, although I have libexpat-dev installed (Ubuntu). Which Linux distribution are you using?

Regards,
Andreas

#5 lore raw
Quoted 46 lines · Andreas Oberritter
Quoted 45 lines · Martin Jansa
Quoted 32 lines · Andreas Oberritter
Quoted 31 lines · Martin Jansa
Quoted 10 lines · On Tue, Apr 03, 2012 at 01:15:37PM +0000, [email protected] wrote:
Module: openembedded-core.git
Branch: master
Commit: 38ee88e3b32b7444d7f1eb64f1b4f69a48fe0458
URL:    http://git.openembedded.org/?p=openembedded-core.git&a=commit;h=38ee88e3b32b7444d7f1eb64f1b4f69a48fe0458
Author: Andreas Oberritter <[email protected]>
Date:   Tue Apr  3 00:23:55 2012 +0200

gdb: build with expat, add missing RRECOMMENDS_gdbserver

Quoted 8 lines

* Fixes communication between gdbserver and gdb-cross by using the same expat settings for both recipes.
* Adds missing build dependencies for expat/expat-native.
* Adds missing glibc-thread-db runtime recommendation to gdbserver, which was set only for gdb.

Here it's trying to use host's expat when building target gdb and fails...

| checking for libexpat... no
| configure: error: expat is missing or unusable
| make[1]: *** [configure-gdb] Error 1
| make[1]: Leaving directory `/OE/shr-core/tmp-eglibc/work/armv7a-vfp-neon-oe-linux-gnueabi/gdb/gdb-7.4-r7.0/build-arm-oe-linux-gnueabi'
| make: *** [all] Error 2
| ERROR: oe_runmake failed

NOTE: package gdb-7.4-r7.0: task do_compile: Failed
ERROR: Task 3561 (/OE/shr-core/openembedded-core/meta/recipes-devtools/gdb/gdb_7.4.bb, do_compile) failed with exit code '1'

Quoted 8 lines
Quoted 6 lines

from config.log:
configure:10704: checking for libexpat
configure:10723: arm-oe-linux-gnueabi-gcc -march=armv7-a -fno-tree-vectorize -mthumb-interwork -mfloat-abi=softfp -mfpu=neon -mtune=cortex-a8 --sysroot=/OE/shr-core/tmp-eglibc/sysroots/om-gta04 -o conftest -O2 -pipe -g -feliminate-unused-debug-types -Wl,-O1 -Wl,--hash-style=gnu -Wl,--as-needed conftest.c -ldl -lncurses -lz -lm /usr/lib/libexpat.so >&5
/OE/shr-core/tmp-eglibc/sysroots/x86_64-linux/usr/libexec/armv7a-vfp-neon-oe-linux-gnueabi/gcc/arm-oe-linux-gnueabi/4.6.4/ld: error: /usr/lib/libexpat.so: incompatible target conftest.c:98: error: undefined reference to 'XML_ParserCreate'
collect2: ld returned 1 exit status

Does "bitbake expat" help? Here I have:

expat was built already, so no doesn't help.

Quoted 7 lines
Quoted 4 lines
(quoted diff) +1 -1
-EXPAT = "--with-expat"
+EXPAT = "--with-expat --with-libexpat-prefix=${STAGING_DIR_HOST}"

helps..

OK. Can you please submit an incremental patch? I wonder why it didn't happen on my system, although I have libexpat-dev installed (Ubuntu).

I've tested it only with target gdb (so I don't feel comfortable to send patch before testing -cross-canadian and -cross, but I don't have time for it now).

Quoted 1 line

Which Linux distribution are you using?

Gentoo minimal chroot
http://git.shr-project.org/git/?p=shr-chroot.git;a=summary

Cheers,

Signature · 1 line
Martin 'JaMa' Jansa     jabber: [email protected]
#6 lore raw
Quoted 55 lines · Martin Jansa
Quoted 46 lines · Andreas Oberritter
Quoted 45 lines · Martin Jansa
Quoted 32 lines · Andreas Oberritter
Quoted 31 lines · Martin Jansa
Quoted 10 lines · On Tue, Apr 03, 2012 at 01:15:37PM +0000, [email protected] wrote:
Module: openembedded-core.git
Branch: master
Commit: 38ee88e3b32b7444d7f1eb64f1b4f69a48fe0458
URL:    http://git.openembedded.org/?p=openembedded-core.git&a=commit;h=38ee88e3b32b7444d7f1eb64f1b4f69a48fe0458
Author: Andreas Oberritter <[email protected]>
Date:   Tue Apr  3 00:23:55 2012 +0200

gdb: build with expat, add missing RRECOMMENDS_gdbserver

Quoted 8 lines

* Fixes communication between gdbserver and gdb-cross by using the same expat settings for both recipes.
* Adds missing build dependencies for expat/expat-native.
* Adds missing glibc-thread-db runtime recommendation to gdbserver, which was set only for gdb.

Here it's trying to use host's expat when building target gdb and fails...

| checking for libexpat... no
| configure: error: expat is missing or unusable
| make[1]: *** [configure-gdb] Error 1
| make[1]: Leaving directory `/OE/shr-core/tmp-eglibc/work/armv7a-vfp-neon-oe-linux-gnueabi/gdb/gdb-7.4-r7.0/build-arm-oe-linux-gnueabi'
| make: *** [all] Error 2
| ERROR: oe_runmake failed

NOTE: package gdb-7.4-r7.0: task do_compile: Failed
ERROR: Task 3561 (/OE/shr-core/openembedded-core/meta/recipes-devtools/gdb/gdb_7.4.bb, do_compile) failed with exit code '1'

Quoted 8 lines
Quoted 6 lines

from config.log:
configure:10704: checking for libexpat
configure:10723: arm-oe-linux-gnueabi-gcc -march=armv7-a -fno-tree-vectorize -mthumb-interwork -mfloat-abi=softfp -mfpu=neon -mtune=cortex-a8 --sysroot=/OE/shr-core/tmp-eglibc/sysroots/om-gta04 -o conftest -O2 -pipe -g -feliminate-unused-debug-types -Wl,-O1 -Wl,--hash-style=gnu -Wl,--as-needed conftest.c -ldl -lncurses -lz -lm /usr/lib/libexpat.so >&5
/OE/shr-core/tmp-eglibc/sysroots/x86_64-linux/usr/libexec/armv7a-vfp-neon-oe-linux-gnueabi/gcc/arm-oe-linux-gnueabi/4.6.4/ld: error: /usr/lib/libexpat.so: incompatible target conftest.c:98: error: undefined reference to 'XML_ParserCreate'
collect2: ld returned 1 exit status

Does "bitbake expat" help? Here I have:

expat was built already, so no doesn't help.

Quoted 7 lines
Quoted 4 lines
(quoted diff) +1 -1
-EXPAT = "--with-expat"
+EXPAT = "--with-expat --with-libexpat-prefix=${STAGING_DIR_HOST}"

helps..

OK. Can you please submit an incremental patch? I wonder why it didn't happen on my system, although I have libexpat-dev installed (Ubuntu).

Quoted 8 lines

I've tested it only with target gdb (so I don't feel comfortable to send patch before testing -cross-canadian and -cross, but I don't have time for it now).

Quoted 1 line

Which Linux distribution are you using?

Gentoo minimal chroot
http://git.shr-project.org/git/?p=shr-chroot.git;a=summary

confirmed on other host also using shr-chroot.. if you want to test it yourself, here is patch (or somewhere there if reabased already)
http://git.openembedded.org/openembedded-core-contrib/commit/?h=shr&id=ef16c225a564d465ebab800204434b0d684c4069

Cheers,

Signature · 1 line
Martin 'JaMa' Jansa     jabber: [email protected]
#7 lore raw
Quoted 60 lines · Martin Jansa
Quoted 59 lines · Martin Jansa
Quoted 46 lines · Andreas Oberritter
Quoted 45 lines · Martin Jansa
Quoted 32 lines · Andreas Oberritter
Quoted 31 lines · Martin Jansa
Quoted 10 lines · On Tue, Apr 03, 2012 at 01:15:37PM +0000, [email protected] wrote:
Module: openembedded-core.git
Branch: master
Commit: 38ee88e3b32b7444d7f1eb64f1b4f69a48fe0458
URL:    http://git.openembedded.org/?p=openembedded-core.git&a=commit;h=38ee88e3b32b7444d7f1eb64f1b4f69a48fe0458
Author: Andreas Oberritter <[email protected]>
Date:   Tue Apr  3 00:23:55 2012 +0200

gdb: build with expat, add missing RRECOMMENDS_gdbserver

Quoted 8 lines

* Fixes communication between gdbserver and gdb-cross by using the same expat settings for both recipes.
* Adds missing build dependencies for expat/expat-native.
* Adds missing glibc-thread-db runtime recommendation to gdbserver, which was set only for gdb.

Here it's trying to use host's expat when building target gdb and fails...

| checking for libexpat... no
| configure: error: expat is missing or unusable
| make[1]: *** [configure-gdb] Error 1
| make[1]: Leaving directory `/OE/shr-core/tmp-eglibc/work/armv7a-vfp-neon-oe-linux-gnueabi/gdb/gdb-7.4-r7.0/build-arm-oe-linux-gnueabi'
| make: *** [all] Error 2
| ERROR: oe_runmake failed

NOTE: package gdb-7.4-r7.0: task do_compile: Failed
ERROR: Task 3561 (/OE/shr-core/openembedded-core/meta/recipes-devtools/gdb/gdb_7.4.bb, do_compile) failed with exit code '1'

Quoted 8 lines
Quoted 6 lines

from config.log:
configure:10704: checking for libexpat
configure:10723: arm-oe-linux-gnueabi-gcc -march=armv7-a -fno-tree-vectorize -mthumb-interwork -mfloat-abi=softfp -mfpu=neon -mtune=cortex-a8 --sysroot=/OE/shr-core/tmp-eglibc/sysroots/om-gta04 -o conftest -O2 -pipe -g -feliminate-unused-debug-types -Wl,-O1 -Wl,--hash-style=gnu -Wl,--as-needed conftest.c -ldl -lncurses -lz -lm /usr/lib/libexpat.so >&5
/OE/shr-core/tmp-eglibc/sysroots/x86_64-linux/usr/libexec/armv7a-vfp-neon-oe-linux-gnueabi/gcc/arm-oe-linux-gnueabi/4.6.4/ld: error: /usr/lib/libexpat.so: incompatible target conftest.c:98: error: undefined reference to 'XML_ParserCreate'
collect2: ld returned 1 exit status

Does "bitbake expat" help? Here I have:

expat was built already, so no doesn't help.

Quoted 7 lines
Quoted 4 lines
(quoted diff) +1 -1
-EXPAT = "--with-expat"
+EXPAT = "--with-expat --with-libexpat-prefix=${STAGING_DIR_HOST}"

helps..

OK. Can you please submit an incremental patch? I wonder why it didn't happen on my system, although I have libexpat-dev installed (Ubuntu).

I've tested it only with target gdb (so I don't feel comfortable to send patch before testing -cross-canadian and -cross, but I don't have time for it now).

Quoted 8 lines
Quoted 4 lines
Quoted 1 line

Which Linux distribution are you using?

Gentoo minimal chroot
http://git.shr-project.org/git/?p=shr-chroot.git;a=summary

confirmed on other host also using shr-chroot.. if you want to test it yourself, here is patch (or somewhere there if reabased already)
http://git.openembedded.org/openembedded-core-contrib/commit/?h=shr&id=ef16c225a564d465ebab800204434b0d684c4069

I've built gdb-cross with your patch applied without problems. gdb-cross-canadian-mipsel is still compiling. However, since the problem you discovered didn't show on my machine, this may not be meaningful at all.

Regards,
Andreas

#8 lore raw
Quoted 3 lines · Andreas Oberritter

I've built gdb-cross with your patch applied without problems. gdb-cross-canadian-mipsel is still compiling. However, since the problem you discovered didn't show on my machine, this may not be meaningful at all.

FWIW, gdb-cross-canadian-mipsel also finished without errors.

Quoted 2 lines

Regards,
Andreas

#9 lore raw
In reply to Martin Jansa

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Quoted 4 lines · Martin Jansa
Quoted 4 lines
Quoted 4 lines
Quoted 4 lines
Quoted 4 lines

-EXPAT = "--with-expat" +EXPAT = "--with-expat
--with-libexpat-prefix=${STAGING_DIR_HOST}"

Quoted 9 lines
Quoted 5 lines
Quoted 5 lines
Quoted 1 line
Quoted 1 line

helps..

OK. Can you please submit an incremental patch? I wonder why it didn't happen on my system, although I have libexpat-dev installed (Ubuntu).

I've tested it only with target gdb (so I don't feel comfortable to send patch before testing -cross-canadian and -cross, but I don't have time for it now).

This patch is good. So dont hesitate to send it. -----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAk9/2GMACgkQuwUzVZGdMxSOAgCcCKwcG44tZMcTxkdY5tMgy2xj qhYAnivdRqKDZoO4+lIjO9vPsX/lSCq1
=sMZh
-----END PGP SIGNATURE-----

#10 lore raw

Op 7 apr. 2012, om 08:02 heeft Khem Raj het volgende geschreven:

Quoted 10 lines · Martin Jansa
Quoted 9 lines
Quoted 9 lines
Quoted 9 lines
Quoted 5 lines
Quoted 5 lines

-EXPAT = "--with-expat" +EXPAT = "--with-expat
--with-libexpat-prefix=${STAGING_DIR_HOST}"

helps..

OK. Can you please submit an incremental patch? I wonder why it didn't happen on my system, although I have libexpat-dev installed (Ubuntu).

Quoted 6 lines
Quoted 4 lines

I've tested it only with target gdb (so I don't feel comfortable to send patch before testing -cross-canadian and -cross, but I don't have time for it now).

This patch is good. So dont hesitate to send it.

Indeed, let's get it in before the yocto-1.2 releasebranch gets created.

#11 lore raw

PATCH 1/1 gdb: add --with-libexpat-prefix

In reply to Andreas Oberritter

* otherwise it sometimes finds host's expat

---
 meta/recipes-devtools/gdb/gdb-common.inc |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
meta/recipes-devtools/gdb/gdb-common.inc +1 -1
index a8fca6f..4f7ea4b 100644
@@ -36,7 +36,7 @@ B = "${WORKDIR}/build-${TARGET_SYS}"
 
 EXTRA_OEMAKE = "'SUBDIRS=intl mmalloc libiberty opcodes bfd sim gdb etc utils'"
 
-EXPAT = "--with-expat"
+EXPAT = "--with-expat --with-libexpat-prefix=${STAGING_DIR_HOST}"
 
 EXTRA_OECONF = "--disable-gdbtk --disable-tui --disable-x \
                 --with-curses --disable-multilib --with-system-readline --disable-sim \
Signature · 1 line
1.7.8.5