From: Alexandre Oliva Date: Fri, 3 Dec 1999 02:57:29 +0000 (+0000) Subject: * libtool.m4: Use host when --target is not specified. X-Git-Tag: multi-language-fork~2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=5c216918b1129b379abf385f6be49620b43a5f21;p=thirdparty%2Flibtool.git * libtool.m4: Use host when --target is not specified. --- diff --git a/ChangeLog b/ChangeLog index 6927c448f..096044c0d 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,7 @@ 1999-12-03 Alexandre Oliva + * libtool.m4: Use host when --target is not specified. + * configure.in: AC_SUBST variables that are used by ltconfig to build libtool. diff --git a/libtool.m4 b/libtool.m4 index 714304a0c..cf4c53909 100644 --- a/libtool.m4 +++ b/libtool.m4 @@ -36,7 +36,7 @@ AS="$AS" DLLTOOL="$DLLTOOL" OBJDUMP="$OBJDUMP" \ objext="$OBJEXT" exeext="$EXEEXT" reload_flag="$reload_flag" \ deplibs_check_method="$deplibs_check_method" file_magic_cmd="$file_magic_cmd" \ ${CONFIG_SHELL-/bin/sh} $ac_aux_dir/ltconfig --no-reexec \ -$libtool_flags --no-verify --build="$build" $ac_aux_dir/ltmain.sh $target \ +$libtool_flags --no-verify --build="$build" $ac_aux_dir/ltmain.sh $lt_target \ || AC_MSG_ERROR([libtool configure failed]) # Reload cache, that may have been modified by ltconfig @@ -80,6 +80,11 @@ file_magic*) ;; esac +case "$target" in +NONE) lt_target="$host" ;; +*) lt_target="$target" ;; +esac + AC_CHECK_TOOL(RANLIB, ranlib, :) AC_CHECK_TOOL(STRIP, strip, :) @@ -107,7 +112,7 @@ test x"$pic_mode" = xno && libtool_flags="$libtool_flags --prefer-non-pic" # Some flags need to be propagated to the compiler or linker for good # libtool support. -case "$target" in +case "$lt_target" in *-*-irix6*) # Find out which ABI we are using. echo '[#]line __oline__ "configure"' > conftest.$ac_ext @@ -153,7 +158,7 @@ ifdef([AC_PROVIDE_AC_LIBTOOL_WIN32_DLL], DllMain (0, 0, 0);], [lt_cv_need_dllmain=yes],[lt_cv_need_dllmain=no])]) - case "$target/$CC" in + case "$lt_target/$CC" in *-*-cygwin*/gcc*-mno-cygwin*|*-*-mingw*) # old mingw systems require "-dll" to link a DLL, while more recent ones # require "-mdll" @@ -367,7 +372,7 @@ ac_prog=ld if test "$ac_cv_prog_gcc" = yes; then # Check if gcc -print-prog-name=ld gives a path. AC_MSG_CHECKING([for ld used by GCC]) - case $target in + case $lt_target in *-*-mingw*) # gcc leaves a trailing carriage return which upsets mingw ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; @@ -603,7 +608,7 @@ AC_MSG_RESULT([$NM]) AC_DEFUN(AC_CHECK_LIBM, [AC_REQUIRE([AC_CANONICAL_HOST])dnl LIBM= -case "$target" in +case "$lt_target" in *-*-beos* | *-*-cygwin*) # These system don't have libm ;;