From bb07b62755da9752e40ad1d5bcfcf7312c8b47fb Mon Sep 17 00:00:00 2001 From: Ralf Wildenhues Date: Mon, 20 Dec 2004 08:15:36 +0000 Subject: [PATCH] * m4/libtool.m4 [solaris] (_LT_LINKER_SHLIBS): Add '${wl}-z ${wl}text' to archive_cmds and archive_expsyms_cmds. I.e., do not allow nopic in shared libraries. --- ChangeLog | 4 ++++ m4/libtool.m4 | 4 ++-- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/ChangeLog b/ChangeLog index 23c93f7cb..a80f6d1bd 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,9 @@ 2004-12-20 Ralf Wildenhues + * m4/libtool.m4 [solaris] (_LT_LINKER_SHLIBS): Add '${wl}-z ${wl}text' + to archive_cmds and archive_expsyms_cmds. I.e., do not allow nopic in + shared libraries. + * m4/libtool.m4 [solaris] (_LT_LINKER_SHLIBS): Change no_undefined_flag back to ' -z defs'. Problems with linking against libgcc.a will have to be resolved differently. diff --git a/m4/libtool.m4 b/m4/libtool.m4 index b735e0a60..f72338ebc 100644 --- a/m4/libtool.m4 +++ b/m4/libtool.m4 @@ -4151,9 +4151,9 @@ _LT_EOF solaris*) _LT_TAGVAR(no_undefined_flag, $1)=' -z defs' if test "$GCC" = yes; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='$ECHO "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$ECHO "local: *; };" >> $lib.exp~ - $CC -shared ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' + $CC -shared ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' else case `$CC -V 2>&1` in *"Compilers 5.0"*) -- 2.47.2