This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
[Patch, Ada, Darwin] Remove explicit "-lm" from shared library builds.
- From: Iain Sandoe <developer at sandoe-acoustics dot co dot uk>
- To: GCC Patches <gcc-patches at gcc dot gnu dot org>
- Cc: Mike Stump <mrs at gcc dot gnu dot org>, Arnaud Charlet <charlet at adacore dot com>
- Date: Tue, 6 Sep 2011 08:22:08 +0100
- Subject: [Patch, Ada, Darwin] Remove explicit "-lm" from shared library builds.
"-lm" is a symlink to libSystem.dylib on all recent Darwin and
therefore not required (as libSystem is automatically provided by gcc).
Using -lm (especially when in conjunction with "-flat_namespace") can
cause unexpected differences in behavior between Darwin 9 -> Darwin10
(where the unwinder was moved to libSystem) - since it causes
libSystem to be placed ahead of other libs.
- I guess it could be a config subsitution if anyone thinks it worth
it for (really) ancient Darwin support - but I've just removed it.
(no Ada regressions from this on *-darwin9 and x86-64-darwin10.)
OK for trunk?
Iain
ada:
* gcc-interface/Makefile.in (gnatlib-shared-darwin): Remove
reference to "-lm".
Attachment:
178555-ada-sharedlib-lm-fix.txt
Description: Text document