public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c/111925] New: fail to build qemu when compile with lto
@ 2023-10-23  2:43 yancheng.li at foxmail dot com
  2023-10-23  8:01 ` [Bug middle-end/111925] " yancheng.li at foxmail dot com
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: yancheng.li at foxmail dot com @ 2023-10-23  2:43 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111925

            Bug ID: 111925
           Summary: fail to build qemu when compile with lto
           Product: gcc
           Version: 10.3.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c
          Assignee: unassigned at gcc dot gnu.org
          Reporter: yancheng.li at foxmail dot com
  Target Milestone: ---

This is happening when attempting to build qemu-6.2.0 with configuration
--enable-lto:

$ ./configure --prefix=/usr '--target-list=aarch64-softmmu x86_64-softmmu
arm-softmmu riscv32-softmmu riscv64-softmmu' '--extra-cflags=-O2 -g -pipe -Wall
-Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS
-fstack-protector-strong -grecord-gcc-switches
-specs=/usr/lib/rpm/generic-hardened-cc1 -fasynchronous-unwind-tables
-fstack-clash-protection -fPIE -DPIE -fPIC -ftls-model=initial-exec'
'--extra-ldflags=-Wl,--build-id -Wl,-z,relro -Wl,-z,now -Wl,-z,noexecstack'
--datadir=/usr/share --docdir=/usr/share/doc/ --libdir=/usr/lib64
--libexecdir=/usr/libexec --localstatedir=/var --sysconfdir=/etc
--interp-prefix=/usr/qemu-%M --firmwarepath=/usr/share/qemu
--with-pkgversion=qemu-6.2.0-80.oe1 --python=/usr/bin/python3
--enable-slirp=system --enable-slirp-smbd --enable-gtk --enable-docs
--enable-guest-agent --enable-pie --enable-numa --enable-mpath --disable-libnfs
--disable-bzip2 --enable-kvm --enable-tcg --enable-rdma --enable-linux-aio
--enable-linux-io-uring --enable-cap-ng --enable-vhost-user --enable-vhost-net
--enable-vhost-kernel --enable-vhost-user-blk-server --enable-vhost-vdpa
--enable-vhost-vsock --enable-tpm --enable-modules --enable-libssh --enable-fdt
--enable-virglrenderer --enable-cap-ng --enable-libusb --enable-rbd
--disable-dmg --disable-qcow1 --disable-vdi --disable-vvfat --disable-qed
--disable-parallels --disable-capstone --disable-smartcard --enable-zstd
--disable-brlapi --disable-plugins --enable-debug --enable-lto

...
[181/2222] Linking target fsdev/virtfs-proxy-helper
FAILED: fsdev/virtfs-proxy-helper
cc  -o fsdev/virtfs-proxy-helper
fsdev/virtfs-proxy-helper.p/virtfs-proxy-helper.c.o
fsdev/virtfs-proxy-helper.p/9p-marshal.c.o
fsdev/virtfs-proxy-helper.p/9p-iov-marshal.c.o -Wl,--as-needed
-Wl,--no-undefined -pie -Wl,--warn-common -Wl,-z,relro -Wl,-z,now
-fstack-protector-strong -O2 -g -pipe -Wall -Werror=format-security
-Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -fstack-protector-strong
-grecord-gcc-switches -specs=/usr/lib/rpm/generic-hardened-cc1
-fasynchronous-unwind-tables -fstack-clash-protection -fPIE -DPIE -fPIC
-ftls-model=initial-exec -flto=96 -Wl,--build-id -Wl,-z,relro -Wl,-z,now
-Wl,-z,noexecstack -flto=96 -Wl,--start-group libqemuutil.a
subprojects/libvhost-user/libvhost-user-glib.a
subprojects/libvhost-user/libvhost-user.a -lcap-ng /usr/lib64/liburing.so
-lutil -lgio-2.0 -lgobject-2.0 -lglib-2.0 -lgio-2.0 -lgobject-2.0 -lglib-2.0
-Wl,--export-dynamic -pthread -lgmodule-2.0 -lglib-2.0 -lglib-2.0
/usr/lib64/libgnutls.so -lm /usr/lib64/libpixman-1.so -lgmodule-2.0 -lglib-2.0
-lglib-2.0 -Wl,--end-group
/usr/bin/ld: /tmp/virtfs-proxy-helper.wCXTDh.ltrans0.ltrans.o: in function
`open_regular':
/home/lyc/rpmbuild/BUILD/qemu-6.2.0/hw/9pfs/9p-util.h:53: undefined reference
to `error_report_once_cond'

What happened to LTO?

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [Bug middle-end/111925] fail to build qemu when compile with lto
  2023-10-23  2:43 [Bug c/111925] New: fail to build qemu when compile with lto yancheng.li at foxmail dot com
@ 2023-10-23  8:01 ` yancheng.li at foxmail dot com
  2023-10-23  9:33 ` rguenth at gcc dot gnu.org
  2023-11-30 12:32 ` yancheng.li at foxmail dot com
  2 siblings, 0 replies; 4+ messages in thread
From: yancheng.li at foxmail dot com @ 2023-10-23  8:01 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111925

--- Comment #1 from yancheng.li at foxmail dot com ---
found discussion from openSUSE:
https://bugzilla.opensuse.org/show_bug.cgi?id=1133281

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [Bug middle-end/111925] fail to build qemu when compile with lto
  2023-10-23  2:43 [Bug c/111925] New: fail to build qemu when compile with lto yancheng.li at foxmail dot com
  2023-10-23  8:01 ` [Bug middle-end/111925] " yancheng.li at foxmail dot com
@ 2023-10-23  9:33 ` rguenth at gcc dot gnu.org
  2023-11-30 12:32 ` yancheng.li at foxmail dot com
  2 siblings, 0 replies; 4+ messages in thread
From: rguenth at gcc dot gnu.org @ 2023-10-23  9:33 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111925

Richard Biener <rguenth at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |WAITING
     Ever confirmed|0                           |1
   Last reconfirmed|                            |2023-10-23

--- Comment #2 from Richard Biener <rguenth at gcc dot gnu.org> ---
Note GCC 10 is no longer maintained, I suggest to update to a newer version
first.

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [Bug middle-end/111925] fail to build qemu when compile with lto
  2023-10-23  2:43 [Bug c/111925] New: fail to build qemu when compile with lto yancheng.li at foxmail dot com
  2023-10-23  8:01 ` [Bug middle-end/111925] " yancheng.li at foxmail dot com
  2023-10-23  9:33 ` rguenth at gcc dot gnu.org
@ 2023-11-30 12:32 ` yancheng.li at foxmail dot com
  2 siblings, 0 replies; 4+ messages in thread
From: yancheng.li at foxmail dot com @ 2023-11-30 12:32 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111925

yancheng.li at foxmail dot com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|WAITING                     |RESOLVED
         Resolution|---                         |FIXED

--- Comment #3 from yancheng.li at foxmail dot com ---
using gcc-ar and gcc-ranlib instead of ar/ranlib could solve this problem.

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2023-11-30 12:32 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-10-23  2:43 [Bug c/111925] New: fail to build qemu when compile with lto yancheng.li at foxmail dot com
2023-10-23  8:01 ` [Bug middle-end/111925] " yancheng.li at foxmail dot com
2023-10-23  9:33 ` rguenth at gcc dot gnu.org
2023-11-30 12:32 ` yancheng.li at foxmail dot com

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).