qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [Bug 1257099] [NEW] QEMU fails to build on CentOS 5.10


From: Don Slutz
Subject: Re: [Qemu-devel] [Bug 1257099] [NEW] QEMU fails to build on CentOS 5.10 with relocation R_X86_64_PC32 error
Date: Wed, 04 Dec 2013 01:32:40 -0000

On 12/03/13 12:15, Paolo Bonzini wrote:
> Il 03/12/2013 14:25, Stefano Stabellini ha scritto:
>> CC'ing Paolo and xen-devel.
>> The original thread is here:
>>
>> http://marc.info/?l=xen-devel&m=135718999710640
>>
>> On Mon, 2 Dec 2013, Don Slutz wrote:
>>> Public bug reported:
>>>
>>>    lt LINK libcacard.la
>>> /usr/bin/ld: libcacard/.libs/vcard.o: relocation R_X86_64_PC32 against 
>>> `vcard_buffer_response_delete' can not be used when making a shared object; 
>>> recompile with -fPIC
>>> /usr/bin/ld: final link failed: Bad value
>>> collect2: ld returned 1 exit status
>>> make[4]: *** [libcacard.la] Error 1
>>> make[3]: *** [subdir-libcacard] Error 2
> This is a bug in RHEL5 binutils.  Configure with --disable-pie to work
> around it.
Any hints or pointers about the bug in RHEL5 binutils?  I can try and 
make a patch to auto detect this.

That still fails for (7dc65c0 (HEAD, origin/master, origin/HEAD, master) 
Open 2.0 development tree):

...
libtool  --mode=link --tag=CC cc -m64 -D_GNU_SOURCE 
-D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -Wstrict-prototypes 
-Wredundant-decls -Wall -Wundef -Wwrite-strings -Wmissing-prototypes 
-fno-strict-aliasing  -Wendif-labels -Wmissing-include-dirs 
-Wnested-externs -Wformat-security -Wformat-y2k -Winit-self 
-Wold-style-definition -fstack-protector-all -I/usr/include/libpng12   
-I/usr/include/nss3 -I/usr/include/nspr4 -pthread 
-I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include 
-I/usr/include/pixman-1   -I/home/don/qemu/dtc/libfdt -pthread 
-I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include 
-I/home/don/qemu/tests -O2 -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=2 -g 
-Wl,--warn-common -m64 -g  -o vscclient libcacard/vscclient.o 
libcacard.la  -Wc,-fstack-protector-all -lrt -pthread -L/lib64 
-lgthread-2.0 -lglib-2.0    -lz -L/usr/kerberos/lib64 -lcurl -ldl 
-lgssapi_krb5 -lkrb5 -lk5crypto -lcom_err -lidn -lssl -lcrypto -lz -luuid
cc -m64 -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE 
-Wstrict-prototypes -Wredundant-decls -Wall -Wundef -Wwrite-strings 
-Wmissing-prototypes -fno-strict-aliasing -Wendif-labels 
-Wmissing-include-dirs -Wnested-externs -Wformat-security -Wformat-y2k 
-Winit-self -Wold-style-definition -fstack-protector-all 
-I/usr/include/libpng12 -I/usr/include/nss3 -I/usr/include/nspr4 
-pthread -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include 
-I/usr/include/pixman-1 -I/home/don/qemu/dtc/libfdt -pthread 
-I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include 
-I/home/don/qemu/tests -O2 -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=2 -g 
-Wl,--warn-common -m64 -g -o .libs/vscclient libcacard/vscclient.o 
-Wl,-fstack-protector-all -pthread  ./.libs/libcacard.so -L/lib64 
-L/usr/kerberos/lib64 -lssl3 -lsmime3 -lnss3 -lnssutil3 -lplds4 -lplc4 
-lnspr4 -lpthread -lrt -lgthread-2.0 -lglib-2.0 -lcurl -ldl 
-lgssapi_krb5 -lkrb5 -lk5crypto -lcom_err -lidn -lssl -lcrypto -lz 
-luuid  -Wl,--rpath -Wl,/usr/local/lib
/usr/bin/ld: -f may not be used without -shared
collect2: ld returned 1 exit status
make: *** [vscclient] Error 1

Attached is the full "make V=1" output.

Here is the configure output:

dcs-xen-53:~/qemu>rm -rf out/tmp;mkdir out/tmp;pushd 
out/tmp;../../configure --disable-pie;make V=1 1>zz1 2>&1;popd
~/qemu/out/tmp ~/qemu
Install prefix    /usr/local
BIOS directory    /usr/local/share/qemu
binary directory  /usr/local/bin
library directory /usr/local/lib
libexec directory /usr/local/libexec
include directory /usr/local/include
config directory  /usr/local/etc
local state directory   /usr/local/var
Manual directory  /usr/local/share/man
ELF interp prefix /usr/gnemul/qemu-%M
Source path       /home/don/qemu
C compiler        cc
Host C compiler   cc
C++ compiler      c++
Objective-C compiler cc
ARFLAGS           rv
CFLAGS            -O2 -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=2 -g
QEMU_CFLAGS       -m64 -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 
-D_LARGEFILE_SOURCE -Wstrict-prototypes -Wredundant-decls -Wall -Wundef 
-Wwrite-strings -Wmissing-prototypes -fno-strict-aliasing -Wendif-labels 
-Wmissing-include-dirs -Wnested-externs -Wformat-security -Wformat-y2k 
-Winit-self -Wold-style-definition -fstack-protector-all   
-I/usr/include/libpng12 -I/usr/include/nss3 -I/usr/include/nspr4   
-pthread -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include 
-I/usr/include/pixman-1   -I$(SRC_PATH)/dtc/libfdt
LDFLAGS           -Wl,--warn-common -m64 -g
make              make
install           install
python            python
smbd              /usr/sbin/smbd
host CPU          x86_64
host big endian   no
target list        alpha-softmmu arm-softmmu cris-softmmu i386-softmmu 
lm32-softmmu m68k-softmmu microblaze-softmmu microblazeel-softmmu 
mips-softmmu mips64-softmmu mips64el-softmmu mipsel-softmmu 
moxie-softmmu or32-softmmu ppc-softmmu ppc64-softmmu ppcemb-softmmu 
s390x-softmmu sh4-softmmu sh4eb-softmmu sparc-softmmu sparc64-softmmu 
unicore32-softmmu x86_64-softmmu xtensa-softmmu xtensaeb-softmmu 
alpha-linux-user arm-linux-user armeb-linux-user cris-linux-user 
i386-linux-user m68k-linux-user microblaze-linux-user 
microblazeel-linux-user mips-linux-user mips64-linux-user 
mips64el-linux-user mipsel-linux-user mipsn32-linux-user 
mipsn32el-linux-user or32-linux-user ppc-linux-user ppc64-linux-user 
ppc64abi32-linux-user s390x-linux-user sh4-linux-user sh4eb-linux-user 
sparc-linux-user sparc32plus-linux-user sparc64-linux-user 
unicore32-linux-user x86_64-linux-user
tcg debug enabled no
gprof enabled     no
sparse enabled    no
strip binaries    yes
profiler          no
static build      no
-Werror enabled   no
pixman            system
SDL support       yes
GTK support       no
curses support    yes
curl support      yes
mingw32 support   no
Audio drivers     oss
Block whitelist (rw)
Block whitelist (ro)
VirtFS support    yes
VNC support       yes
VNC TLS support   no
VNC SASL support  yes
VNC JPEG support  yes
VNC PNG support   yes
VNC WS support    no
xen support       yes
brlapi support    no
bluez  support    no
Documentation     yes
GUEST_BASE        yes
PIE               no
vde support       no
Linux AIO support no
ATTR/XATTR support yes
Install blobs     yes
KVM support       yes
RDMA support      no
TCG interpreter   no
fdt support       yes
preadv support    no
fdatasync         yes
madvise           yes
posix_madvise     yes
sigev_thread_id   yes
uuid support      yes
libcap-ng support no
vhost-net support yes
vhost-scsi support yes
Trace backend     nop
Trace output file trace-<pid>
spice support     no (/)
rbd support       no
xfsctl support    no
nss used          yes
libusb            no
usb net redir     no
GLX support       yes
libiscsi support  no
build guest agent yes
QGA VSS support   no
seccomp support   no
coroutine backend ucontext
coroutine pool    yes
GlusterFS support no
virtio-blk-data-plane no
gcov              gcov
gcov enabled      no
TPM support       no
libssh2 support   no
TPM passthrough   no
QOM debugging     yes
vhdx              yes

I bisect'd this to:

dcs-xen-53:~/qemu>git-bisect good
37746c5eacf309fa019ea0fa45f776c36c561457 is the first bad commit
commit 37746c5eacf309fa019ea0fa45f776c36c561457
Author: Marc-André Lureau <address@hidden>
Date:   Mon Feb 25 23:31:12 2013 +0100

     build-sys: must link with -fstack-protector

     It is needed to give that flag to the linker as well, but latest
     libtool 2.4.2 still swallows that argument, so let's pass it with
     libtool -Wc argument.

     qemu-1.4.0/stubs/arch-query-cpu-def.c:6: undefined reference to 
`__stack_chk_guard'

     Signed-off-by: Marc-André Lureau <address@hidden>
     Reviewed-by: Alon Levy <address@hidden>

:100755 100755 33d3354ea30838694020660f5822f551293d7e9a 
ee2e7e8ad9b8a23af96e4e404e3f7658efcbe74b M      configure
:100644 100644 edc2552f0886c99608b97f85bd932460fa50da73 
36aba2de1fa9e0f8acde7640818e94a28dd03c80 M      rules.mak

Do you want a bug opened for this?

    -Don Slutz

> Paolo


** Attachment added: "zz1"
   https://bugs.launchpad.net/bugs/1257099/+attachment/3922629/+files/zz1

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

Title:
  QEMU fails to build on CentOS 5.10 with relocation R_X86_64_PC32 error

Status in QEMU:
  New

Bug description:
    lt LINK libcacard.la
  /usr/bin/ld: libcacard/.libs/vcard.o: relocation R_X86_64_PC32 against 
`vcard_buffer_response_delete' can not be used when making a shared object; 
recompile with -fPIC
  /usr/bin/ld: final link failed: Bad value
  collect2: ld returned 1 exit status
  make[4]: *** [libcacard.la] Error 1
  make[3]: *** [subdir-libcacard] Error 2

  I have bisect'd this to:

  dcs-xen-53:~/qemu>git-bisect next
  00c705fb92bc6e69e955aeac3614e05ca02feacd is the first bad commit
  commit 00c705fb92bc6e69e955aeac3614e05ca02feacd
  Author: Paolo Bonzini <address@hidden>
  Date:   Tue May 29 11:40:24 2012 +0200

      build: libcacard Makefile cleanups
      
      Build vscclient from toplevel Makefile, limit usage of vpath.
      
      Signed-off-by: Paolo Bonzini <address@hidden>

  :100644 100644 a10005a22fe44a107dfec15106960612b43be71f 
1d34b9539e9ba47fdb7028ad0569389fa48712b9 M      Makefile
  :100644 100644 ae3770a5f718742838844f9064be6a7153ac7469 
74110dda7e38b8ddae47a53ad4cb6ecf48231fa0 M      Makefile.objs
  :100644 100644 3dfdf925fdc2c92239b7053a3d4e09687dcc2171 
555894db4aa717f15cfc24093d838131f422fc78 M      Makefile.target
  :100755 100755 e50ad0bb8fc2e331562f3c09e605af6597a143b1 
cd5e8b349c137f621d2e9dc516145bc650d977c0 M      configure
  :040000 040000 160d565b7e551c3248333c9e49f34edb7a30f5e0 
008bc3fccda52f78accf9494539ba62bfb1621a0 M      libcacard

  dcs-xen-53:~/qemu>git bisect log   
  git bisect start
  # bad: [7457fe9541b5162f285454947448d553a5d5a531] Update version for 
v1.7.0-rc2 release
  git bisect bad 7457fe9541b5162f285454947448d553a5d5a531
  # good: [ed7ec8400707fe42f4a0f40db2f2d5827ecea789] Merge remote-tracking 
branch 'bonzini/scsi.2' into staging
  git bisect good ed7ec8400707fe42f4a0f40db2f2d5827ecea789
  # bad: [1d31fca470648ec66afd8743491bfb5846306341] qemu-barrier: Fix 
compilation on i386 hosts
  git bisect bad 1d31fca470648ec66afd8743491bfb5846306341
  # good: [9de36b1a7cf61aa8be365f13c81668b3e19fbc7f] Make -machine/-enable-kvm 
options merge into a single list
  git bisect good 9de36b1a7cf61aa8be365f13c81668b3e19fbc7f
  # bad: [3edb8f92e8b5f18797693d8ed9fad3962e11e25d] target-s390x: Pass S390CPU 
to s390_cpu_restart()
  git bisect bad 3edb8f92e8b5f18797693d8ed9fad3962e11e25d
  # good: [aecff6924dab0197b6c8f132e44502b25fd98a38] hw/arm_gic: Make gic_reset 
a sysbus reset function
  git bisect good aecff6924dab0197b6c8f132e44502b25fd98a38
  # good: [b9531b6eed93c9e1769d6f371c4da5d1f955e0d1] block/qcow2: Add missing 
GCC_FMT_ATTR to function report_unsupported()
  git bisect good b9531b6eed93c9e1769d6f371c4da5d1f955e0d1
  # good: [dd86df756e02b684718dd5378725927361b0ad36] Merge remote-tracking 
branch 'sstabellini/for_1.1_rc3' into staging
  git bisect good dd86df756e02b684718dd5378725927361b0ad36
  # good: [8ebdf9dcc6036171a9f8bac3fe8dc459725a3e83] sun4u: Use 
cpu_sparc_init() to obtain SPARCCPU
  git bisect good 8ebdf9dcc6036171a9f8bac3fe8dc459725a3e83
  # good: [8867aef02e1e5817c72b2e09be4ae952eb0c9d9d] build: move ui/ objects to 
nested Makefile.objs
  git bisect good 8867aef02e1e5817c72b2e09be4ae952eb0c9d9d
  # bad: [e8de1ea849176812765bf30514f66c5450a1edc6] target-xtensa: add 
attributes to helper functions
  git bisect bad e8de1ea849176812765bf30514f66c5450a1edc6
  # bad: [fa79c914efd35cb60e0bc18512c03690c48b13e2] Merge remote-tracking 
branch 'bonzini/nested-makefiles-3' into staging
  git bisect bad fa79c914efd35cb60e0bc18512c03690c48b13e2
  # good: [c353f261946ddbd814b333ae2440712b486977fd] build: move per-target hw/ 
objects to nested Makefile.objs
  git bisect good c353f261946ddbd814b333ae2440712b486977fd
  # bad: [25f27a4f7160d077d6992e811021b4bc3a82abc1] build: compile oslib-obj-y 
once
  git bisect bad 25f27a4f7160d077d6992e811021b4bc3a82abc1
  # bad: [00c705fb92bc6e69e955aeac3614e05ca02feacd] build: libcacard Makefile 
cleanups
  git bisect bad 00c705fb92bc6e69e955aeac3614e05ca02feacd
  # good: [49ac9e0a8cfb737d6da9c0b056c062e3dec0ba45] build: move device tree to 
per-target Makefile.objs
  git bisect good 49ac9e0a8cfb737d6da9c0b056c062e3dec0ba45

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



reply via email to

[Prev in Thread] Current Thread [Next in Thread]