Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 803338 - sys-apps/systemd-248.5: fails to compile with gcc -ftracer (error: '%s' directive argument is null [-Werror=format-overflow=])
Summary: sys-apps/systemd-248.5: fails to compile with gcc -ftracer (error: '%s' direc...
Status: RESOLVED UPSTREAM
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo systemd Team
URL: https://gcc.gnu.org/bugzilla/show_bug...
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2021-07-22 07:43 UTC by Christian Strahl
Modified: 2023-07-22 20:32 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
build.log (build.log,743.53 KB, text/plain)
2021-07-22 07:45 UTC, Christian Strahl
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Christian Strahl 2021-07-22 07:43:40 UTC
with gcc-9.3.0 emerge works fine, but with gcc-10.3.0 emerge fails with the following message:

In file included from /usr/include/stdio.h:866,
                 from ../systemd-stable-248.5/src/shared/condition.h:5,
                 from ../systemd-stable-248.5/src/core/unit.h:11,
                 from ../systemd-stable-248.5/src/core/automount.h:6,
                 from ../systemd-stable-248.5/src/core/automount.c:15:
In function 'fprintf',
    inlined from 'automount_dump' at ../systemd-stable-248.5/src/core/automount.c:313:9:
/usr/include/bits/stdio2.h:105:10: error: '%s' directive argument is null [-Werror=format-overflow=]
  105 |   return __fprintf_chk (__stream, __USE_FORTIFY_LEVEL - 1, __fmt,
      |          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  106 |    __va_arg_pack ());
      |    ~~~~~~~~~~~~~~~~~
../systemd-stable-248.5/src/core/automount.c: In function 'automount_dump':
../systemd-stable-248.5/src/core/automount.c:315:28: note: format string is defined here
  315 |                 "%sResult: %s\n"
      |                            ^~
cc1: some warnings being treated as errors


Reproducible: Always




$ emerge --info
Portage 3.0.20 (python 3.9.5-final-0, default/linux/amd64/17.1/desktop/gnome/systemd, gcc-10.3.0, glibc-2.33-r1, 5.10.49-gentoo-r1 x86_64)
=================================================================
System uname: Linux-5.10.49-gentoo-r1-x86_64-Intel-R-_Xeon-R-_CPU_E5-1650_v3_@_3.50GHz-with-glibc2.33
KiB Mem:    32799560 total,  21815172 free
KiB Swap:          0 total,         0 free
Timestamp of repository gentoo: Thu, 22 Jul 2021 07:06:32 +0000
Head commit of repository gentoo: a741990054d2717f4d3b9a00ba51852931ae5b58

sh bash 5.1_p8
ld GNU ld (Gentoo 2.35.2 p1) 2.35.2
app-shells/bash:          5.1_p8::gentoo
dev-java/java-config:     2.3.1::gentoo
dev-lang/perl:            5.34.0::gentoo
dev-lang/python:          3.9.5_p2::gentoo
dev-lang/rust:            1.52.1::gentoo
dev-util/cmake:           3.18.5::gentoo
dev-util/pkgconfig:       0.29.2::gentoo
sys-apps/baselayout:      2.7::gentoo
sys-apps/sandbox:         2.24::gentoo
sys-devel/autoconf:       2.13-r1::gentoo, 2.69-r5::gentoo
sys-devel/automake:       1.16.3-r1::gentoo
sys-devel/binutils:       2.35.2::gentoo
sys-devel/gcc:            9.3.0-r2::gentoo, 10.3.0-r2::gentoo
sys-devel/gcc-config:     2.4::gentoo
sys-devel/libtool:        2.4.6-r6::gentoo
sys-devel/make:           4.3::gentoo
sys-kernel/linux-headers: 5.10::gentoo (virtual/os-headers)
sys-libs/glibc:           2.33-r1::gentoo
Repositories:

gentoo
    location: /var/db/repos/gentoo
    sync-type: git
    sync-uri: https://github.com/gentoo-mirror/gentoo
    priority: -1000

local-repo
    location: /usr/local/local_gentoo_overlay
    masters: gentoo

ACCEPT_KEYWORDS="amd64"
ACCEPT_LICENSE="* -@EULA"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-march=native -O2 -pipe -fomit-frame-pointer -fweb -ftracer"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/lib64/libreoffice/program/sofficerc /usr/share/gnupg/qualified.txt"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/dconf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/php/apache2-php7.4/ext-active/ /etc/php/cgi-php7.4/ext-active/ /etc/php/cli-php7.4/ext-active/ /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo"
CXXFLAGS="-march=native -O2 -pipe -fomit-frame-pointer -fweb -ftracer"
DISTDIR="/usr/portage/distfiles"
EMERGE_DEFAULT_OPTS="--quiet-build=n --jobs 3"
ENV_UNSET="CARGO_HOME DBUS_SESSION_BUS_ADDRESS DISPLAY GOBIN GOPATH PERL5LIB PERL5OPT PERLPREFIX PERL_CORE PERL_MB_OPT PERL_MM_OPT XAUTHORITY XDG_CACHE_HOME XDG_CONFIG_HOME XDG_DATA_HOME XDG_RUNTIME_DIR"
FCFLAGS="-O2 -pipe"
FEATURES="assume-digests binpkg-docompress binpkg-dostrip binpkg-logs config-protect-if-modified distlocks ebuild-locks fixlafiles ipc-sandbox merge-sync metadata-transfer multilib-strict network-sandbox news parallel-fetch pid-sandbox preserve-libs protect-owned qa-unresolved-soname-deps sandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv usersandbox usersync xattr"
FFLAGS="-O2 -pipe"
GENTOO_MIRRORS="http://ftp.uni-erlangen.de/pub/mirrors/gentoo http://ftp.spline.inf.fu-berlin.de/mirrors/gentoo/"
LANG="de_DE.utf8"
LC_ALL="en_US.utf8"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
MAKEOPTS="-j13"
PKGDIR="/usr/portage/packages"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --omit-dir-times --compress --force --whole-file --delete --stats --human-readable --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages --exclude=/.git"
PORTAGE_TMPDIR="/var/tmp"
USE="3dnow 3dnowext 64bit 7zip X a52 aac acl acpi alsa amd64 apache2 apm apng applet aqua_theme asf async audio automount avahi bash-completion bonobo branding bzip2 c++ cairo calendar cdda cddb cdio cdr cdrom cgi cli colord consolekit crypt css ctype cups custom-optimization cvs cvsgraph dbus dhcp directfb divx divx4linux dpms dri dts dvb dvbplayer dvd dvdr emboss emerald emul-linux-x86 encode evo exif ext-png fat fbcon fbcondecor fbsplash ffmpeg flac flash fortran fpx ftp g3dvl gaim gdbm gecko gedit gif gimp git glade glitz gnome gnome-keyring gnome-online-accounts gnome-print gnomecanvas gnomedb gnutls gpm gps graphviz grub gs gsl gstreamer gtk gtkhtml gui gzip h323 hddtemp heif hfs icons iconv icq icu id3 imap inkjar introspection ipsec ipv6 java jfs jpeg jpeg2k kvm lame lcms libglvnd libnotify libsecret libtirpc libvisual live lm_sensors logitech-mouse mad math matroska ming mmxext mng mod moonlight mouse mozbranding mozilla moznopango mp2 mp3 mp4 mp4live mpd-mad mpe mpeg mpeg2 mpeg4 mplayer mplayer-bin multilib musepack mysql nautilus ncurses net networkmanager nfs nfsidmap nfsv4 nfsv41 nls no-seamonkey nptl nsplugin ntfs nvidia ogg openal opengl openmp opus pam pango pcap pcapnav pcre pdf plotutils png policykit postscript ppds pulseaudio python qt5 rar readline real samba sblive scanner screencast sdl seccomp sensord sftp simplexml skins slang smp spell split-usr sql sqlite sse-filters ssl startup-notification stream svg svgz sysprof systemd tcpd themes theora thesaurus threads thunderbird tidy tiff totem transcode truetype tv_check type1 udev udisks unicode upower usb userlocales utf8 vcd vdpau vdr vfat video vim vim-syntax vorbis wav wayland webdav winbind wireshark wma wmf wxwidgets x264 xattr xcb xfs xine xinerama xml xmldoclet xmlreader xmlwriter xpm xprint xscreensaver xsettings xsl xslt xulrunner xv xvid zeroconf zip zlib" ABI_X86="64 32" ADA_TARGET="gnat_2018" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m maestro3 trident usb-audio via82xx via82xx-modem ymfpci" APACHE2_MODULES="authn_core authz_core socache_shmcb unixd actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" CALLIGRA_FEATURES="karbon sheets words" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" CPU_FLAGS_X86="aes mmx mmxext popcnt sse sse2 sse3 sse4_1 sse4_2 ssse3" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock greis isync itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf skytraq superstar2 timing tsip tripmate tnt ublox ubx" INPUT_DEVICES="evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" LUA_SINGLE_TARGET="lua5-1" LUA_TARGETS="lua5-1" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php7-3 php7-4" POSTGRES_TARGETS="postgres10 postgres11" PYTHON_SINGLE_TARGET="python3_9" PYTHON_TARGETS="python3_9" QEMU_SOFTMMU_TARGETS="arm i386 x86_64" QEMU_USER_TARGETS="arm i386 x86_64" RUBY_TARGETS="ruby26" USERLAND="GNU" VIDEO_CARDS="nvidia nv" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq proto steal rawnat logmark ipmark dhcpmac delude chaos account"
Unset:  CC, CPPFLAGS, CTARGET, CXX, INSTALL_MASK, LINGUAS, PORTAGE_BINHOST, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, RUSTFLAGS
Comment 1 Christian Strahl 2021-07-22 07:45:22 UTC
Created attachment 725647 [details]
build.log

systemd-248.5 build.log
Comment 2 Christian Strahl 2021-08-10 22:09:54 UTC
same with sys-apps/systemd-248.6

Any updates?
Comment 3 Christian Strahl 2021-09-06 11:04:34 UTC
same with sys-apps/systemd-249.2

Any updates?
Comment 4 Mike Gilbert gentoo-dev 2021-09-06 13:40:59 UTC
This looks like bug 810937, which we narrowed down to the -ftracer compiler flag.

If you want to see a fix for this, you'll probably need to work with the gcc and systemd developers upstream.
Comment 5 Mike Gilbert gentoo-dev 2023-07-22 20:32:34 UTC
Please work with upstream on this.