The file sysdeps/generic/framestate.c has a hardcoded value of "libgcc.so.1". Some architectures have bumped the so version on libgcc_s and therefore the hardcoded value is wrong. It would be nice if ports could write: ports/sysdeps/$target/framestate.c: #define LIBGCC_S_SO "libgcc_so.so.2" #include-next <framestate.c> There are other alternatives but this one seemed the simplest and easiest to maintain. Patch attached.
Created attachment 1746 [details] [PATCH] Allow override of "libgcc_s.so.1" in framestate.c This patch allows the override of "libgcc_s.so.1" in sysdeps/generic/framestate.c. Tested without regressions on hppa-linux-gnu.
framestate.c is so short that I wonder if it isn't better just to duplicate the file in ports.
Not like this. Provide a patch which determines the correct name, adds it to the names in the generated gnu/lib-names.h, and then use that name in framestate.c.
No reply in 3+ months. Closing.
Created attachment 4144 [details] Another attempt Hello, The attached patch makes another attempt to fix this issue. It doesn't implement exactly the solution Ulrich proposed above in that it doesn't detects the version of libgcc_s.so installed. Instead, the patch make GLIBC to rely on shlib-versions files to specify it. The entry in top-level shlib-versions file specifies the version of libgcc_s to be '1' (what most architectures have) and shlib-versions in sysdeps directories can override that. FWIW, making GLIBC to autodetect the version of libgcc_s installed does not seem trivial to me.
Created attachment 4145 [details] Set libgcc_s' version for m68k and hppa This patch sets libgcc_s' version to 2 for m68k and to 4 for hppa. The combined patch was tested on m68k and powerpc.
Would please maintainers kindly consider the patches attached above?
Ping. Would maintainers please kindly consider the patches in the attachment.
This is now fixed on trunk by these patches. This fix will be part of 2.11 given that the 2.11 branch happens from trunk. / 2009-11-03 Andreas Schwab <schwab@linux-m68k.org> [BZ #4457] * sysdeps/generic/libgcc_s.h: New file. * sysdeps/generic/framestate.c: Include it and use LIBGCC_S_SO. nptl/ 2009-11-03 Andreas Schwab <schwab@linux-m68k.org> [BZ #4457] * sysdeps/pthread/unwind-resume.c: Include <libgcc_s.h> and use LIBGCC_S_SO. * sysdeps/pthread/unwind-forcedunwind.c: Likewise.
Per the new bugzilla procedure I've opened new issues for m68k and hppa to provide libgcc_s.h.