https://gcc.gnu.org/bugzilla/show_bug.cgi?id=97865
--- Comment #23 from Jürgen Reuter <juergen.reuter at desy dot de> --- (In reply to Iain Sandoe from comment #18) > (In reply to Jürgen Reuter from comment #17) > ----- > > * I found that there was one incorrect case in libgfortran (where there is a > direct reference to **environ from the dylib, which is not allowed) - this > was being hidden by the 'global dynamic_lookup' -- the > master-wip-config-darwin20 branch has a patch now for that too. > > My test setup > > clean install of macOS11.0.1 > master-wip-config-darwin20 > command line install of XC12.2RC > GMP/MPFR/PMC/ISL are built in-tree (the sources are symlinked into the root > dir) > > /src-local/gcc-master/configure > --prefix=/opt/iains/x86_64-apple-darwin20/gcc-11-0-0 > --target=x86_64-apple-darwin20 --host=x86_64-apple-darwin20 > --build=x86_64-apple-darwin20 > --with-sysroot=/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk > --enable-languages=all CC=x86_64-apple-darwin19-gcc > CXX=x86_64-apple-darwin19-g++ > > ==== > > The effort of testing a top-level configuration change across multiple > platforms is quite significant - so I'd rather not hack a minimal change and > then have to go back and fix it properly later - so let's get to the bottom > of what's happening and find the correct solution. So with that patch it works. Probably it worked even before your last fix, as I think I cloned the first your repo just with the link above, but was on master, not on the master-wip-config-darwin20, my fault. I compiled/bootstrapped now with Apple clang version 12.0.0 (clang-1200.0.32.27), and just did make -i install, skipping over the error, which I think is not relevant for me. I used my patches for the gmp, mpfr, mpc, though I think it's not relevant for them. In any case I notified their developers about the issue. Hope we get a stable and convincing solution into 11.0.1. Will you then backport this for upcoming 10.3 and 9.4 as well? (for 8 it's probably too late).