Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 806433 - Prefix bootstrap failure due to gcc stage2 and stage3 bootstrap comparison failure on Mac Os 11.4 with Xcode 12.5
Summary: Prefix bootstrap failure due to gcc stage2 and stage3 bootstrap comparison fa...
Status: RESOLVED DUPLICATE of bug 799170
Alias: None
Product: Gentoo/Alt
Classification: Unclassified
Component: Prefix Support (show other bugs)
Hardware: AMD64 OS X
: Normal blocker
Assignee: Gentoo Prefix
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2021-08-04 21:56 UTC by Alex
Modified: 2021-08-27 15:38 UTC (History)
1 user (show)

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


Attachments
gcc stage3 bootstrap log (stage3.log.gz,774.84 KB, application/x-gzip)
2021-08-04 22:01 UTC, Alex
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Alex 2021-08-04 21:56:35 UTC
Bootstrapping prefix on Mac OS 11.4 fails due to gcc bootstrap failure with message about stage2 and stage3 comparison failure:

```
make "DESTDIR=" "RPATH_ENVVAR=DYLD_LIBRARY_PATH" "TARGET_SUBDIR=x86_64-apple-darwin20" "bindir=/Users/egorov/Gentoo/usr/x86_64-apple-darwin20/gcc-bin/10.2.0" "datadir=/Users/egorov/Gentoo/usr/share/gcc-data/x86_64-apple-darwin20/10.2.0" "exec_prefix=/Users/egorov/Gentoo/usr" "includedir=/Users/egorov/Gentoo/usr/lib/gcc/x86_64-apple-darwin20/10.2.0/include" "datarootdir=/Users/egorov/Gentoo/usr/share" "docdir=/Users/egorov/Gentoo/usr/share/doc/" "infodir=/Users/egorov/Gentoo/usr/share/gcc-data/x86_64-apple-darwin20/10.2.0/info" "pdfdir=/Users/egorov/Gentoo/usr/share/doc/" "htmldir=/Users/egorov/Gentoo/usr/share/doc/" "libdir=/Users/egorov/Gentoo/usr/lib" "libexecdir=/Users/egorov/Gentoo/usr/libexec" "lispdir=" "localstatedir=/Users/egorov/Gentoo/usr/var" "mandir=/Users/egorov/Gentoo/usr/share/gcc-data/x86_64-apple-darwin20/10.2.0/man" "oldincludedir=/usr/include" "prefix=/Users/egorov/Gentoo/usr" "sbindir=/Users/egorov/Gentoo/usr/sbin" "sharedstatedir=/Users/egorov/Gentoo/usr/com" "sysconfdir=/Users/egorov/Gentoo/usr/etc" "tooldir=/Users/egorov/Gentoo/usr/x86_64-apple-darwin20" "build_tooldir=/Users/egorov/Gentoo/usr/x86_64-apple-darwin20" "target_alias=x86_64-apple-darwin20" "AWK=gawk" "BISON=bison" "CC_FOR_BUILD=x86_64-apple-darwin20-gcc" "CFLAGS_FOR_BUILD=-pipe -O2" "CXX_FOR_BUILD=x86_64-apple-darwin20-g++ -std=gnu++98" "CXXFLAGS_FOR_BUILD=-pipe -O2" "EXPECT=expect" "FLEX=flex" "INSTALL=/Users/egorov/Gentoo/tmp/usr/bin/install -c" "INSTALL_DATA=/Users/egorov/Gentoo/tmp/usr/bin/install -c -m 644" "INSTALL_PROGRAM=/Users/egorov/Gentoo/tmp/usr/bin/install -c" "INSTALL_SCRIPT=/Users/egorov/Gentoo/tmp/usr/bin/install -c" "LDFLAGS_FOR_BUILD=-L/Users/egorov/Gentoo/usr/lib" "LEX=flex" "M4=gm4" "MAKE=make" "RUNTEST=runtest" "RUNTESTFLAGS=" "SED=/Users/egorov/Gentoo/usr/bin/sed" "SHELL=/Users/egorov/Gentoo/tmp/bin/bash" "YACC=bison -y" "`echo 'ADAFLAGS=' | sed -e s'/[^=][^=]*=$/XFOO=/'`" "ADA_CFLAGS=" "AR_FLAGS=rc" "`echo 'BOOT_ADAFLAGS=-gnatpg' | sed -e s'/[^=][^=]*=$/XFOO=/'`" "BOOT_CFLAGS=-pipe -O2" "BOOT_LDFLAGS=" "CFLAGS=-pipe -O2" "CXXFLAGS=-pipe -O2" "LDFLAGS=-L/Users/egorov/Gentoo/usr/lib" "LIBCFLAGS=-pipe -O2" "LIBCXXFLAGS=-pipe -O2 -fno-implicit-templates" "STAGE1_CHECKING=--enable-checking=release,types" "STAGE1_LANGUAGES=c,c++,lto" "GNATBIND=no" "GNATMAKE=no" "GDC=@GDC@" "GDCFLAGS=-pipe -O2" "AR_FOR_TARGET=/Users/egorov/Gentoo/usr/x86_64-apple-darwin20/bin/ar" "AS_FOR_TARGET=/Users/egorov/Gentoo/usr/x86_64-apple-darwin20/bin/as" "CC_FOR_TARGET=/Users/egorov/Gentoo/var/tmp/portage/sys-devel/gcc-10.2.0-r5/work/build/./gcc/xgcc -B/Users/egorov/Gentoo/var/tmp/portage/sys-devel/gcc-10.2.0-r5/work/build/./gcc/" "CFLAGS_FOR_TARGET=-g -pipe -O2" "CPPFLAGS_FOR_TARGET=" "CXXFLAGS_FOR_TARGET=-g -pipe -O2" "DLLTOOL_FOR_TARGET=dlltool" "FLAGS_FOR_TARGET=-B/Users/egorov/Gentoo/usr/x86_64-apple-darwin20/bin/ -B/Users/egorov/Gentoo/usr/x86_64-apple-darwin20/lib/ -isystem /Users/egorov/Gentoo/usr/x86_64-apple-darwin20/include -isystem /Users/egorov/Gentoo/usr/x86_64-apple-darwin20/sys-include" "GFORTRAN_FOR_TARGET=" "GOC_FOR_TARGET=" "GOCFLAGS_FOR_TARGET=-O2 -g" "GDC_FOR_TARGET=@GDC@" "GDCFLAGS_FOR_TARGET=-O2 -g" "LD_FOR_TARGET=/Users/egorov/Gentoo/usr/x86_64-apple-darwin20/bin/ld" "LIPO_FOR_TARGET=/Users/egorov/Gentoo/usr/x86_64-apple-darwin20/bin/lipo" "LDFLAGS_FOR_TARGET=" "LIBCFLAGS_FOR_TARGET=-g -pipe -O2" "LIBCXXFLAGS_FOR_TARGET=-g -pipe -O2 -fno-implicit-templates" "NM_FOR_TARGET=/Users/egorov/Gentoo/usr/x86_64-apple-darwin20/bin/nm" "OBJDUMP_FOR_TARGET=/Users/egorov/Gentoo/usr/x86_64-apple-darwin20/bin/objdump" "OBJCOPY_FOR_TARGET=/Users/egorov/Gentoo/usr/x86_64-apple-darwin20/bin/objcopy" "RANLIB_FOR_TARGET=/Users/egorov/Gentoo/usr/x86_64-apple-darwin20/bin/ranlib" "READELF_FOR_TARGET=/Users/egorov/Gentoo/usr/x86_64-apple-darwin20/bin/readelf" "STRIP_FOR_TARGET=/Users/egorov/Gentoo/usr/x86_64-apple-darwin20/bin/strip" "WINDRES_FOR_TARGET=windres" "WINDMC_FOR_TARGET=windmc" "BUILD_CONFIG=bootstrap-debug" "`echo 'LANGUAGES=' | sed -e s'/[^=][^=]*=$/XFOO=/'`" "LEAN=false" "STAGE1_CFLAGS=" "STAGE1_CXXFLAGS=" "STAGE1_GENERATOR_CFLAGS=" "STAGE1_TFLAGS=-fno-checking" "STAGE2_CFLAGS=-pipe -O2 -fno-checking  -gtoggle" "STAGE2_CXXFLAGS=-pipe -O2 -fno-checking  -gtoggle" "STAGE2_GENERATOR_CFLAGS=" "STAGE2_TFLAGS=-fno-checking" "STAGE3_CFLAGS=-pipe -O2 -fchecking=1 " "STAGE3_CXXFLAGS=-pipe -O2 -fchecking=1 " "STAGE3_GENERATOR_CFLAGS=" "STAGE3_TFLAGS=-fchecking=1" "STAGE4_CFLAGS=-pipe -O2 " "STAGE4_CXXFLAGS=-pipe -O2 " "STAGE4_GENERATOR_CFLAGS=" "STAGE4_TFLAGS=" "STAGEprofile_CFLAGS=-pipe -O2 -fno-checking  -gtoggle -fprofile-generate" "STAGEprofile_CXXFLAGS=-pipe -O2 -fno-checking  -gtoggle -fprofile-generate" "STAGEprofile_GENERATOR_CFLAGS=" "STAGEprofile_TFLAGS=-fno-checking" "STAGEtrain_CFLAGS=-pipe -O2 " "STAGEtrain_CXXFLAGS=-pipe -O2 " "STAGEtrain_GENERATOR_CFLAGS=" "STAGEtrain_TFLAGS=" "STAGEfeedback_CFLAGS=-pipe -O2  -fprofile-use" "STAGEfeedback_CXXFLAGS=-pipe -O2  -fprofile-use" "STAGEfeedback_GENERATOR_CFLAGS=" "STAGEfeedback_TFLAGS=" "STAGEautoprofile_CFLAGS=-pipe -O2 -fno-checking  -gtoggle -g" "STAGEautoprofile_CXXFLAGS=-pipe -O2 -fno-checking  -gtoggle -g" "STAGEautoprofile_GENERATOR_CFLAGS=" "STAGEautoprofile_TFLAGS=-fno-checking
" "STAGEautofeedback_CFLAGS=-pipe -O2 -fchecking=1 " "STAGEautofeedback_CXXFLAGS=-pipe -O2 -fchecking=1 " "STAGEautofeedback_GENERATOR_CFLAGS=" "STAGEautofeedback_TFLAGS=-fchecking=1" "CXX_FOR_TARGET= $r/./gcc/xg++ -B$r/./gcc/ -nostdinc++ `if test -f $r/x86_64-apple-darwin20/libstdc++-v3/scripts/testsuite_flags; then /Users/egorov/Gentoo/tmp/bin/bash $r/x86_64-apple-darwin20/libstdc++-v3/scripts/testsuite_flags --build-includes; else echo -funconfigured-libstdc++-v3 ; fi` -L$r/x86_64-apple-darwin20/libstdc++-v3/src -L$r/x86_64-apple-darwin20/libstdc++-v3/src/.libs -L$r/x86_64-apple-darwin20/libstdc++-v3/libsupc++/.libs" "TFLAGS=" "CONFIG_SHELL=/Users/egorov/Gentoo/tmp/bin/bash" "MAKEINFO=makeinfo --split-size=5000000 --split-size=5000000"  compare
make[2]: Entering directory '/Users/egorov/Gentoo/var/tmp/portage/sys-devel/gcc-10.2.0-r5/work/build'
make[3]: Entering directory '/Users/egorov/Gentoo/var/tmp/portage/sys-devel/gcc-10.2.0-r5/work/build'
rm -f stage_current
make[3]: Leaving directory '/Users/egorov/Gentoo/var/tmp/portage/sys-devel/gcc-10.2.0-r5/work/build'
Comparing stages 2 and 3
warning: gcc/cc1obj-checksum.o differs
warning: gcc/cc1objplus-checksum.o differs
Bootstrap comparison failure!
gcc/tree-ssa-operands.o differs
gcc/tree-ssanames.o differs
<...>
<a lot of messages about gcc/<libname>.o files being different>
<...>
gcc/var-tracking.o differs
libbacktrace/fileline.o differs
libbacktrace/dwarf.o differs
libbacktrace/sort.o differs
libbacktrace/mmap.o differs
libbacktrace/.libs/fileline.o differs
libbacktrace/.libs/dwarf.o differs
libbacktrace/.libs/sort.o differs
libbacktrace/.libs/mmap.o differs
libcpp/directives-only.o differs
libcpp/pch.o differs
libcpp/traditional.o differs
libcpp/charset.o differs
libcpp/macro.o differs
libcpp/expr.o differs
libcpp/symtab.o differs
libcpp/lex.o differs
libcpp/line-map.o differs
libcpp/init.o differs
libcpp/files.o differs
libcpp/mkdeps.o differs
libcpp/directives.o differs
libdecnumber/decNumber.o differs
libdecnumber/decContext.o differs
libdecnumber/decimal64.o differs
libdecnumber/decimal128.o differs
libdecnumber/decimal32.o differs
libiberty/lbasename.o differs
libiberty/make-relative-prefix.o differs
libiberty/objalloc.o differs
libiberty/simple-object-coff.o differs
libiberty/strerror.o differs
libiberty/strsignal.o differs
libiberty/dwarfnames.o differs
libiberty/rust-demangle.o differs
libiberty/splay-tree.o differs
libiberty/stack-limit.o differs
libiberty/simple-object-elf.o differs
libiberty/argv.o differs
libiberty/xatexit.o differs
libiberty/regex.o differs
libiberty/d-demangle.o differs
libiberty/make-temp-file.o differs
libiberty/getopt.o differs
libiberty/concat.o differs
libiberty/fnmatch.o differs
libiberty/pex-unix.o differs
libiberty/simple-object.o differs
libiberty/pic/lbasename.o differs
libiberty/pic/make-relative-prefix.o differs
libiberty/pic/objalloc.o differs
libiberty/pic/simple-object-coff.o differs
libiberty/pic/strerror.o differs
libiberty/pic/strsignal.o differs
libiberty/pic/dwarfnames.o differs
libiberty/pic/rust-demangle.o differs
libiberty/pic/splay-tree.o differs
libiberty/pic/stack-limit.o differs
libiberty/pic/simple-object-elf.o differs
libiberty/pic/argv.o differs
libiberty/pic/xatexit.o differs
libiberty/pic/regex.o differs
libiberty/pic/d-demangle.o differs
libiberty/pic/make-temp-file.o differs
libiberty/pic/getopt.o differs
libiberty/pic/concat.o differs
libiberty/pic/fnmatch.o differs
libiberty/pic/pex-unix.o differs
libiberty/pic/simple-object.o differs
libiberty/pic/cp-demangle.o differs
libiberty/pic/fibheap.o differs
libiberty/pic/obstack.o differs
libiberty/pic/partition.o differs
libiberty/pic/simple-object-mach-o.o differs
libiberty/pic/pexecute.o differs
libiberty/pic/physmem.o differs
libiberty/pic/hashtab.o differs
libiberty/pic/sha1.o differs
libiberty/pic/timeval-utils.o differs
libiberty/pic/simple-object-xcoff.o differs
libiberty/pic/pex-common.o differs
libiberty/pic/cp-demint.o differs
libiberty/pic/getpwd.o differs
libiberty/pic/filename_cmp.o differs
libiberty/pic/dyn-string.o differs
libiberty/pic/cplus-dem.o differs
libiberty/pic/vprintf-support.o differs
libiberty/cp-demangle.o differs
libiberty/fibheap.o differs
libiberty/obstack.o differs
libiberty/partition.o differs
./var/db/repos/gentoo/games-mud/kildclient/kildclient-3.0.1-r1.ebuild
./var/db/repos/gentoo/games-mud/powwow/powwow-1.2.22.ebuild
./var/db/repos/gentoo/games-mud/powwow/powwow-1.2.16-r1.ebuild
./var/db/repos/gentoo/games-mud/gmudix/gmudix-1.0-r1.ebuild
./var/db/repos/gentoo/games-mud/crystal/crystal-0.2.4-r1.ebuild
./var/db/repos/gentoo/games-mud/tkmoo/tkmoo-0.3.32-r1.ebuild
./var/db/repos/gentoo/games-mud/trebuchet/trebuchet-1.075-r1.ebuild
* Triggering Darwin with GCC toolchain
USE=-acl -berkdb -fortran -gdbm -git -libcxx -nls -pcre -python -qmanifest -qtegrity -readline bootstrap clang internal-glib prefix-stack PKG=sys-apps/gentoo-functions
2;stage3: emerge sys-apps/gentoo-functions^G!!! BINPKG_COMPRESS unsupported zstd. Missing package: app-arch/zstd!!! BINPKG_COMPRESS unsupported zstd. Missing package: app-arch/zstd
These are the packages that would be merged, in order:

[ebuild  N     ] sys-apps/gentoo-functions-0.14::gentoo_prefix  0 KiB

Total: 1 package (1 new), Size of downloads: 0 KiB

>>> Verifying ebuild manifests


>>> Emerging (1 of 1) sys-apps/gentoo-functions-0.14::gentoo_prefix
Warning: File compression unsupported zstd. Missing package: app-arch/zstd
 * gentoo-functions-0.14.tar.gz BLAKE2B SHA512 size ;-) ...              [ ok ]
>>> Unpacking source...
>>> Unpacking gentoo-functions-0.14.tar.gz to /Users/egorov/Gentoo/var/tmp/portage/sys-apps/gentoo-functions-0.14/work
>>> Source unpacked in /Users/egorov/Gentoo/var/tmp/portage/sys-apps/gentoo-functions-0.14/work
>>> Preparing source in /Users/egorov/Gentoo/var/tmp/portage/sys-apps/gentoo-functions-0.14/work/gentoo-functions-0.14 ...
>>> Source prepared.
>>> Configuring source in /Users/egorov/Gentoo/var/tmp/portage/sys-apps/gentoo-functions-0.14/work/gentoo-functions-0.14 ...
>>> Source configured.
>>> Compiling source in /Users/egorov/Gentoo/var/tmp/portage/sys-apps/gentoo-functions-0.14/work/gentoo-functions-0.14 ...
make SHELL=/Users/egorov/Gentoo/tmp/bin/bash -j7
x86_64-apple-darwin20-gcc -march=native -O2 -pipe -isystem /Users/egorov/Gentoo/usr/include -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -L/Users/egorov/Gentoo/usr/lib  consoletype.c   -o consoletype
>>> Source compiled.
>>> Test phase [not enabled]: sys-apps/gentoo-functions-0.14

>>> Install sys-apps/gentoo-functions-0.14 into /Users/egorov/Gentoo/var/tmp/portage/sys-apps/gentoo-functions-0.14/image
make SHELL=/Users/egorov/Gentoo/tmp/bin/bash -j7 DESTDIR=/Users/egorov/Gentoo/var/tmp/portage/sys-apps/gentoo-functions-0.14/image install
install -m 0755 -d /Users/egorov/Gentoo/var/tmp/portage/sys-apps/gentoo-functions-0.14/image/Users/egorov/Gentoo/sbin
install -m 0755 consoletype /Users/egorov/Gentoo/var/tmp/portage/sys-apps/gentoo-functions-0.14/image/Users/egorov/Gentoo/sbin
install -m 0755 -d /Users/egorov/Gentoo/var/tmp/portage/sys-apps/gentoo-functions-0.14/image/Users/egorov/Gentoo/lib/gentoo
install -m 0644 functions.sh /Users/egorov/Gentoo/var/tmp/portage/sys-apps/gentoo-functions-0.14/image/Users/egorov/Gentoo/lib/gentoo
install -m 0755 -d /Users/egorov/Gentoo/var/tmp/portage/sys-apps/gentoo-functions-0.14/image/Users/egorov/Gentoo/usr/share/man/man1
install -m 0644 consoletype.1 /Users/egorov/Gentoo/var/tmp/portage/sys-apps/gentoo-functions-0.14/image/Users/egorov/Gentoo/usr/share/man/man1
>>> Completed installing sys-apps/gentoo-functions-0.14 into /Users/egorov/Gentoo/var/tmp/portage/sys-apps/gentoo-functions-0.14/image

 * Final size of build directory: 100 KiB
 * Final size of installed tree:   68 KiB

/Users/egorov/Gentoo/tmp/usr/lib/portage/bin/ecompress: line 65: declare: -A: invalid option
declare: usage: declare [-afFirtx] [-p] [name[=value] ...]
/Users/egorov/Gentoo/tmp/usr/lib/portage/bin/misc-functions.sh: line 306: scanmacho: command not found

>>> Installing (1 of 1) sys-apps/gentoo-functions-0.14::gentoo_prefix
Warning: File compression unsupported zstd. Missing package: app-arch/zstd
...skipping...
libiberty/pic/stack-limit.o differs
libiberty/pic/simple-object-elf.o differs
libiberty/pic/argv.o differs
libiberty/pic/xatexit.o differs
libiberty/pic/regex.o differs
libiberty/pic/d-demangle.o differs
libiberty/pic/make-temp-file.o differs
libiberty/pic/getopt.o differs
libiberty/pic/concat.o differs
libiberty/pic/fnmatch.o differs
libiberty/pic/pex-unix.o differs
libiberty/pic/simple-object.o differs
libiberty/pic/cp-demangle.o differs
libiberty/pic/fibheap.o differs
libiberty/pic/obstack.o differs
libiberty/pic/partition.o differs
libiberty/pic/simple-object-mach-o.o differs
libiberty/pic/pexecute.o differs
libiberty/pic/physmem.o differs
libiberty/pic/hashtab.o differs
libiberty/pic/sha1.o differs
libiberty/pic/timeval-utils.o differs
libiberty/pic/simple-object-xcoff.o differs
libiberty/pic/pex-common.o differs
libiberty/pic/cp-demint.o differs
libiberty/pic/getpwd.o differs
libiberty/pic/filename_cmp.o differs
libiberty/pic/dyn-string.o differs
libiberty/pic/cplus-dem.o differs
libiberty/pic/vprintf-support.o differs
libiberty/cp-demangle.o differs
libiberty/fibheap.o differs
libiberty/obstack.o differs
libiberty/partition.o differs
libiberty/simple-object-mach-o.o differs
libiberty/pexecute.o differs
libiberty/physmem.o differs
libiberty/hashtab.o differs
libiberty/sha1.o differs
libiberty/timeval-utils.o differs
libiberty/simple-object-xcoff.o differs
libiberty/pex-common.o differs
libiberty/cp-demint.o differs
libiberty/getpwd.o differs
libiberty/filename_cmp.o differs
libiberty/dyn-string.o differs
libiberty/cplus-dem.o differs
libiberty/vprintf-support.o differs
make[2]: *** [Makefile:21250: compare] Error 1
make[2]: Leaving directory '/Users/egorov/Gentoo/var/tmp/portage/sys-devel/gcc-10.2.0-r5/work/build'
make[1]: *** [Makefile:21230: stage3-bubble] Error 2
make[1]: Leaving directory '/Users/egorov/Gentoo/var/tmp/portage/sys-devel/gcc-10.2.0-r5/work/build'
make: *** [Makefile:1026: all] Error 2
 * ERROR: sys-devel/gcc-10.2.0-r5::gentoo_prefix failed (compile phase):
 *   emake failed
```

Reproducible: Always

Steps to Reproduce:
1. Start bootstrapping prefix on Mac OS
2. Wait for gcc to almost finish its emerge

Actual Results:  
Failure with described message

Expected Results:  
Successful bootstrapping

Probably related to this gcc issue: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=100340
Comment 1 Alex 2021-08-04 22:01:04 UTC
Created attachment 730179 [details]
gcc stage3 bootstrap log
Comment 2 Fabian Groffen gentoo-dev 2021-08-17 08:09:01 UTC
do you have -g in your CFLAGS yourself, or is it part of the defaults somehow?
Comment 3 Alex 2021-08-17 10:41:50 UTC
(In reply to Fabian Groffen from comment #2)
> do you have -g in your CFLAGS yourself, or is it part of the defaults
> somehow?

I haven't modified the installation in any way, so it must be a part of the defaults.
Comment 4 Fabian Groffen gentoo-dev 2021-08-27 15:27:15 UTC
I just tried bootstrapping on a stock x86_64-apple-darwin20, which worked fine, need to check the xcode version there to see if it makes a difference.
Comment 5 Fabian Groffen gentoo-dev 2021-08-27 15:38:41 UTC

*** This bug has been marked as a duplicate of bug 799170 ***