This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |
Other format: | [Raw text] |
On Darwin (before 8), constructors are done lazy on the load of the module containing the constructor so the initializer for libgfortran is not done unless you either call set_args or use the provided main which calls set_args. The way to fix this is just to make libgfortran one module while linking and this patch fixes that by adding the extra flag of "-single_module".
Thanks, Andrew Pinski
* configure.ac (extra_ldflags_libgfortran): Set for *-darwin* to "-Wl,-single_module". * configure: Regenerate. * Makefile.am (libgfortran_la_LDFLAGS): Add extra_ldflags_libgfortran. * Makefile.in: Regenerate.
Attachment:
fixPR20766.diff.txt
Description: Text document
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |