lttng-tools: Fix compilation
PATCH 1/1 lttng-tools: Fix compilation
Compiling lttng-tools fails when lttng-libust is enabled bacause of a missing -lurcu-bp in the linker command line, at least for linaro 2012.12 toolchain.
--- package/lttng-tools/lttng-tools.mk | 2 ++ 1 files changed, 2 insertions(+), 0 deletions(-)
package/lttng-tools/lttng-tools.mk +2 -0
@@ -21,6 +21,8 @@ LTTNG_AUTORECONF = YES ifeq ($(BR2_PACKAGE_LTTNG_LIBUST),y) LTTNG_TOOLS_CONF_OPT += --enable-lttng-ust LTTNG_TOOLS_DEPENDENCIES += lttng-libust +# Build fails without this, at least with Linuaro 2012.12 toolchain +LTTNG_TOOLS_CONF_ENV += LDFLAGS="$(TARGET_LDFLAGS) -lurcu-bp" else LTTNG_TOOLS_CONF_OPT += --disable-lttng-ust endif
Signature · 1 line
1.7.0.4
PATCH 1/1 lttng-tools: Fix compilation
Hi Stephan,
2013/2/4 Stephan Hoffmann <[email protected]>:
Quoted 1 line
Compiling lttng-tools fails when lttng-libust is enabled bacause of a missing
s/bacause/because/
Quoted 1 line
-lurcu-bp in the linker command line, at least for linaro 2012.12 toolchain.
hum... weird!
lttng-tools handles that in its configure file, checking for ustctl_set_filter availability in liblttng-ust-ctl; see:
http://git.lttng.org/?p=lttng-tools.git;a=blob;f=configure.ac;h=91e76f06a98700d2a9deb36c29a650176e62c4ab;hb=HEAD#l137
Are you sure lttng-libust was correctly built before? Could you give more details about the linking error?
It may also be something to report upstream, lttng guys are quite responsive.
Quoted 22 lines
Signed-off-by Stephan Hoffmann <[email protected]>--- package/lttng-tools/lttng-tools.mk | 2 ++ 1 files changed, 2 insertions(+), 0 deletions(-)package/lttng-tools/lttng-tools.mk +2
-1@@ -21,6 +21,8 @@ LTTNG_AUTORECONF = YES ifeq ($(BR2_PACKAGE_LTTNG_LIBUST),y) LTTNG_TOOLS_CONF_OPT += --enable-lttng-ust LTTNG_TOOLS_DEPENDENCIES += lttng-libust +# Build fails without this, at least with Linuaro 2012.12 toolchain +LTTNG_TOOLS_CONF_ENV += LDFLAGS="$(TARGET_LDFLAGS) -lurcu-bp" else LTTNG_TOOLS_CONF_OPT += --disable-lttng-ust endif --1.7.0.4
Quoted 4 lines
_______________________________________________
buildroot mailing list
buildroot at busybox.net
http://lists.busybox.net/mailman/listinfo/buildroot
Regards,
Signature · 1 line
Samuel
PATCH 1/1 lttng-tools: Fix compilation
Hello Samuel,
Am 04.02.2013 15:49, schrieb Samuel Martin:
Quoted 7 lines
Hi Stephan,
2013/2/4 Stephan Hoffmann <[email protected]>:
Quoted 1 line
Compiling lttng-tools fails when lttng-libust is enabled bacause of a missing
s/bacause/because/
Quoted 1 line
-lurcu-bp in the linker command line, at least for linaro 2012.12 toolchain.
Quoted 8 lines
hum... weird!
lttng-tools handles that in its configure file, checking for
ustctl_set_filteravailability in liblttng-ust-ctl; see:
http://git.lttng.org/?p=lttng-tools.git;a=blob;f=configure.ac;h=91e76f06a98700d2a9deb36c29a650176e62c4ab;hb=HEAD#l137Are you sure lttng-libust was correctly built before? Could you give more details about the linking error?
the error message I always got is:
Quoted 7 lines
make[4]: Betrete Verzeichnis
'/opt/scratch/buildroot/output/build/lttng-tools-2.1.1/tests/tools/streaming'
CCLD gen-ust-events/opt/scratch/buildroot/output/host/opt/ext-toolchain/bin/../lib/gcc/arm-linux-gnueabihf/4.7.3/../../../../arm-linux-gnueabihf/bin/ld:
tp.o: undefined reference to symbol 'rcu_dereference_sym'/opt/scratch/buildroot/output/host/opt/ext-toolchain/bin/../lib/gcc/arm-linux-gnueabihf/4.7.3/../../../../arm-linux-gnueabihf/bin/ld:
note: 'rcu_dereference_sym' is defined in DSO
Quoted 8 lines
/opt/scratch/buildroot/output/host/usr/arm-buildroot-linux-gnueabi/sysroot/usr/lib/liburcu-bp.so.1so try adding it to the linker command line/opt/scratch/buildroot/output/host/usr/arm-buildroot-linux-gnueabi/sysroot/usr/lib/liburcu-bp.so.1:
could not read symbols: Invalid operation
collect2: error: ld returned 1 exit status
make[4]: *** [gen-ust-events] Fehler 1
make[4]: Verlasse Verzeichnis '/opt/scratch/buildroot/output/build/lttng-tools-2.1.1/tests/tools/streaming'
But even worse: now I cannot reproduce it. Maybe you're right and there was something wrong with libust. I cannot verify that I really called "make clean" while hunting for this. So for now let's assume that I forgot it.
Btw: Originally, I wanted to use the internal toolchain, but the default one (4.6) cannot compile libust (see autobuild logs). After switching to gcc 4.7 it compiles, but "lttng list -k" does not find any events.
Kind regards
Stephan
Quoted 31 lines
It may also be something to report upstream, lttng guys are quite responsive.
Quoted 21 lines
Signed-off-by Stephan Hoffmann <[email protected]>--- package/lttng-tools/lttng-tools.mk | 2 ++ 1 files changed, 2 insertions(+), 0 deletions(-)package/lttng-tools/lttng-tools.mk +2
-1@@ -21,6 +21,8 @@ LTTNG_AUTORECONF = YES ifeq ($(BR2_PACKAGE_LTTNG_LIBUST),y) LTTNG_TOOLS_CONF_OPT += --enable-lttng-ust LTTNG_TOOLS_DEPENDENCIES += lttng-libust +# Build fails without this, at least with Linuaro 2012.12 toolchain +LTTNG_TOOLS_CONF_ENV += LDFLAGS="$(TARGET_LDFLAGS) -lurcu-bp" else LTTNG_TOOLS_CONF_OPT += --disable-lttng-ust endif --1.7.0.4
Quoted 4 lines
_______________________________________________
buildroot mailing list
buildroot at busybox.net
http://lists.busybox.net/mailman/listinfo/buildrootRegards,
Signature · 4 lines
reLinux - Stephan Hoffmann Am Schmidtgrund 124 50765 K?ln Tel. +49.221.95595-19 Fax: -64 www.reLinux.de sho at reLinux.de