From: Gary V. Vaughan Date: Fri, 29 Sep 2000 21:06:27 +0000 (+0000) Subject: * libtool.m4 (MAGIC_CMD): Don't use MAGIC, since BSD versions of X-Git-Tag: multi-language-merge-point~131 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=0c61b6ba043fb61a776ef7b146ca4e5604ab37f8;p=thirdparty%2Flibtool.git * libtool.m4 (MAGIC_CMD): Don't use MAGIC, since BSD versions of the file command use this environment variable to hold the location of the magic database. * ltconfig.in (MAGIC_CMD): ditto. Reported by Marc Espie --- diff --git a/ChangeLog b/ChangeLog index a4c173e1a..64383716d 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,11 @@ +2000-09-28 Gary V. Vaughan + + * libtool.m4 (MAGIC_CMD): Don't use MAGIC, since BSD versions of + the file command use this environment variable to hold the + location of the magic database. + * ltconfig.in (MAGIC_CMD): ditto. + Reported by Marc Espie + 2000-09-20 Ossama Othman * ltconfig.in (lt_cv_dlopen_self, lt_cv_dlopen_self_static): Use diff --git a/libtool.m4 b/libtool.m4 index 02b09ea71..f5405d5b7 100644 --- a/libtool.m4 +++ b/libtool.m4 @@ -59,7 +59,7 @@ AC_CACHE_SAVE # Actually configure libtool. ac_aux_dir is where install-sh is found. AR="$AR" LTCC="$CC" CC="$CC" CFLAGS="$CFLAGS" CPPFLAGS="$CPPFLAGS" \ -MAGIC="$MAGIC" LD="$LD" LDFLAGS="$LDFLAGS" LIBS="$LIBS" \ +MAGIC_CMD="$MAGIC_CMD" LD="$LD" LDFLAGS="$LDFLAGS" LIBS="$LIBS" \ LN_S="$LN_S" NM="$NM" RANLIB="$RANLIB" STRIP="$STRIP" \ AS="$AS" DLLTOOL="$DLLTOOL" OBJDUMP="$OBJDUMP" \ objext="$OBJEXT" exeext="$EXEEXT" reload_flag="$reload_flag" \ @@ -104,7 +104,7 @@ dnl # Only perform the check for file, if the check method requires it case "$deplibs_check_method" in file_magic*) - if test "$file_magic_cmd" = '${MAGIC}'; then + if test "$file_magic_cmd" = '${MAGIC_CMD}'; then AC_PATH_MAGIC fi ;; @@ -322,16 +322,16 @@ pic_mode=ifelse($#,1,$1,default)]) # AC_PATH_TOOL_PREFIX - find a file program which can recognise shared library AC_DEFUN(AC_PATH_TOOL_PREFIX, [AC_MSG_CHECKING([for $1]) -AC_CACHE_VAL(lt_cv_path_MAGIC, -[case "$MAGIC" in +AC_CACHE_VAL(lt_cv_path_MAGIC_CMD, +[case "$MAGIC_CMD" in /*) - lt_cv_path_MAGIC="$MAGIC" # Let the user override the test with a path. + lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. ;; ?:/*) - ac_cv_path_MAGIC="$MAGIC" # Let the user override the test with a dos path. + ac_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a dos path. ;; *) - ac_save_MAGIC="$MAGIC" + ac_save_MAGIC_CMD="$MAGIC_CMD" IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" dnl $ac_dummy forces splitting on constant user-supplied paths. dnl POSIX.2 word splitting is done only on the output of word expansions, @@ -340,12 +340,12 @@ dnl not every word. This closes a longstanding sh security hole. for ac_dir in $ac_dummy; do test -z "$ac_dir" && ac_dir=. if test -f $ac_dir/$1; then - lt_cv_path_MAGIC="$ac_dir/$1" + lt_cv_path_MAGIC_CMD="$ac_dir/$1" if test -n "$file_magic_test_file"; then case "$deplibs_check_method" in "file_magic "*) file_magic_regex="`expr \"$deplibs_check_method\" : \"file_magic \(.*\)\"`" - MAGIC="$lt_cv_path_MAGIC" + MAGIC_CMD="$lt_cv_path_MAGIC_CMD" if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | egrep "$file_magic_regex" > /dev/null; then : @@ -369,12 +369,12 @@ EOF fi done IFS="$ac_save_ifs" - MAGIC="$ac_save_MAGIC" + MAGIC_CMD="$ac_save_MAGIC_CMD" ;; esac]) -MAGIC="$lt_cv_path_MAGIC" -if test -n "$MAGIC"; then - AC_MSG_RESULT($MAGIC) +MAGIC_CMD="$lt_cv_path_MAGIC_CMD" +if test -n "$MAGIC_CMD"; then + AC_MSG_RESULT($MAGIC_CMD) else AC_MSG_RESULT(no) fi @@ -385,11 +385,11 @@ fi AC_DEFUN(AC_PATH_MAGIC, [AC_REQUIRE([AC_CHECK_TOOL_PREFIX])dnl AC_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin:$PATH) -if test -z "$lt_cv_path_MAGIC"; then +if test -z "$lt_cv_path_MAGIC_CMD"; then if test -n "$ac_tool_prefix"; then AC_PATH_TOOL_PREFIX(file, /usr/bin:$PATH) else - MAGIC=: + MAGIC_CMD=: fi fi ]) @@ -497,7 +497,7 @@ test -n "$reload_flag" && reload_flag=" $reload_flag" AC_DEFUN(AC_DEPLIBS_CHECK_METHOD, [AC_CACHE_CHECK([how to recognise dependant libraries], lt_cv_deplibs_check_method, -[lt_cv_file_magic_cmd='${MAGIC}' +[lt_cv_file_magic_cmd='${MAGIC_CMD}' lt_cv_file_magic_test_file= lt_cv_deplibs_check_method='unknown' # Need to set the preceding variable on all platforms that support @@ -770,7 +770,7 @@ lt_save_CFLAGS="$CFLAGS" dnl Make sure LTCC is set to the C compiler, i.e. set LTCC before CC dnl is set to the C++ compiler. AR="$AR" LTCC="$CC" CC="$CXX" CXX="$CXX" CFLAGS="$CXXFLAGS" CPPFLAGS="$CPPFLAGS" \ -MAGIC="$MAGIC" LDFLAGS="$LDFLAGS" LIBS="$LIBS" \ +MAGIC_CMD="$MAGIC_CMD" LDFLAGS="$LDFLAGS" LIBS="$LIBS" \ LN_S="$LN_S" NM="$NM" RANLIB="$RANLIB" STRIP="$STRIP" \ AS="$AS" DLLTOOL="$DLLTOOL" OBJDUMP="$OBJDUMP" \ objext="$OBJEXT" exeext="$EXEEXT" reload_flag="$reload_flag" \ @@ -803,7 +803,7 @@ lt_save_CFLAGS="$CFLAGS" dnl Make sure LTCC is set to the C compiler, i.e. set LTCC before CC dnl is set to the C++ compiler. AR="$AR" LTCC="$CC" CC="$GCJ" CFLAGS="$GCJFLAGS" CPPFLAGS="" \ -MAGIC="$MAGIC" LDFLAGS="$LDFLAGS" LIBS="$LIBS" \ +MAGIC_CMD="$MAGIC_CMD" LDFLAGS="$LDFLAGS" LIBS="$LIBS" \ LN_S="$LN_S" NM="$NM" RANLIB="$RANLIB" STRIP="$STRIP" \ AS="$AS" DLLTOOL="$DLLTOOL" OBJDUMP="$OBJDUMP" \ objext="$OBJEXT" exeext="$EXEEXT" reload_flag="$reload_flag" \ diff --git a/ltconfig.in b/ltconfig.in index 94123e4e7..d7eaeade9 100755 --- a/ltconfig.in +++ b/ltconfig.in @@ -273,7 +273,7 @@ old_CFLAGS="$CFLAGS" old_CPPFLAGS="$CPPFLAGS" old_LDFLAGS="$LDFLAGS" old_LIBS="$LIBS" -old_MAGIC="$MAGIC" +old_MAGIC_CMD="$MAGIC_CMD" old_LD="$LD" old_LN_S="$LN_S" old_LTCC="$LTCC" @@ -640,7 +640,7 @@ test -z "$AR_FLAGS" && AR_FLAGS=cru test -z "$AS" && AS=as test -z "$CC" && CC=cc test -z "$DLLTOOL" && DLLTOOL=dlltool -test -z "$MAGIC" && MAGIC=file +test -z "$MAGIC_CMD" && MAGIC_CMD=file test -z "$LD" && LD=ld test -z "$LN_S" && LN_S="ln -s" test -z "$NM" && NM=nm @@ -1960,7 +1960,7 @@ case "$ltmain" in *.sh) # Now quote all the things that may contain metacharacters. for var in ltecho old_AR old_AR_FLAGS old_CC old_LTCC old_CFLAGS old_CPPFLAGS \ - old_MAGIC old_LD old_LDFLAGS old_LIBS \ + old_MAGIC_CMD old_LD old_LDFLAGS old_LIBS \ old_LN_S old_NM old_RANLIB old_STRIP \ old_AS old_DLLTOOL old_OBJDUMP \ old_OBJEXT old_EXEEXT old_reload_flag \ @@ -2058,7 +2058,7 @@ EOF *) # Double-quote the variables that need it (for aesthetics). for var in old_AR old_AR_FLAGS old_CC old_LTCC old_CFLAGS old_CPPFLAGS \ - old_MAGIC old_LD old_LDFLAGS old_LIBS \ + old_MAGIC_CMD old_LD old_LDFLAGS old_LIBS \ old_LN_S old_NM old_RANLIB old_STRIP \ old_AS old_DLLTOOL old_OBJDUMP \ old_OBJEXT old_EXEEXT old_reload_flag \ @@ -2090,7 +2090,7 @@ cat <> "$cfgfile" # # AR=$old_AR AR_FLAGS=$old_AR_FLAGS LTCC=$old_LTCC CC=$old_CC \\ # CFLAGS=$old_CFLAGS CPPFLAGS=$old_CPPFLAGS \\ -# MAGIC=$old_MAGIC LD=$old_LD LDFLAGS=$old_LDFLAGS LIBS=$old_LIBS \\ +# MAGIC_CMD=$old_MAGIC_CMD LD=$old_LD LDFLAGS=$old_LDFLAGS LIBS=$old_LIBS \\ # LN_S=$old_LN_S NM=$old_NM RANLIB=$old_RANLIB STRIP=$old_STRIP \\ # AS=$old_AS DLLTOOL=$old_DLLTOOL OBJDUMP=$old_OBJDUMP \\ # objext=$old_OBJEXT exeext=$old_EXEEXT reload_flag=$old_reload_flag \\ @@ -2152,7 +2152,7 @@ NM=$NM STRIP=$STRIP # Used to examine libraries when file_magic_cmd begins "file" -MAGIC=$MAGIC +MAGIC_CMD=$MAGIC_CMD # Used on cygwin: DLL creation program. DLLTOOL="$DLLTOOL"