[PATCH] Don't build programs in $(others-noinstall) like tests when cross-compiling

Joseph Myers josmyers@redhat.com
Fri Oct 31 21:24:18 GMT 2025


On Fri, 31 Oct 2025, H.J. Lu wrote:

> On Fri, Oct 31, 2025 at 1:00 AM Andreas Schwab <schwab@suse.de> wrote:
> >
> > On Sep 15 2025, H.J. Lu wrote:
> >
> > > Programs in $(others-noinstall) are internal to glibc build and they
> > > aren't installed.  They should be treated like programs in $(others),
> > > but linked like tests so that --enable-hardcoded-path-in-tests also
> > > applies to them.
> >
> > This is breaking cross builds, they are now requiring libgcc_s to link
> > the other-install programs.
> 
> Don't build programs in $(others-noinstall) like tests when
> cross-compiling.  Otherwise, "build-many-glibcs.py compilers" will
> fail to build the initial glibc with the initial limited gcc due to
> the missing libgcc_s.

It's a bad idea to build things differently based on whether cross 
compiling; cross compiling and native compiling should produce the same 
binaries, both installed and uninstalled, to the extent that the compilers 
used have the same features available (and the installed binaries should 
be identical even when built with an initial bootstrap cross compiler).

We do have a configure test "whether $CC can link against -lgcc_s" which 
could be used if needed for non-installed binaries rather than a test on 
cross compiling (note the comment that this must not be used for installed 
binaries).

-- 
Joseph S. Myers
josmyers@redhat.com


More information about the Libc-alpha mailing list