[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Links self with wrong linker
From: |
Morten Welinder |
Subject: |
Re: Links self with wrong linker |
Date: |
Wed, 6 Apr 2005 15:46:03 -0400 |
I can fix my problems if I change a section on libtool.m4 around line
5750 to the
sniplet below.
1. The added "xxx" forces the branch I want. Yes, that's crude.
2. Note the whole_archive_flag_spec line -- I had to remove some ${wl} quoting
there. The need for that would appear to be an independent bug.
Morten
solaris*)
_LT_AC_TAGVAR(no_undefined_flag, $1)=' -z text'
if test "xxx$GCC" = yes; then
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h ${wl}$soname -o
$lib $libobjs $deplibs $compiler_flags'
_LT_AC_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'
else
_LT_AC_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h
$soname -o $lib $libobjs $deplibs $linker_flags'
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" >
$lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >>
$lib.exp~$echo "local: *; };" >> $lib.exp~
$LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib
$libobjs $deplibs $linker_flags~$rm $lib.exp'
fi
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
case $host_os in
solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
*) # Supported since Solaris 2.6 (maybe 2.5.1?)
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience
-z defaultextract' ;;
esac
_LT_AC_TAGVAR(link_all_deplibs, $1)=yes
;;