[PATCH] Add --enable-static-c++-link-check option [BZ #31412]

H.J. Lu hjl.tools@gmail.com
Sun May 26 14:26:00 GMT 2024


On Sun, May 26, 2024 at 7:08 AM Florian Weimer <fweimer@redhat.com> wrote:
>
> * H. J. Lu:
>
> >> > with GCC 6.4.  I will check if it is a testcase issue.
> >> >
> >> >> Even CXX=no will not work because in some configurations, it's actually
> >> >> libgcc_s.so.1 that can't be loaded, and that breaks pthread_cancel.
> >> >>
> >> >
> >> > c++ still works.  Only "c++ -static" doesn't work with the system libc.a.
> >>
> >> I think you'll see the issue if you go back further, to the 2.34 branch.
> >>
> >
> > I set up LD_LIBRARY_PATH to GCC 6.4 run-time libraries and only saw
> >
> > FAIL: nptl/tst-pthread-gdb-attach
> > FAIL: nptl/tst-pthread-gdb-attach-static
> >
> > which is caused by gdb dependency on GCC 14 run-time libraries.
> >
> > --disable-static-c++-link-check together with --disable-static-c++-tests
> > allow me to test ppc64le glibc on GCC compiler farm.
>
> Has this GCC 6.4 been built against system glibc?

No.  GCC 6.4 binaries were built years agao.

> The use case for what you are trying to do seems to be really narrow to
> me.  In general, building a fresh glibc against system glibc will not
> result in a GCC that is compatible with the (earlier) glibc under
> development.  GCC before 12 probably has it a lot easier.
>

I used GCC 6.4 on Fedora 40 to verify that glibc source is buildable with
GCC 6 and I discovered a glibc bug:

https://sourceware.org/bugzilla/show_bug.cgi?id=31798

-- 
H.J.


More information about the Libc-alpha mailing list