Skip to contentSkip to conversation

Fix linking when using UST tracing

PATCH Applied Lluís Vilanova 2 participants 7 messages Apr 2, 2012 – Apr 3, 2012

lore
Share & tools
lore
#0 lore raw

cover Fix linking when using UST tracing

---

Lluís Vilanova (3):
configure: Fix typo 'lib_qga' -> 'libs_qga'
configure: Link QEMU against 'liburcu-bp'
configure: Link qga against UST tracing related libraries

 configure |    5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)
#1 lore raw

PATCH 1/3 configure: Fix typo 'lib_qga' -> 'libs_qga'

---
 configure |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
configure +1 -1
index bea4a2c..c7be13d 100755
@@ -526,7 +526,7 @@ EOF
   bindir="\${prefix}"
   sysconfdir="\${prefix}"
   confsuffix=""
-  libs_qga="-lws2_32 -lwinmm -lpowrprof $lib_qga"
+  libs_qga="-lws2_32 -lwinmm -lpowrprof $libs_qga"
 fi
 
 werror=""
#2 lore raw

Re: [Qemu-devel] [PATCH 1/3] configure: Fix typo 'lib_qga' -> 'libs_qga'

Quoted 10 lines · Lluís Vilanova
---
 configure |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
configure +0 -0
index bea4a2c..c7be13d 100755

configure EOF · line 532

Quoted 8 lines
configure +1 -1
@@ -526,7 +526,7 @@ EOF
   bindir="\${prefix}"
   sysconfdir="\${prefix}"
   confsuffix=""
-  libs_qga="-lws2_32 -lwinmm -lpowrprof $lib_qga"
+  libs_qga="-lws2_32 -lwinmm -lpowrprof $libs_qga"
 fi
 
 werror=""

An equivalent patch is already in the trivial-patches tree:
http://patchwork.ozlabs.org/patch/148919/

Thanks,
Stefan

#3 lore raw

PATCH 2/3 configure: Link QEMU against 'liburcu-bp'

In reply to Lluís Vilanova

This library is needed when using 'ust/tracepoint.h'.

---
 configure |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
configure +1 -1
index c7be13d..30591b0 100755
@@ -2672,7 +2672,7 @@ if test "$trace_backend" = "ust"; then
 int main(void) { return 0; }
 EOF
   if compile_prog "" "" ; then
-    LIBS="-lust $LIBS"
+    LIBS="-lust -lurcu-bp $LIBS"
   else
     echo
     echo "Error: Trace backend 'ust' missing libust header files"
#4 lore raw

Re: [Qemu-devel] [PATCH 2/3] configure: Link QEMU against 'liburcu-bp'

Quoted 7 lines · Lluís Vilanova

This library is needed when using 'ust/tracepoint.h'.

---
 configure |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

Thanks, applied to the trivial patches tree:
https://github.com/stefanha/qemu/commits/trivial-patches

I also sent an email to lttng-devel asking if pkg-config --libs ust should include this, you are CCed. If the library details will change it would be best for us to use pkg-config.

Stefan

#5 lore raw

PATCH 3/3 configure: Link qga against UST tracing related libraries

In reply to Lluís Vilanova
---
 configure |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)
configure +1 -0
index 30591b0..e72f66f 100755
@@ -2673,6 +2673,7 @@ int main(void) { return 0; }
 EOF
   if compile_prog "" "" ; then
     LIBS="-lust -lurcu-bp $LIBS"
+    libs_qga="-lust -lurcu-bp $libs_qga"
   else
     echo
     echo "Error: Trace backend 'ust' missing libust header files"
#6 lore raw

Re: [Qemu-devel] [PATCH 3/3] configure: Link qga against UST tracing related libraries

Quoted 5 lines · Lluís Vilanova
---
 configure |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

Thanks, applied to the trivial patches tree:
https://github.com/stefanha/qemu/commits/trivial-patches

It would be nice to clean up libs_qga in the future so that common library lists can be reused instead of duplicating them in both LIBS and libs_qga. Anyway, thanks for this fix.

Stefan