Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 833620 - sys-libs/glibc-2.34-r8 fails to compile (stddef.h: No such file or directory)
Summary: sys-libs/glibc-2.34-r8 fails to compile (stddef.h: No such file or directory)
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: AMD64 Linux
: Normal normal (vote)
Assignee: Gentoo Toolchain Maintainers
URL:
Whiteboard: Need to add check in ebuild
Keywords:
Depends on:
Blocks: glibc-2.34
  Show dependency tree
 
Reported: 2022-02-18 19:34 UTC by Courier6
Modified: 2022-03-26 20:08 UTC (History)
1 user (show)

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


Attachments
build.log (file_833620.txt,83.41 KB, text/plain)
2022-02-18 19:34 UTC, Courier6
Details
emerge log since the 18th of january (emerge.log,231.40 KB, text/x-log)
2022-02-23 00:59 UTC, Courier6
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Courier6 2022-02-18 19:34:00 UTC
Created attachment 765401 [details]
build.log

When issuing an "emerge -av =sys-libs/glibc-2.34-r8", it completes the configure process, but it only make it half way into the compilation process where it errors out.
Emerge info: 
Portage 3.0.30 (python 3.9.10-final-0, default/linux/amd64/17.1/hardened, gcc-11.2.1, glibc-2.34-r7, 5.16.5-gentoo-x86_64 x86_64)
=================================================================
System uname: Linux-5.16.5-gentoo-x86_64-x86_64-Intel-R-_Core-TM-_i5-8500_CPU_@_3.00GHz-with-glibc2.34
KiB Mem:    16153652 total,  10018764 free
KiB Swap:          0 total,         0 free
Timestamp of repository gentoo: Fri, 18 Feb 2022 18:00:01 +0000
Head commit of repository gentoo: 83f421d8ed39fc11f4ca87f95a8d707bac656f9c
Head commit of repository librewolf: fbb73af7e9f63b6552e6f92d71c01f6b222602a9

Head commit of repository steam-overlay: f2c2eaf447183fd98ea6e6abe11b75590aae5866

sh bash 5.1_p16
ld GNU ld (Gentoo 2.37_p1 p2) 2.37
app-misc/pax-utils:        1.3.3::gentoo
app-shells/bash:           5.1_p16::gentoo
dev-java/java-config:      2.3.1::gentoo
dev-lang/perl:             5.34.0-r6::gentoo
dev-lang/python:           3.9.10-r1::gentoo, 3.10.2-r1::gentoo
dev-lang/rust-bin:         1.58.1::gentoo
dev-util/cmake:            3.22.2::gentoo
dev-util/meson:            0.60.3::gentoo
sys-apps/baselayout:       2.8::gentoo
sys-apps/openrc:           0.44.10::gentoo
sys-apps/sandbox:          2.29::gentoo
sys-devel/autoconf:        2.13-r1::gentoo, 2.71-r1::gentoo
sys-devel/automake:        1.16.5::gentoo
sys-devel/binutils:        2.37_p1-r2::gentoo
sys-devel/binutils-config: 5.4::gentoo
sys-devel/clang:           13.0.1::gentoo
sys-devel/gcc:             11.2.1_p20220115::gentoo
sys-devel/gcc-config:      2.5-r1::gentoo
sys-devel/libtool:         2.4.6-r6::gentoo
sys-devel/lld:             13.0.1::gentoo
sys-devel/llvm:            13.0.1::gentoo
sys-devel/make:            4.3::gentoo
sys-kernel/linux-headers:  5.16::gentoo (virtual/os-headers)
sys-libs/glibc:            2.34-r7::gentoo

ACCEPT_KEYWORDS="amd64 ~amd64"
ACCEPT_LICENSE="@FREE @FREE @GPL-COMPATIBLE @BINARY-REDISTRIBUTABLE @EULA"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-march=native -O2 -pipe -mstackrealign"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /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/revdep-rebuild /etc/sandbox.d /etc/terminfo"
CXXFLAGS="-march=native -O2 -pipe -mstackrealign"
DISTDIR="/var/cache/distfiles"
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="-march=native -O2 -pipe"
FEATURES="assume-digests binpkg-docompress binpkg-dostrip binpkg-logs buildpkg-live config-protect-if-modified distlocks ebuild-locks fixlafiles ipc-sandbox merge-sync 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="-march=native -O2 -pipe"

LANG="en_US.utf8"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
PKGDIR="/var/cache/binpkgs"
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"
SHELL="/bin/bash"
USE="acl alsa amd64 amdgpu bluray bzip2 cdr cli crypt dvd elogind gtk hardened iconv intel ipv6 jpeg libglvnd libmpv libtirpc mount multilib ncurses nptl openmp pam pcre pie pipewire-alsa readline seccomp split-usr ssl ssp themes truetype unicode usbredir vulkan x x264 x265 xattr xinerama xtpax zlib" ABI_X86="64" ADA_TARGET="gnat_2020" 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 avx avx2 f16c fma3 mmx mmxext pclmul popcnt rdrand 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" GRUB_PLATFORMS="efi-64" INPUT_DEVICES="libinput joystick" 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-4 php8-0" POSTGRES_TARGETS="postgres12 postgres13" PYTHON_SINGLE_TARGET="python3_9" PYTHON_TARGETS="python3_9" QEMU_SOFTMMU_TARGETS="arm x86_64 sparc i386 x86 m68k ppc ppc64" QEMU_USER_TARGETS="x86_64" RUBY_TARGETS="ruby26 ruby27" USERLAND="GNU" VIDEO_CARDS="amdgpu radeonsi" 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:  ADDR2LINE, AR, ARFLAGS, AS, ASFLAGS, CC, CCLD, CONFIG_SHELL, CPP, CPPFLAGS, CTARGET, CXX, CXXFILT, ELFEDIT, EMERGE_DEFAULT_OPTS, EXTRA_ECONF, F77FLAGS, FC, GCOV, GPROF, INSTALL_MASK, LC_ALL, LD, LEX, LFLAGS, LIBTOOL, LINGUAS, MAKE, MAKEFLAGS, MAKEOPTS, NM, OBJCOPY, OBJDUMP, PORTAGE_BINHOST, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, RANLIB, READELF, RUSTFLAGS, SIZE, STRINGS, STRIP, YACC, YFLAGS
Comment 1 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2022-02-18 19:38:22 UTC
Snippet:

x86_64-pc-linux-gnu-nptl/cpu-features-offsets.h'" \
	  ../sysdeps/x86/cpu-features-offsets.sym > /var/tmp/portage/sys-libs/glibc-2.34-r8/work/build-x86-x86_64-pc-linux-gnu-nptl/cpu-features-offsets.hT
/bin/sh ../scripts/move-if-change /var/tmp/portage/sys-libs/glibc-2.34-r8/work/build-x86-x86_64-pc-linux-gnu-nptl/gnu/lib-names-32.T /var/tmp/portage/sys-libs/glibc-2.34-r8/work/build-x86-x86_64-pc-linux-gnu-nptl/gnu/lib-names-32.h
touch /var/tmp/portage/sys-libs/glibc-2.34-r8/work/build-x86-x86_64-pc-linux-gnu-nptl/gnu/lib-names-32.stmp
if test -r /var/tmp/portage/sys-libs/glibc-2.34-r8/work/build-x86-x86_64-pc-linux-gnu-nptl/csu/abi-tag.h.new; then mv -f /var/tmp/portage/sys-libs/glibc-2.34-r8/work/build-x86-x86_64-pc-linux-gnu-nptl/csu/abi-tag.h.new /var/tmp/portage/sys-libs/glibc-2.34-r8/work/build-x86-x86_64-pc-linux-gnu-nptl/csu/abi-tag.h; \
else echo >&2 'This configuration not matched in ../abi-tags'; exit 1; fi
[01m[K<stdin>:1:10:[m[K [01;31m[Kfatal error: [m[Kstddef.h: No such file or directory
compilation terminated.
Traceback (most recent call last):
  File "/var/tmp/portage/sys-libs/glibc-2.34-r8/work/glibc-2.34/csu/../scripts/gen-as-const.py", line 120, in <module>
    main()
  File "/var/tmp/portage/sys-libs/glibc-2.34-r8/work/glibc-2.34/csu/../scripts/gen-as-const.py", line 116, in main
    consts = glibcextract.compute_c_consts(sym_data, args.cc)
  File "/var/tmp/portage/sys-libs/glibc-2.34-r8/work/glibc-2.34/scripts/glibcextract.py", line 62, in compute_c_consts
    subprocess.check_call(cmd, shell=True)
  File "/usr/lib/python3.9/subprocess.py", line 373, in check_call
    raise CalledProcessError(retcode, cmd)
Comment 2 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2022-02-18 20:32:34 UTC
Thanks for reporting this. It looks like it's an issue in the GCC 11 snapshot (something got backported to the stable branch upstream) but it might/is actually a glibc bug.

Please hold while we look into it.
Comment 3 Courier6 2022-02-18 21:34:13 UTC
(In reply to Sam James from comment #2)
> Thanks for reporting this. It looks like it's an issue in the GCC 11
> snapshot (something got backported to the stable branch upstream) but it
> might/is actually a glibc bug.
> 
> Please hold while we look into it.

You are very welcome, I can't thank you enough for looking into this!
Comment 4 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2022-02-22 03:47:00 UTC
Could you tar up /var/tmp/portage/sys-libs/glibc-2.34-r8/work and upload it compressed here?
Comment 5 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2022-02-22 03:55:39 UTC
(In reply to Sam James from comment #4)
> Could you tar up /var/tmp/portage/sys-libs/glibc-2.34-r8/work and upload it
> compressed here?

I wonder if you have a /usr/lib/include or /usr/lib64/include. If not, we'll need to do some digging like in bug 643302.

Did anything change on your system recently? Obvious example would be 17.0->17.1 profile migration. The interesting part is you managed to install glibc-2.34-r7.

Could you share 'qlop' output or /var/log/emerge.log, to see what you installed _after_ glibc-2.34-r7 up until now? I'm really interested in what's changed.
Comment 6 Courier6 2022-02-23 00:59:10 UTC
Created attachment 765691 [details]
emerge log since the 18th of january

(In reply to Sam James from comment #4)
> Could you tar up /var/tmp/portage/sys-libs/glibc-2.34-r8/work and upload it
> compressed here?

sure thing! I just got home from work, also here is the emerge.log file of everything I did since installing sys-libs/glibc-2.34-r7. I checked to see if I have /usr/lib/include and /usr/lib64/include and both directories were not present so that is quite odd. 

link to working directory of sys-libs/glibc-2.34-r8
https://www.sharebylink.fr/?C5cXyekkdsjM
Comment 7 Courier6 2022-02-23 01:12:48 UTC
do not use the sharebylink url, use this instead
link that works: https://drive.google.com/file/d/1JHKuzA4kfjg7z3JsDnVYmRZYSnCjquuv/view?usp=sharing
Comment 8 Courier6 2022-02-23 01:30:45 UTC
(In reply to Sam James from comment #5)
Nothing really major changed on my system software or hardware wise, and I am perplexed on out I got 2.34-r7 installed, as it just came in when I did an "emerge -j5 --ask --update --deep --with-bdeps=y --newuse @world" command as a routine update. Also I had misread the /usr/lib directory to find that it has an "include" directory, while the /usr/lib64 directory does not contain the "include" directory. I'm very sorry to waste your time.
Comment 9 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2022-02-23 01:37:27 UTC
(In reply to Courier6 from comment #8)
> (In reply to Sam James from comment #5)
> Nothing really major changed on my system software or hardware wise, and I
> am perplexed on out I got 2.34-r7 installed, as it just came in when I did
> an "emerge -j5 --ask --update --deep --with-bdeps=y --newuse @world" command
> as a routine update. Also I had misread the /usr/lib directory to find that
> it has an "include" directory, while the /usr/lib64 directory does not
> contain the "include" directory. I'm very sorry to waste your time.

Could you do: ls /usr/lib/include? Then mv /usr/lib/include /usr/lib/include.bak/ and try emerge -v1 glibc again?

Also, could you try attach all these files, rather than use external services? Sometimes we can't reach them due to firewalls and we also want to keep them here for posterity.

Thanks in advance!
Comment 10 Courier6 2022-02-23 01:51:51 UTC
(In reply to Sam James from comment #9)

I tried using the "mv /usr/lib/include /usr/lib/include.bak" command, and then I tried updating glibc, and what do you know, it worked! I now have the latest version of glibc! also I tried attaching the working directory of 2.34-r8 but I couldn't compress it to be below 1000kb as the original directory was 224mb, but I totally understand keeping the files here for posterity sake and firewalls being a thing. thank you so much for your help
Comment 11 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2022-02-27 06:17:07 UTC
(In reply to Courier6 from comment #10)
> (In reply to Sam James from comment #9)
> 
> I tried using the "mv /usr/lib/include /usr/lib/include.bak" command, and
> then I tried updating glibc, and what do you know, it worked! I now have the
> latest version of glibc! also I tried attaching the working directory of
> 2.34-r8 but I couldn't compress it to be below 1000kb as the original
> directory was 224mb, but I totally understand keeping the files here for
> posterity sake and firewalls being a thing. thank you so much for your help

No problem. I think we'll add some check in pkg_pretend or similar and warn at least. Cheers!
Comment 12 Larry the Git Cow gentoo-dev 2022-03-20 21:14:06 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=b522ecb1078aad753b3970d91699053974440e2f

commit b522ecb1078aad753b3970d91699053974440e2f
Author:     Sam James <sam@gentoo.org>
AuthorDate: 2022-03-20 21:13:16 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2022-03-20 21:13:16 +0000

    sys-libs/glibc: add safety check for /usr/lib/include
    
    This directory isn't used by anything legitimate but
    it breaks the build in a confusing way.
    
    Add a check for it & bail out if it exists.
    
    If you do have this directory on your system,
    back up its contents, then move it away/delete it.
    
    Closes: https://bugs.gentoo.org/643302
    Closes: https://bugs.gentoo.org/833620
    Signed-off-by: Sam James <sam@gentoo.org>

 sys-libs/glibc/glibc-2.34-r10.ebuild | 8 ++++++++
 sys-libs/glibc/glibc-2.35.ebuild     | 8 ++++++++
 sys-libs/glibc/glibc-9999.ebuild     | 8 ++++++++
 3 files changed, 24 insertions(+)