Skip to contentSkip to conversation

undefined reference to `trace_qemu_anon_ram_alloc'

Qemu-devel Nigel Horne 3 participants 8 messages May 27, 2013 – Oct 19, 2016

lore
Share & tools
lore
#0 lore raw

Public bug reported:

The latest git version (commit 6a4e17711442849bf2cc731ccddef5a2a2d92d29) fails to compile:

...
LINK qemu-ga
libqemuutil.a(oslib-posix.o): In function `qemu_anon_ram_alloc':
oslib-posix.c:(.text+0x154): undefined reference to trace_qemu_anon_ram_alloc' libqemuutil.a(oslib-posix.o): In function qemu_anon_ram_free':
oslib-posix.c:(.text+0x1e7): undefined reference to `trace_qemu_anon_ram_free'
collect2: error: ld returned 1 exit status
make: *** [qemu-ga] Error 1

This is on Ubuntu 13.04, gcc 4.7.3, configure flags:
'./configure' '--enable-linux-aio' '--enable-kvm' '--enable-vhost-net'

** Affects: qemu
Importance: Undecided
Status: New

Signature · 28 lines
You received this bug notification because you are a member of qemu-
devel-ml, which is subscribed to QEMU.
https://bugs.launchpad.net/bugs/1184616

Title:
   undefined reference to `trace_qemu_anon_ram_alloc'

Status in QEMU:
  New

Bug description:
  The latest git version (commit
  6a4e17711442849bf2cc731ccddef5a2a2d92d29) fails to compile:

  ...
    LINK  qemu-ga
  libqemuutil.a(oslib-posix.o): In function `qemu_anon_ram_alloc':
  oslib-posix.c:(.text+0x154): undefined reference to `trace_qemu_anon_ram_alloc'
  libqemuutil.a(oslib-posix.o): In function `qemu_anon_ram_free':
  oslib-posix.c:(.text+0x1e7): undefined reference to `trace_qemu_anon_ram_free'
  collect2: error: ld returned 1 exit status
  make: *** [qemu-ga] Error 1

  This is on Ubuntu 13.04, gcc 4.7.3, configure flags: 
  './configure' '--enable-linux-aio' '--enable-kvm' '--enable-vhost-net'

To manage notifications about this bug go to:
https://bugs.launchpad.net/qemu/+bug/1184616/+subscriptions
#1 lore raw
Quoted 12 lines · Nigel Horne

The latest git version (commit 6a4e17711442849bf2cc731ccddef5a2a2d92d29) fails to compile:

...
LINK qemu-ga
libqemuutil.a(oslib-posix.o): In function `qemu_anon_ram_alloc':
oslib-posix.c:(.text+0x154): undefined reference to trace_qemu_anon_ram_alloc' libqemuutil.a(oslib-posix.o): In function qemu_anon_ram_free':
oslib-posix.c:(.text+0x1e7): undefined reference to `trace_qemu_anon_ram_free'
collect2: error: ld returned 1 exit status
make: *** [qemu-ga] Error 1

Quoted 2 lines

This is on Ubuntu 13.04, gcc 4.7.3, configure flags:
'./configure' '--enable-linux-aio' '--enable-kvm' '--enable-vhost-net'

Please try:
make distclean && ./configure --enable-linux-aio --enable-kvm --enable-vhost-net && make

Stefan

#2 lore raw

Re: [Qemu-devel] [Bug 1184616] [NEW] undefined reference to`trace_qemu_anon_ram_alloc'

Quoted 16 lines
Quoted 14 lines · Nigel Horne

The latest git version (commit 6a4e17711442849bf2cc731ccddef5a2a2d92d29) fails to compile:

...
LINK qemu-ga
libqemuutil.a(oslib-posix.o): In function `qemu_anon_ram_alloc':
oslib-posix.c:(.text+0x154): undefined reference to trace_qemu_anon_ram_alloc' libqemuutil.a(oslib-posix.o): In function qemu_anon_ram_free':
oslib-posix.c:(.text+0x1e7): undefined reference to `trace_qemu_anon_ram_free'
collect2: error: ld returned 1 exit status
make: *** [qemu-ga] Error 1

Quoted 6 lines
Quoted 2 lines

This is on Ubuntu 13.04, gcc 4.7.3, configure flags:
'./configure' '--enable-linux-aio' '--enable-kvm' '--enable-vhost-net'

Please try:
make distclean && ./configure --enable-linux-aio --enable-kvm --enable-vhost-net && make

I tried that before I raised the bug. However I tried it again to be sure, and yes I still get the same error.

Quoted 2 lines

Stefan

Regards,

-Nigel

Signature · 28 lines
You received this bug notification because you are a member of qemu-
devel-ml, which is subscribed to QEMU.
https://bugs.launchpad.net/bugs/1184616

Title:
   undefined reference to `trace_qemu_anon_ram_alloc'

Status in QEMU:
  New

Bug description:
  The latest git version (commit
  6a4e17711442849bf2cc731ccddef5a2a2d92d29) fails to compile:

  ...
    LINK  qemu-ga
  libqemuutil.a(oslib-posix.o): In function `qemu_anon_ram_alloc':
  oslib-posix.c:(.text+0x154): undefined reference to `trace_qemu_anon_ram_alloc'
  libqemuutil.a(oslib-posix.o): In function `qemu_anon_ram_free':
  oslib-posix.c:(.text+0x1e7): undefined reference to `trace_qemu_anon_ram_free'
  collect2: error: ld returned 1 exit status
  make: *** [qemu-ga] Error 1

  This is on Ubuntu 13.04, gcc 4.7.3, configure flags: 
  './configure' '--enable-linux-aio' '--enable-kvm' '--enable-vhost-net'

To manage notifications about this bug go to:
https://bugs.launchpad.net/qemu/+bug/1184616/+subscriptions
#3 lore raw

Re: [Qemu-devel] [Bug 1184616] [NEW] undefined reference to`trace_qemu_anon_ram_alloc'

Quoted 19 lines · Nigel Horne
Quoted 19 lines
Quoted 16 lines · Nigel Horne

The latest git version (commit 6a4e17711442849bf2cc731ccddef5a2a2d92d29) fails to compile:

...
LINK qemu-ga
libqemuutil.a(oslib-posix.o): In function `qemu_anon_ram_alloc':
oslib-posix.c:(.text+0x154): undefined reference to trace_qemu_anon_ram_alloc' libqemuutil.a(oslib-posix.o): In function qemu_anon_ram_free':
oslib-posix.c:(.text+0x1e7): undefined reference to `trace_qemu_anon_ram_free'
collect2: error: ld returned 1 exit status
make: *** [qemu-ga] Error 1

This is on Ubuntu 13.04, gcc 4.7.3, configure flags:
'./configure' '--enable-linux-aio' '--enable-kvm' '--enable-vhost-net'

Quoted 6 lines
Quoted 3 lines

Please try:
make distclean && ./configure --enable-linux-aio --enable-kvm --enable-vhost-net && make

I tried that before I raised the bug. However I tried it again to be sure, and yes I still get the same error.

Please post the output of "git status". I wonder if there are stale files because the build works fine here.

Stefan

#4 lore raw

Re: [Qemu-devel] [Bug 1184616] [NEW] undefined reference to`trace_qemu_anon_ram_alloc'

Quoted 24 lines · Stefan Hajnoczi
Quoted 23 lines · Nigel Horne
Quoted 22 lines
Quoted 14 lines · Nigel Horne

The latest git version (commit 6a4e17711442849bf2cc731ccddef5a2a2d92d29) fails to compile:

...
LINK qemu-ga
libqemuutil.a(oslib-posix.o): In function `qemu_anon_ram_alloc':
oslib-posix.c:(.text+0x154): undefined reference to trace_qemu_anon_ram_alloc' libqemuutil.a(oslib-posix.o): In function qemu_anon_ram_free':
oslib-posix.c:(.text+0x1e7): undefined reference to `trace_qemu_anon_ram_free'
collect2: error: ld returned 1 exit status
make: *** [qemu-ga] Error 1

Quoted 2 lines

This is on Ubuntu 13.04, gcc 4.7.3, configure flags:
'./configure' '--enable-linux-aio' '--enable-kvm' '--enable-vhost-net'

Please try:
make distclean && ./configure --enable-linux-aio --enable-kvm --enable-vhost-net && make

Quoted 8 lines
Quoted 2 lines

I tried that before I raised the bug. However I tried it again to be sure, and yes I still get the same error.

Please post the output of "git status". I wonder if there are stale files because the build works fine here.

Stefan

In my case, git ignored files may also have affects. So make distclean then git clean -dfx is worth a try.

Signature · 1 line
Fam
#5 lore raw

Re: [Qemu-devel] [Bug 1184616] [NEW] undefined reference to`trace_qemu_anon_ram_alloc'

In reply to Stefan Hajnoczi
Quoted 18 lines
Quoted 18 lines
Quoted 18 lines
Quoted 16 lines · Nigel Horne

The latest git version (commit 6a4e17711442849bf2cc731ccddef5a2a2d92d29) fails to compile:

...
LINK qemu-ga
libqemuutil.a(oslib-posix.o): In function `qemu_anon_ram_alloc':
oslib-posix.c:(.text+0x154): undefined reference to trace_qemu_anon_ram_alloc' libqemuutil.a(oslib-posix.o): In function qemu_anon_ram_free':
oslib-posix.c:(.text+0x1e7): undefined reference to `trace_qemu_anon_ram_free'
collect2: error: ld returned 1 exit status
make: *** [qemu-ga] Error 1

This is on Ubuntu 13.04, gcc 4.7.3, configure flags:
'./configure' '--enable-linux-aio' '--enable-kvm' '--enable-vhost-net'

Quoted 7 lines
Quoted 5 lines
Quoted 3 lines

Please try:
make distclean && ./configure --enable-linux-aio --enable-kvm --enable-vhost-net && make

I tried that before I raised the bug. However I tried it again to be sure, and yes I still get the same error.

Please post the output of "git status". I wonder if there are stale files because the build works fine here.

Here it is:

# On branch master
# Untracked files:
# (use "git add <file>..." to include in what will be committed)
#

#       libhw32/
#       libhw64/
#       trace.c
#       trace.h

I don't do any local modification just 'git pull' and recompile. Perhaps git is broken so I should 'git clone' and start again.

-Nigel

Signature · 28 lines
You received this bug notification because you are a member of qemu-
devel-ml, which is subscribed to QEMU.
https://bugs.launchpad.net/bugs/1184616

Title:
   undefined reference to `trace_qemu_anon_ram_alloc'

Status in QEMU:
  New

Bug description:
  The latest git version (commit
  6a4e17711442849bf2cc731ccddef5a2a2d92d29) fails to compile:

  ...
    LINK  qemu-ga
  libqemuutil.a(oslib-posix.o): In function `qemu_anon_ram_alloc':
  oslib-posix.c:(.text+0x154): undefined reference to `trace_qemu_anon_ram_alloc'
  libqemuutil.a(oslib-posix.o): In function `qemu_anon_ram_free':
  oslib-posix.c:(.text+0x1e7): undefined reference to `trace_qemu_anon_ram_free'
  collect2: error: ld returned 1 exit status
  make: *** [qemu-ga] Error 1

  This is on Ubuntu 13.04, gcc 4.7.3, configure flags: 
  './configure' '--enable-linux-aio' '--enable-kvm' '--enable-vhost-net'

To manage notifications about this bug go to:
https://bugs.launchpad.net/qemu/+bug/1184616/+subscriptions
#6 lore raw

Re: [Qemu-devel] [Bug 1184616] [NEW] undefined reference to`trace_qemu_anon_ram_alloc'

Quoted 28 lines · Nigel Horne
Quoted 18 lines
Quoted 18 lines
Quoted 18 lines
Quoted 16 lines · Nigel Horne

The latest git version (commit 6a4e17711442849bf2cc731ccddef5a2a2d92d29) fails to compile:

...
LINK qemu-ga
libqemuutil.a(oslib-posix.o): In function `qemu_anon_ram_alloc':
oslib-posix.c:(.text+0x154): undefined reference to trace_qemu_anon_ram_alloc' libqemuutil.a(oslib-posix.o): In function qemu_anon_ram_free':
oslib-posix.c:(.text+0x1e7): undefined reference to `trace_qemu_anon_ram_free'
collect2: error: ld returned 1 exit status
make: *** [qemu-ga] Error 1

This is on Ubuntu 13.04, gcc 4.7.3, configure flags:
'./configure' '--enable-linux-aio' '--enable-kvm' '--enable-vhost-net'

Quoted 7 lines
Quoted 5 lines
Quoted 3 lines

Please try:
make distclean && ./configure --enable-linux-aio --enable-kvm --enable-vhost-net && make

I tried that before I raised the bug. However I tried it again to be sure, and yes I still get the same error.

Please post the output of "git status". I wonder if there are stale files because the build works fine here.

Here it is:

Quoted 8 lines

# On branch master
# Untracked files:
# (use "git add <file>..." to include in what will be committed)
#

#       libhw32/
#       libhw64/
#       trace.c
#       trace.h

rm trace.[ch]

Then try again.

The problem is that the auto-generated tracing files moved into trace/generated-* but the Makefile and C compiler include paths still pick up the old trace.[ch].

You probably built an older version of QEMU first in the same directory. The latest make distclean doesn't know about the old trace.[ch] files.

Stefan

author
#7 lore raw
In reply to Nigel Horne

** Changed in: qemu
Status: New => Invalid

Signature · 28 lines
You received this bug notification because you are a member of qemu-
devel-ml, which is subscribed to QEMU.
https://bugs.launchpad.net/bugs/1184616

Title:
   undefined reference to `trace_qemu_anon_ram_alloc'

Status in QEMU:
  Invalid

Bug description:
  The latest git version (commit
  6a4e17711442849bf2cc731ccddef5a2a2d92d29) fails to compile:

  ...
    LINK  qemu-ga
  libqemuutil.a(oslib-posix.o): In function `qemu_anon_ram_alloc':
  oslib-posix.c:(.text+0x154): undefined reference to `trace_qemu_anon_ram_alloc'
  libqemuutil.a(oslib-posix.o): In function `qemu_anon_ram_free':
  oslib-posix.c:(.text+0x1e7): undefined reference to `trace_qemu_anon_ram_free'
  collect2: error: ld returned 1 exit status
  make: *** [qemu-ga] Error 1

  This is on Ubuntu 13.04, gcc 4.7.3, configure flags: 
  './configure' '--enable-linux-aio' '--enable-kvm' '--enable-vhost-net'

To manage notifications about this bug go to:
https://bugs.launchpad.net/qemu/+bug/1184616/+subscriptions