Skip to contentSkip to conversation

Build failure in test-coroutine.c

Qemu-devel Erik Rull 2 participants 4 messages Jan 19, 2012 – Feb 7, 2012

lore
Share & tools
lore

Erik Rull

author
#0 lore raw

Hi all,

I just got a copy of the current qemu-kvm but there is a build failure in test-coroutine.c:

erik@debian:~/qemu-test/qemu-kvm$ make
[...]
  CC    test-coroutine.o
test-coroutine.c: In function 'test_nesting':
test-coroutine.c:92: warning: implicit declaration of function 'g_assert_cmpint'
test-coroutine.c:92: warning: nested extern declaration of 'g_assert_cmpint'
test-coroutine.c:92: error: expected expression before '==' token
test-coroutine.c:93: error: expected expression before '==' token
test-coroutine.c: In function 'test_yield':
test-coroutine.c:122: error: expected expression before '==' token
test-coroutine.c: In function 'perf_lifecycle':
test-coroutine.c:170: warning: implicit declaration of function 'g_test_timer_start'
test-coroutine.c:170: warning: nested extern declaration of 'g_test_timer_start'
test-coroutine.c:175: warning: implicit declaration of function 'g_test_timer_elapsed'
test-coroutine.c:175: warning: nested extern declaration of 'g_test_timer_elapsed'
test-coroutine.c:177: warning: implicit declaration of function 'g_test_message'
test-coroutine.c:177: warning: nested extern declaration of 'g_test_message'
test-coroutine.c: In function 'main':
test-coroutine.c:182: warning: implicit declaration of function 'g_test_init'
test-coroutine.c:182: warning: nested extern declaration of 'g_test_init'
test-coroutine.c:183: warning: implicit declaration of function 'g_test_add_func'
test-coroutine.c:183: warning: nested extern declaration of 'g_test_add_func'
test-coroutine.c:188: warning: implicit declaration of function 'g_test_perf'
test-coroutine.c:188: warning: nested extern declaration of 'g_test_perf'
test-coroutine.c:191: warning: implicit declaration of function 'g_test_run'
test-coroutine.c:191: warning: nested extern declaration of 'g_test_run'
make: *** [test-coroutine.o] Error 1
erik@debian:~/qemu-test/qemu-kvm$

Any ideas how to fix that?

Best regards,

Erik

#1 lore raw
Quoted 2 lines · Erik Rull

test-coroutine.c:92: warning: implicit declaration of function 'g_assert_cmpint'

...

Quoted 1 line

erik@debian:~/qemu-test/qemu-kvm$

This must be an old Debian box. Debian stable has a new enough glib that provides g_assert_cmpint().

The glib testing infrastructure requires glib 2.16 or later. It's trivial to write a replacement g_assert_cmpint() for old systems but unfortunately you're also missing the core testing framework (g_test_run() and friends) so it's not that easy to backport.

Which version of distro version are you using? Which glib version are you using?

Stefan

author
#2 lore raw
Quoted 14 lines · Stefan Hajnoczi
Quoted 2 lines · Erik Rull

test-coroutine.c:92: warning: implicit declaration of function 'g_assert_cmpint'

...

Quoted 1 line

erik@debian:~/qemu-test/qemu-kvm$

This must be an old Debian box. Debian stable has a new enough glib that provides g_assert_cmpint().

The glib testing infrastructure requires glib 2.16 or later. It's trivial to write a replacement g_assert_cmpint() for old systems but unfortunately you're also missing the core testing framework (g_test_run() and friends) so it's not that easy to backport.

Quoted 5 lines

Which version of distro version are you using? Which glib version are you using?

Stefan

Hi Stefan,

it is Debian 4.0 glib 2.0
Can you add a ./configure option to just remove the compilation of the test infrastructure? I don't need it. Currently I just modify my configure script...

Best regards,

Erik

P.S. I'm planning to upgrade to a "more recent" version during this year...

#3 lore raw
Quoted 24 lines · Erik Rull
Quoted 14 lines · Stefan Hajnoczi
Quoted 2 lines · Erik Rull

test-coroutine.c:92: warning: implicit declaration of function 'g_assert_cmpint'

...

Quoted 1 line

erik@debian:~/qemu-test/qemu-kvm$

This must be an old Debian box.  Debian stable has a new enough glib that provides g_assert_cmpint().

The glib testing infrastructure requires glib 2.16 or later.  It's trivial to write a replacement g_assert_cmpint() for old systems but unfortunately you're also missing the core testing framework (g_test_run() and friends) so it's not that easy to backport.

Quoted 5 lines

Which version of distro version are you using?  Which glib version are you using?

Stefan

Quoted 6 lines

Hi Stefan,

it is Debian 4.0 glib 2.0
Can you add a ./configure option to just remove the compilation of the test infrastructure? I don't need it. Currently I just modify my configure script...

I have added this to my todo list but am unsure when I can come up with a patch. If you or anyone else wants to do it, please go ahead.

Stefan