https://gcc.gnu.org/bugzilla/show_bug.cgi?id=115907

--- Comment #42 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
(In reply to frankhb1989 from comment #41)
> I ran into exact the same trouble of C23 missing symbols on old systems. In
> my case it is a custom build (with tailored source) of libfreeimage which
> has some calls to `sscanf` pulling the unwanted symbol references (to
> `__isoc23_sscanf@GLIBC_2.38`) into the library

That is not a glibc issue but rather you are thinking glibc will be forwards
compatible; glibc is not and never can be; this is true for almost all OS out
there (Mac OS has a similar issue though they provide sysroots with all needed
headers/libraries so it is slightly easier to handle rather than you need to go
out and find one). It is definitely backwards compatiable. If you want to build
a program that runs on older systems you 100% need to use the earliest version
of glibc to link (and use headers from) against rather than the newest version.

Reply via email to