mirror of
git://git.savannah.gnu.org/libtool.git
synced 2024-11-27 06:09:57 +08:00
* libtool.m4 (darwin): Remove checks for Apple-specific gcc.
* libltdl/ltdl.c (HAVE_MACH_O_DYLD_H): #define __private_extern__ for fsf gcc. * ltmain.in (darwin): Only add new paths to newlib_search_path.
This commit is contained in:
parent
e2b9104502
commit
90233b7fa9
@ -1,3 +1,10 @@
|
||||
2003-06-03 Peter O'Gorman <peter@pogma.com>
|
||||
|
||||
* libtool.m4 (darwin): Remove checks for Apple-specific gcc.
|
||||
* libltdl/ltdl.c (HAVE_MACH_O_DYLD_H): #define
|
||||
__private_extern__ for fsf gcc.
|
||||
* ltmain.in (darwin): Only add new paths to newlib_search_path.
|
||||
|
||||
2003-06-03 Max Bowsher <maxb@ukf.net>
|
||||
|
||||
* libtool.m4 (AC_LIBTOOL_SYS_DYNAMIC_LINKER): Reorder cygwin's
|
||||
|
@ -1580,6 +1580,10 @@ static struct lt_user_dlloader sys_dld = {
|
||||
|
||||
|
||||
#if HAVE_MACH_O_DYLD_H
|
||||
#if !defined(__APPLE_CC__) && !defined(__MWERKS__) && !defined(__private_extern__)
|
||||
/* Is this correct? Does it still function properly? */
|
||||
#define __private_extern__ extern
|
||||
#endif
|
||||
# include <mach-o/dyld.h>
|
||||
#endif
|
||||
#include <mach-o/getsect.h>
|
||||
|
79
libtool.m4
vendored
79
libtool.m4
vendored
@ -1256,17 +1256,16 @@ darwin* | rhapsody*)
|
||||
version_type=darwin
|
||||
need_lib_prefix=no
|
||||
need_version=no
|
||||
# FIXME: Relying on posixy $() will cause problems for
|
||||
# cross-compilation, but unfortunately the echo tests do not
|
||||
# yet detect zsh echo's removal of \ escapes.
|
||||
library_names_spec='${libname}${release}${versuffix}$shared_ext ${libname}${release}${major}$shared_ext ${libname}$shared_ext'
|
||||
soname_spec='${libname}${release}${major}$shared_ext'
|
||||
shlibpath_overrides_runpath=yes
|
||||
shlibpath_var=DYLD_LIBRARY_PATH
|
||||
shrext='$(test .$module = .yes && echo .so || echo .dylib)'
|
||||
# Apple's gcc prints 'gcc -print-search-dirs' doesn't operate the same.
|
||||
if $CC -v 2>&1 | grep 'Apple' >/dev/null ; then
|
||||
sys_lib_search_path_spec=`$CC -print-search-dirs | tr "\n" "$PATH_SEPARATOR" | sed -e 's/libraries:/@libraries:/' | tr "@" "\n" | grep "^libraries:" | sed -e "s/^libraries://" -e "s,=/,/,g" -e "s,$PATH_SEPARATOR, ,g" -e "s,.*,& /lib /usr/lib /usr/local/lib,g"`
|
||||
if test "$GCC" = yes; then
|
||||
sys_lib_search_path_spec=`$CC -print-search-dirs | tr "\n" "$PATH_SEPARATOR" | sed -e 's/libraries:/@libraries:/' | tr "@" "\n" | grep "^libraries:" | sed -e "s/^libraries://" -e "s,=/,/,g" -e "s,$PATH_SEPARATOR, ,g" -e "s,.*,& /lib /usr/lib /usr/local/lib,g"`
|
||||
else
|
||||
sys_lib_search_path_spec='/lib /usr/lib /usr/local/lib'
|
||||
fi
|
||||
sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
|
||||
;;
|
||||
@ -2551,7 +2550,7 @@ aix4*)
|
||||
fi
|
||||
;;
|
||||
darwin* | rhapsody*)
|
||||
if $CC -v 2>&1 | grep 'Apple' >/dev/null ; then
|
||||
if test "$GCC" = yes; then
|
||||
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
|
||||
case "$host_os" in
|
||||
rhapsody* | darwin1.[[012]])
|
||||
@ -2561,22 +2560,20 @@ aix4*)
|
||||
test -z ${LD_TWOLEVEL_NAMESPACE} && _LT_AC_TAGVAR(allow_undefined_flag, $1)='-flat_namespace -undefined suppress'
|
||||
;;
|
||||
esac
|
||||
# FIXME: Relying on posixy $() will cause problems for
|
||||
# cross-compilation, but unfortunately the echo tests do not
|
||||
# yet detect zsh echo's removal of \ escapes. Also zsh mangles
|
||||
# `"' quotes if we put them in here... so don't!
|
||||
output_verbose_link_cmd='echo'
|
||||
output_verbose_link_cmd='echo'
|
||||
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs$compiler_flags -install_name $rpath/$soname $verstring'
|
||||
_LT_AC_TAGVAR(module_cmds, $1)='$CC -bundle $allow_undefined_flag -o $lib $libobjs $deplibs$compiler_flags'
|
||||
_LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
|
||||
# Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin ld's
|
||||
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs$compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
|
||||
_LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -bundle $allow_undefined_flag -o $lib $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
|
||||
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs$compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
|
||||
_LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
|
||||
_LT_AC_TAGVAR(hardcode_direct, $1)=no
|
||||
_LT_AC_TAGVAR(hardcode_automatic, $1)=yes
|
||||
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
|
||||
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)='-all_load $convenience'
|
||||
_LT_AC_TAGVAR(link_all_deplibs, $1)=yes
|
||||
fi
|
||||
else
|
||||
_LT_AC_TAGVAR(ld_shlibs, $1)=no
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
AC_MSG_RESULT([$enable_shared])
|
||||
@ -2879,7 +2876,7 @@ case $host_os in
|
||||
;;
|
||||
|
||||
darwin* | rhapsody*)
|
||||
if $CC -v 2>&1 | grep 'Apple' >/dev/null ; then
|
||||
if test "$GXX" = yes; then
|
||||
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
|
||||
case "$host_os" in
|
||||
rhapsody* | darwin1.[[012]])
|
||||
@ -2889,31 +2886,33 @@ case $host_os in
|
||||
test -z ${LD_TWOLEVEL_NAMESPACE} && _LT_AC_TAGVAR(allow_undefined_flag, $1)='-flat_namespace -undefined suppress'
|
||||
;;
|
||||
esac
|
||||
lt_int_apple_cc_single_mod=no
|
||||
output_verbose_link_cmd='echo'
|
||||
if $CC -dumpspecs 2>&1 | grep 'single_module' >/dev/null ; then
|
||||
lt_int_apple_cc_single_mod=yes
|
||||
fi
|
||||
if test "X$lt_int_apple_cc_single_mod" = Xyes ; then
|
||||
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -dynamiclib -single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring'
|
||||
else
|
||||
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -r ${wl}-bind_at_load -keep_private_externs -nostdlib -o ${lib}-master.o $libobjs~$CC -dynamiclib $allow_undefined_flag -o $lib ${lib}-master.o $deplibs $compiler_flags -install_name $rpath/$soname $verstring'
|
||||
fi
|
||||
_LT_AC_TAGVAR(module_cmds, $1)='$CC -bundle ${wl}-bind_at_load $allow_undefined_flag -o $lib $libobjs $deplibs$compiler_flags'
|
||||
lt_int_apple_cc_single_mod=no
|
||||
output_verbose_link_cmd='echo'
|
||||
if $CC -dumpspecs 2>&1 | grep 'single_module' >/dev/null ; then
|
||||
lt_int_apple_cc_single_mod=yes
|
||||
fi
|
||||
if test "X$lt_int_apple_cc_single_mod" = Xyes ; then
|
||||
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -dynamiclib -single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring'
|
||||
else
|
||||
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -r ${wl}-bind_at_load -keep_private_externs -nostdlib -o ${lib}-master.o $libobjs~$CC -dynamiclib $allow_undefined_flag -o $lib ${lib}-master.o $deplibs $compiler_flags -install_name $rpath/$soname $verstring'
|
||||
fi
|
||||
_LT_AC_TAGVAR(module_cmds, $1)='$CC ${wl}-bind_at_load $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
|
||||
|
||||
# Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin ld's
|
||||
if test "X$lt_int_apple_cc_single_mod" = Xyes ; then
|
||||
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -dynamiclib -single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
|
||||
else
|
||||
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -r ${wl}-bind_at_load -keep_private_externs -nostdlib -o ${lib}-master.o $libobjs~$CC -dynamiclib $allow_undefined_flag -o $lib ${lib}-master.o $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
|
||||
fi
|
||||
_LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -bundle $allow_undefined_flag -o $lib $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
|
||||
if test "X$lt_int_apple_cc_single_mod" = Xyes ; then
|
||||
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -dynamiclib -single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
|
||||
else
|
||||
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -r ${wl}-bind_at_load -keep_private_externs -nostdlib -o ${lib}-master.o $libobjs~$CC -dynamiclib $allow_undefined_flag -o $lib ${lib}-master.o $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
|
||||
fi
|
||||
_LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
|
||||
_LT_AC_TAGVAR(hardcode_direct, $1)=no
|
||||
_LT_AC_TAGVAR(hardcode_automatic, $1)=yes
|
||||
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
|
||||
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)='-all_load $convenience'
|
||||
_LT_AC_TAGVAR(link_all_deplibs, $1)=yes
|
||||
fi
|
||||
else
|
||||
_LT_AC_TAGVAR(ld_shlibs, $1)=no
|
||||
fi
|
||||
;;
|
||||
|
||||
dgux*)
|
||||
@ -5328,7 +5327,7 @@ EOF
|
||||
;;
|
||||
|
||||
darwin* | rhapsody*)
|
||||
if $CC -v 2>&1 | grep 'Apple' >/dev/null ; then
|
||||
if test "$GXX" = yes ; then
|
||||
_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
|
||||
case "$host_os" in
|
||||
rhapsody* | darwin1.[[012]])
|
||||
@ -5338,10 +5337,6 @@ EOF
|
||||
test -z ${LD_TWOLEVEL_NAMESPACE} && _LT_AC_TAGVAR(allow_undefined_flag, $1)='-flat_namespace -undefined suppress'
|
||||
;;
|
||||
esac
|
||||
# FIXME: Relying on posixy $() will cause problems for
|
||||
# cross-compilation, but unfortunately the echo tests do not
|
||||
# yet detect zsh echo's removal of \ escapes. Also zsh mangles
|
||||
# `"' quotes if we put them in here... so don't!
|
||||
lt_int_apple_cc_single_mod=no
|
||||
output_verbose_link_cmd='echo'
|
||||
if $CC -dumpspecs 2>&1 | grep 'single_module' >/dev/null ; then
|
||||
@ -5352,19 +5347,21 @@ EOF
|
||||
else
|
||||
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -r ${wl}-bind_at_load -keep_private_externs -nostdlib -o ${lib}-master.o $libobjs~$CC -dynamiclib $allow_undefined_flag -o $lib ${lib}-master.o $deplibs $compiler_flags -install_name $rpath/$soname $verstring'
|
||||
fi
|
||||
_LT_AC_TAGVAR(module_cmds, $1)='$CC -bundle ${wl}-bind_at_load $allow_undefined_flag -o $lib $libobjs $deplibs$compiler_flags'
|
||||
_LT_AC_TAGVAR(module_cmds, $1)='$CC ${wl}-bind_at_load $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
|
||||
# Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin ld's
|
||||
if test "X$lt_int_apple_cc_single_mod" = Xyes ; then
|
||||
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -dynamiclib -single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
|
||||
else
|
||||
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -r ${wl}-bind_at_load -keep_private_externs -nostdlib -o ${lib}-master.o $libobjs~$CC -dynamiclib $allow_undefined_flag -o $lib ${lib}-master.o $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
|
||||
fi
|
||||
_LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -bundle $allow_undefined_flag -o $lib $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
|
||||
_LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
|
||||
_LT_AC_TAGVAR(hardcode_direct, $1)=no
|
||||
_LT_AC_TAGVAR(hardcode_automatic, $1)=yes
|
||||
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
|
||||
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)='-all_load $convenience'
|
||||
_LT_AC_TAGVAR(link_all_deplibs, $1)=yes
|
||||
else
|
||||
_LT_AC_TAGVAR(ld_shlibs, $1)=no
|
||||
fi
|
||||
;;
|
||||
|
||||
|
@ -2568,7 +2568,11 @@ EOF
|
||||
if test -f "$path/$depdepl" ; then
|
||||
depdepl="$path/$depdepl"
|
||||
fi
|
||||
newlib_search_path="$newlib_search_path $path"
|
||||
# do not add paths which are already there
|
||||
case " $newlib_search_path " in
|
||||
*" $path "*) ;;
|
||||
*) newlib_search_path="$newlib_search_path $path";;
|
||||
esac
|
||||
path=""
|
||||
fi
|
||||
;;
|
||||
|
Loading…
Reference in New Issue
Block a user