Changeset View
Changeset View
Standalone View
Standalone View
contrib/ldns/m4/libtool.m4
- This file is larger than 256 KB, so syntax highlighting is disabled by default.
Show First 20 Lines • Show All 1,035 Lines • ▼ Show 20 Lines | LDFLAGS=$save_LDFLAGS | ||||
AC_CACHE_CHECK([for -force_load linker flag],[lt_cv_ld_force_load], | AC_CACHE_CHECK([for -force_load linker flag],[lt_cv_ld_force_load], | ||||
[lt_cv_ld_force_load=no | [lt_cv_ld_force_load=no | ||||
cat > conftest.c << _LT_EOF | cat > conftest.c << _LT_EOF | ||||
int forced_loaded() { return 2;} | int forced_loaded() { return 2;} | ||||
_LT_EOF | _LT_EOF | ||||
echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&AS_MESSAGE_LOG_FD | echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&AS_MESSAGE_LOG_FD | ||||
$LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&AS_MESSAGE_LOG_FD | $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&AS_MESSAGE_LOG_FD | ||||
echo "$AR cru libconftest.a conftest.o" >&AS_MESSAGE_LOG_FD | echo "$AR cr libconftest.a conftest.o" >&AS_MESSAGE_LOG_FD | ||||
$AR cru libconftest.a conftest.o 2>&AS_MESSAGE_LOG_FD | $AR cr libconftest.a conftest.o 2>&AS_MESSAGE_LOG_FD | ||||
echo "$RANLIB libconftest.a" >&AS_MESSAGE_LOG_FD | echo "$RANLIB libconftest.a" >&AS_MESSAGE_LOG_FD | ||||
$RANLIB libconftest.a 2>&AS_MESSAGE_LOG_FD | $RANLIB libconftest.a 2>&AS_MESSAGE_LOG_FD | ||||
cat > conftest.c << _LT_EOF | cat > conftest.c << _LT_EOF | ||||
int main() { return 0;} | int main() { return 0;} | ||||
_LT_EOF | _LT_EOF | ||||
echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&AS_MESSAGE_LOG_FD | echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&AS_MESSAGE_LOG_FD | ||||
$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err | $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err | ||||
_lt_result=$? | _lt_result=$? | ||||
Show All 12 Lines | rhapsody* | darwin1.[[012]]) | ||||
_lt_dar_allow_undefined='$wl-undefined ${wl}suppress' ;; | _lt_dar_allow_undefined='$wl-undefined ${wl}suppress' ;; | ||||
darwin1.*) | darwin1.*) | ||||
_lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;; | _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;; | ||||
darwin*) # darwin 5.x on | darwin*) # darwin 5.x on | ||||
# if running on 10.5 or later, the deployment target defaults | # if running on 10.5 or later, the deployment target defaults | ||||
# to the OS version, if on x86, and 10.4, the deployment | # to the OS version, if on x86, and 10.4, the deployment | ||||
# target defaults to 10.4. Don't you love it? | # target defaults to 10.4. Don't you love it? | ||||
case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in | case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in | ||||
10.0,*86*-darwin8*|10.0,*-darwin[[91]]*) | 10.0,*86*-darwin8*|10.0,*-darwin[[912]]*) | ||||
_lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;; | _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;; | ||||
10.[[012]][[,.]]*) | 10.[[012]][[,.]]*) | ||||
_lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;; | _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;; | ||||
10.*) | 10.*|11.*) | ||||
_lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;; | _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;; | ||||
esac | esac | ||||
;; | ;; | ||||
esac | esac | ||||
if test yes = "$lt_cv_apple_cc_single_mod"; then | if test yes = "$lt_cv_apple_cc_single_mod"; then | ||||
_lt_dar_single_mod='$single_module' | _lt_dar_single_mod='$single_module' | ||||
fi | fi | ||||
if test yes = "$lt_cv_ld_exported_symbols_list"; then | if test yes = "$lt_cv_ld_exported_symbols_list"; then | ||||
▲ Show 20 Lines • Show All 400 Lines • ▼ Show 20 Lines | |||||
])# _LT_ENABLE_LOCK | ])# _LT_ENABLE_LOCK | ||||
# _LT_PROG_AR | # _LT_PROG_AR | ||||
# ----------- | # ----------- | ||||
m4_defun([_LT_PROG_AR], | m4_defun([_LT_PROG_AR], | ||||
[AC_CHECK_TOOLS(AR, [ar], false) | [AC_CHECK_TOOLS(AR, [ar], false) | ||||
: ${AR=ar} | : ${AR=ar} | ||||
: ${AR_FLAGS=cru} | : ${AR_FLAGS=cr} | ||||
_LT_DECL([], [AR], [1], [The archiver]) | _LT_DECL([], [AR], [1], [The archiver]) | ||||
_LT_DECL([], [AR_FLAGS], [1], [Flags to create an archive]) | _LT_DECL([], [AR_FLAGS], [1], [Flags to create an archive]) | ||||
AC_CACHE_CHECK([for archiver @FILE support], [lt_cv_ar_at_file], | AC_CACHE_CHECK([for archiver @FILE support], [lt_cv_ar_at_file], | ||||
[lt_cv_ar_at_file=no | [lt_cv_ar_at_file=no | ||||
AC_COMPILE_IFELSE([AC_LANG_PROGRAM], | AC_COMPILE_IFELSE([AC_LANG_PROGRAM], | ||||
[echo conftest.$ac_objext > conftest.lst | [echo conftest.$ac_objext > conftest.lst | ||||
lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&AS_MESSAGE_LOG_FD' | lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&AS_MESSAGE_LOG_FD' | ||||
▲ Show 20 Lines • Show All 2,554 Lines • ▼ Show 20 Lines | |||||
} | } | ||||
#endif | #endif | ||||
int main(){nm_test_var='a';nm_test_func();return(0);} | int main(){nm_test_var='a';nm_test_func();return(0);} | ||||
_LT_EOF | _LT_EOF | ||||
if AC_TRY_EVAL(ac_compile); then | if AC_TRY_EVAL(ac_compile); then | ||||
# Now try to grab the symbols. | # Now try to grab the symbols. | ||||
nlist=conftest.nm | nlist=conftest.nm | ||||
if AC_TRY_EVAL(NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) && test -s "$nlist"; then | $ECHO "$as_me:$LINENO: $NM conftest.$ac_objext | $lt_cv_sys_global_symbol_pipe > $nlist" >&AS_MESSAGE_LOG_FD | ||||
if eval "$NM" conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist 2>&AS_MESSAGE_LOG_FD && test -s "$nlist"; then | |||||
# Try sorting and uniquifying the output. | # Try sorting and uniquifying the output. | ||||
if sort "$nlist" | uniq > "$nlist"T; then | if sort "$nlist" | uniq > "$nlist"T; then | ||||
mv -f "$nlist"T "$nlist" | mv -f "$nlist"T "$nlist" | ||||
else | else | ||||
rm -f "$nlist"T | rm -f "$nlist"T | ||||
fi | fi | ||||
# Make sure that we snagged all the symbols we need. | # Make sure that we snagged all the symbols we need. | ||||
▲ Show 20 Lines • Show All 621 Lines • ▼ Show 20 Lines | irix5* | irix6* | nonstopux*) | ||||
;; | ;; | ||||
linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) | linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) | ||||
case $cc_basename in | case $cc_basename in | ||||
# old Intel for x86_64, which still supported -KPIC. | # old Intel for x86_64, which still supported -KPIC. | ||||
ecc*) | ecc*) | ||||
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' | _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' | ||||
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' | _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' | ||||
_LT_TAGVAR(lt_prog_compiler_static, $1)='-static' | |||||
;; | |||||
# flang / f18. f95 an alias for gfortran or flang on Debian | |||||
flang* | f18* | f95*) | |||||
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' | |||||
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' | |||||
_LT_TAGVAR(lt_prog_compiler_static, $1)='-static' | _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' | ||||
;; | ;; | ||||
# icc used to be incompatible with GCC. | # icc used to be incompatible with GCC. | ||||
# ICC 10 doesn't accept -KPIC any more. | # ICC 10 doesn't accept -KPIC any more. | ||||
icc* | ifort*) | icc* | ifort*) | ||||
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' | _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' | ||||
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' | _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' | ||||
_LT_TAGVAR(lt_prog_compiler_static, $1)='-static' | _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' | ||||
▲ Show 20 Lines • Show All 1,721 Lines • ▼ Show 20 Lines | $GREP 'no-whole-archive' > /dev/null; then | ||||
# overridden to take advantage of the native linker features on | # overridden to take advantage of the native linker features on | ||||
# the platform it is being used on. | # the platform it is being used on. | ||||
_LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' | _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' | ||||
fi | fi | ||||
# Commands to make compiler produce verbose output that lists | # Commands to make compiler produce verbose output that lists | ||||
# what "hidden" libraries, object files and flags are used when | # what "hidden" libraries, object files and flags are used when | ||||
# linking a shared library. | # linking a shared library. | ||||
output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' | output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP " \-L"' | ||||
else | else | ||||
GXX=no | GXX=no | ||||
with_gnu_ld=no | with_gnu_ld=no | ||||
wlarc= | wlarc= | ||||
fi | fi | ||||
# PORTME: fill in a description of your system's C++ link characteristics | # PORTME: fill in a description of your system's C++ link characteristics | ||||
▲ Show 20 Lines • Show All 358 Lines • ▼ Show 20 Lines | # switch to ELF | ||||
# Commands to make compiler produce verbose output that lists | # Commands to make compiler produce verbose output that lists | ||||
# what "hidden" libraries, object files and flags are used when | # what "hidden" libraries, object files and flags are used when | ||||
# linking a shared library. | # linking a shared library. | ||||
# | # | ||||
# There doesn't appear to be a way to prevent this compiler from | # There doesn't appear to be a way to prevent this compiler from | ||||
# explicitly linking system object files so we need to strip them | # explicitly linking system object files so we need to strip them | ||||
# from the output so that they don't get included in the library | # from the output so that they don't get included in the library | ||||
# dependencies. | # dependencies. | ||||
output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP "\-L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' | output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP " \-L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' | ||||
;; | ;; | ||||
*) | *) | ||||
if test yes = "$GXX"; then | if test yes = "$GXX"; then | ||||
_LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared -nostdlib $pic_flag $wl+b $wl$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' | _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared -nostdlib $pic_flag $wl+b $wl$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' | ||||
else | else | ||||
# FIXME: insert proper C++ library support | # FIXME: insert proper C++ library support | ||||
_LT_TAGVAR(ld_shlibs, $1)=no | _LT_TAGVAR(ld_shlibs, $1)=no | ||||
fi | fi | ||||
▲ Show 20 Lines • Show All 48 Lines • ▼ Show 20 Lines | _LT_TAGVAR(hardcode_libdir_separator, $1)=: | ||||
# Commands to make compiler produce verbose output that lists | # Commands to make compiler produce verbose output that lists | ||||
# what "hidden" libraries, object files and flags are used when | # what "hidden" libraries, object files and flags are used when | ||||
# linking a shared library. | # linking a shared library. | ||||
# | # | ||||
# There doesn't appear to be a way to prevent this compiler from | # There doesn't appear to be a way to prevent this compiler from | ||||
# explicitly linking system object files so we need to strip them | # explicitly linking system object files so we need to strip them | ||||
# from the output so that they don't get included in the library | # from the output so that they don't get included in the library | ||||
# dependencies. | # dependencies. | ||||
output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP "\-L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' | output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP " \-L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' | ||||
;; | ;; | ||||
*) | *) | ||||
if test yes = "$GXX"; then | if test yes = "$GXX"; then | ||||
if test no = "$with_gnu_ld"; then | if test no = "$with_gnu_ld"; then | ||||
case $host_cpu in | case $host_cpu in | ||||
hppa*64*) | hppa*64*) | ||||
_LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC $wl+h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' | _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC $wl+h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' | ||||
;; | ;; | ||||
▲ Show 20 Lines • Show All 322 Lines • ▼ Show 20 Lines | *) | ||||
esac | esac | ||||
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' | _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' | ||||
_LT_TAGVAR(hardcode_libdir_separator, $1)=: | _LT_TAGVAR(hardcode_libdir_separator, $1)=: | ||||
# Commands to make compiler produce verbose output that lists | # Commands to make compiler produce verbose output that lists | ||||
# what "hidden" libraries, object files and flags are used when | # what "hidden" libraries, object files and flags are used when | ||||
# linking a shared library. | # linking a shared library. | ||||
output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' | output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP " \-L"' | ||||
else | else | ||||
# FIXME: insert proper C++ library support | # FIXME: insert proper C++ library support | ||||
_LT_TAGVAR(ld_shlibs, $1)=no | _LT_TAGVAR(ld_shlibs, $1)=no | ||||
fi | fi | ||||
;; | ;; | ||||
esac | esac | ||||
;; | ;; | ||||
▲ Show 20 Lines • Show All 67 Lines • ▼ Show 20 Lines | _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' | ||||
if $CC --version | $GREP -v '^2\.7' > /dev/null; then | if $CC --version | $GREP -v '^2\.7' > /dev/null; then | ||||
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib' | _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib' | ||||
_LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ | _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 $pic_flag -nostdlib $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' | $CC -shared $pic_flag -nostdlib $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' | ||||
# Commands to make compiler produce verbose output that lists | # Commands to make compiler produce verbose output that lists | ||||
# what "hidden" libraries, object files and flags are used when | # what "hidden" libraries, object files and flags are used when | ||||
# linking a shared library. | # linking a shared library. | ||||
output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' | output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP " \-L"' | ||||
else | else | ||||
# g++ 2.7 appears to require '-G' NOT '-shared' on this | # g++ 2.7 appears to require '-G' NOT '-shared' on this | ||||
# platform. | # platform. | ||||
_LT_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib' | _LT_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib' | ||||
_LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ | _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ | ||||
$CC -G -nostdlib $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' | $CC -G -nostdlib $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' | ||||
# Commands to make compiler produce verbose output that lists | # Commands to make compiler produce verbose output that lists | ||||
# what "hidden" libraries, object files and flags are used when | # what "hidden" libraries, object files and flags are used when | ||||
# linking a shared library. | # linking a shared library. | ||||
output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' | output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP " \-L"' | ||||
fi | fi | ||||
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R $wl$libdir' | _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R $wl$libdir' | ||||
case $host_os in | case $host_os in | ||||
solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; | solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; | ||||
*) | *) | ||||
_LT_TAGVAR(whole_archive_flag_spec, $1)='$wl-z ${wl}allextract$convenience $wl-z ${wl}defaultextract' | _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl-z ${wl}allextract$convenience $wl-z ${wl}defaultextract' | ||||
;; | ;; | ||||
▲ Show 20 Lines • Show All 1,064 Lines • Show Last 20 Lines |