[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: lang/gcc10 does not compile with Darwin 20.5.0 + Xcode 11.4
On 6/18/21 10:40 AM, Adam wrote:
I read through that too and thought it really meant —with-dwarf2 as well.
However, we use that option for older versions of Darwin:
This is Darwin 20.2.0, so I don’t think that matches.
In any case, the discussion of including differing debug information seems more plausible, although I have not had a chance to check and I don’t know the implications of that. For reference, here is what the gcc docs  say about that option:
Verifies that the compiler generates the same executable code, whether or not it is asked to emit debug information. To this end, this option builds stage2 host programs without debug information, and uses contrib/compare-debug to compare them with the stripped stage3 object files. If BOOT_CFLAGS is overridden so as to not enable debug information, stage2 will have it, and stage3 won’t. This option is enabled by default when GCC bootstrapping is enabled, if strip can turn object files compiled with and without debug info into identical object files. In addition to better test coverage, this option makes default bootstraps faster and leaner.
Perhaps someone who knows this better than I will chime in.
I have added these to Makefile
and GCC builds turbo fast (one stage, I guess) without complaining.
I got a successful install by disabling the stage 2-3 comparison in the
generated Makefile and it seems to work, but it's a matter of how much
we trust the build to produce correct output with these checks disabled.
I think it's not as critical to Darwin pkgsrc users as it is to Linux
users who use GCC for everything, but it would be better to understand
why the stage comparison is failing in any case.
My build just finished and showed that enabling --with-dwarf2 alone is
not enough, so I guess we'll have
+# Avert stage 2 & 3 compare errors
+.if !empty(MACHINE_PLATFORM:MDarwin-[0-8].*-*) ||
Darwin abalone.acadix bacon ~/Pkgsrc/pkgsrc/lang/gcc10 82: (pkgsrc):
grep dwarf work/build/config.log
$ ../gcc-10.3.0/configure --disable-libstdcxx-pch --disable-nls
--enable-libssp --enable-languages=c obj-c++ objc fortran c++
-L/Users/bacon/Pkgsrc/pkg/lib --with-system-zlib --without-zstd
The "strip" command doesn't seem to work on Darwin, so I'm still not
clear on how to confirm that the differences are just debug info.
Darwin abalone.acadix bacon ~/Pkgsrc/pkgsrc/lang/gcc10 80: (pkgsrc):
find work/ -name yn.o -ls
22512786 56 -rw-r--r-- 1 bacon staff
27156 Jun 18 08:40 work//build/stage1-mpfr/src/yn.o
22572858 56 -rw-r--r-- 1 bacon staff
28060 Jun 18 10:41 work//build/stage3-mpfr/src/yn.o
22543202 24 -rw-r--r-- 1 bacon staff
12148 Jun 18 09:24 work//build/stage2-mpfr/src/yn.o
Main Index |
Thread Index |