[RFC, patch] Detect lack of 32-bit devel environment on x86_64-linux targets

Richard Biener richard.guenther@gmail.com
Fri Jan 31 14:45:00 GMT 2014


On Fri, Dec 13, 2013 at 10:47 PM, FX <fxcoudert@gmail.com> wrote:
>> The patch is okay, but if other architecture maintainers could add
>> similar checks for their ports (SPARC and PPC, I guess), it would be nice.
>
> Thanks, committed as rev. 205975
>
> Adding other systems to the list of checks will be easy, once the maintainers confirm that they want to opt in into it.

In our default build environment for package building GCC no longer builds
because of this:

[  152s] /usr/lib64/gcc/x86_64-suse-linux/4.8/../../../../x86_64-suse-linux/bin/
ld: skipping incompatible /usr/lib64/gcc/x86_64-suse-linux/4.8/libgcc.a when sea
rching for -lgcc
[  152s] /usr/lib64/gcc/x86_64-suse-linux/4.8/../../../../x86_64-suse-linux/bin/
ld: cannot find -lgcc
[  152s] /usr/lib64/gcc/x86_64-suse-linux/4.8/../../../../x86_64-suse-linux/bin/ld:
skipping incompatible /usr/lib64/gcc/x86_64-suse-linux/4.8/libgcc_s.so
when searching for -lgcc_s
[  152s] /usr/lib64/gcc/x86_64-suse-linux/4.8/../../../../x86_64-suse-linux/bin/ld:
cannot find -lgcc_s
[  152s] collect2: error: ld returned 1 exit status
[  152s] configure: error: I suspect your system does not have 32-bit
developement libraries (libc and headers). If you have them, rerun
configure with --enable-multilib. If you do not have them, and want to
build a 64-bit-only compiler, rerun configure with --disable-multilib.

the issue is that while we do have 32bit glibc support installed but not all
required files for the host compiler to produce 32bit executables - which
isn't needed - the compiler we bootstrap will have all the support for this.

In fact, a x86_64 multilib GCC can be just bootstrapped fine with a
non-multilib x86_64 compiler which you also disallow with the above check.

I don't see how you can do this configure check in its current form early,
before you've built the stage1 compiler.

So - please consider reverting this patch or at least provide a way to
override the check.

Thanks,
Richard.



> FX



More information about the Gcc-patches mailing list