[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
libtool support for hosts with strict "grep", "test"
From: |
Paul Eggert |
Subject: |
libtool support for hosts with strict "grep", "test" |
Date: |
Wed, 23 Oct 2002 23:23:35 -0700 (PDT) |
I ran my POSIX 1003.1-2001 checker over CVS libtool and found the
following portability problems for libtool that will become evident
when libtool is run on strict POSIX 1003.1-2001 hosts. POSIX
1003.1-2001 has removed "egrep" and "fgrep" from the spec, and also it
says that "test FOO -a BAR" is not required to be supported. Portable
programs are supposed to use "grep -E", "grep -F", and "test FOO &&
test BAR".
I sent in a similar patch (for egrep and fgrep only) a while ago, in
<http://mail.gnu.org/pipermail/bug-libtool/2002-May/003656.html>, but
quite possibly that patch got lost amid all the spam that was on the
list at the time.
2002-10-23 Paul Eggert <address@hidden>
Don't assume that egrep and fgrep exist. POSIX 1003.1-2001 no
longer requires them; you're supposed to use grep -E and grep -F
instead. Also, don't assume that "test -a" works, since POSIX
doesn't require it.
* libtool.m4 (AC_LIBTOOL_SYS_DYNAMIC_LINKER, _LT_AC_LANG_C_CONFIG,
_LT_AC_LANG_CXX_CONFIG, AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE,
AC_LIBTOOL_PROG_LD_SHLIBS):
egrep -> grep, when that makes no difference.
* libtoolize.in: Likewise.
* ltdl.m4 (AC_LTDL_SYMBOL_USCORE): Likewise.
* ltmain.in: Likewise.
* demo/Makefile.am (hc-direct): Likewise.
* pdemo/Makefile.am (hc-direct): Likewise.
* tests/build-relink.test, tests/build-relink2.test,
tests/cdemo-conf.test, tests/cdemo-shared.test,
tests/cdemo-static.test, tests/demo-conf.test,
tests/demo-nofast.test, tests/demo-shared.test,
tests/demo-static.test, tests/depdemo-conf.test,
tests/depdemo-nofast.test, tests/depdemo-shared.test,
tests/depdemo-static.test, tests/hardcode.test,
tests/mdemo-conf.test, tests/mdemo-shared.test,
tests/mdemo-static.test, tests/pdemo-conf.test,
tests/tagdemo-conf.test, tests/tagdemo-shared.test,
tests/tagdemo-static.test: Likewise.
* libtool.m4 (AC_PROG_EGREP):
New macro, defined if Autoconf doesn't define.
(AC_PATH_TOOL_PREFIX, AC_PROG_LD_GNU): Use it.
(AC_PROG_LD, AC_PROG_NM, AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE):
Use shell pattern matching rather than egrep.
(AC_LIBTOOL_CONFIG): Set lt_EGREP and EGREP.
* demo/Makefile.am (SET_HARDCODE_FLAGS): Use sed instead of egrep.
* pdemo/Makefile.am (SET_HARDCODE_FLAGS): Likewise.
* tests/defs (EGREP, FGREP): New vars.
* ltmain.in: egrep -> $EGREP
* tests/assign.test, tests/demo-exec.test, tests/demo-inst.test,
tests/pdemo-exec.test, tests/pdemo-inst.test, tests/sh.test:
Likewise.
* tests/hardcode.test: fgrep -> $FGREP
* tests/f77demo-exec.test: test -a -> test &&
Index: libtool.m4
===================================================================
RCS file: /cvsroot/libtool/libtool/libtool.m4,v
retrieving revision 1.270
diff -p -u -r1.270 libtool.m4
--- libtool.m4 24 Oct 2002 03:42:54 -0000 1.270
+++ libtool.m4 24 Oct 2002 06:06:36 -0000
@@ -1027,7 +1027,7 @@ dynamic_linker="$host_os ld.so"
sys_lib_dlsearch_path_spec="/lib /usr/lib"
if test "$GCC" = yes; then
sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | sed
-e "s/^libraries://" -e "s,=/,/,g"`
- if echo "$sys_lib_search_path_spec" | egrep ';' >/dev/null ; then
+ if echo "$sys_lib_search_path_spec" | grep ';' >/dev/null ; then
# if the path contains ";" then we assume it to be the separator
# otherwise default to the standard path separator (i.e. ":") - it is
# assumed that no part of a normal pathname contains ";" but that should
@@ -1155,7 +1155,7 @@ cygwin* | mingw* | pw32*)
# MinGW DLLs use traditional 'lib' prefix
soname_spec='${libname}`echo ${release} | sed -e
's/[[.]]/-/g'`${versuffix}.dll'
sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" |
sed -e "s/^libraries://" -e "s,=/,/,g"`
- if echo "$sys_lib_search_path_spec" | [egrep ';[c-zC-Z]:/' >/dev/null];
then
+ if echo "$sys_lib_search_path_spec" | [grep ';[c-zC-Z]:/' >/dev/null];
then
# It is most probably a Windows format PATH printed by
# mingw gcc, but we are running on Cygwin. Gcc prints its search
# path with ; separators, and with drive letters. We can handle the
@@ -1721,11 +1721,27 @@ pic_mode=ifelse($#,1,$1,default)
])# AC_LIBTOOL_PICMODE
+# AC_PROG_EGREP
+# -------------
+# This is predefined starting with Autoconf 2.54, so this conditional
+# definition can be removed once we require Autoconf 2.54 or later.
+m4_ifndef([AC_PROG_EGREP], [AC_DEFUN([AC_PROG_EGREP],
+[AC_CACHE_CHECK([for egrep], [ac_cv_prog_egrep],
+ [if echo a | (grep -E '(a|b)') >/dev/null 2>&1
+ then ac_cv_prog_egrep='grep -E'
+ else ac_cv_prog_egrep='egrep'
+ fi])
+ EGREP=$ac_cv_prog_egrep
+ AC_SUBST([EGREP])
+])])
+
+
# 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_REQUIRE([AC_PROG_EGREP])dnl
+AC_MSG_CHECKING([for $1])
AC_CACHE_VAL(lt_cv_path_MAGIC_CMD,
[case $MAGIC_CMD in
[[\\/*] | ?:[\\/]*])
@@ -1749,7 +1765,7 @@ dnl not every word. This closes a longs
file_magic_regex="`expr \"$deplibs_check_method\" : \"file_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
+ $EGREP "$file_magic_regex" > /dev/null; then
:
else
cat <<EOF 1>&2
@@ -1857,11 +1873,14 @@ AC_CACHE_VAL(lt_cv_path_LD,
# Check to see if the program is GNU ld. I'd rather use --version,
# but apparently some GNU ld's only accept -v.
# Break only if it was the GNU/non-GNU ld that we prefer.
- if "$lt_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' >
/dev/null; then
+ case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
+ *GNU* | *'with BFD'*)
test "$with_gnu_ld" != no && break
- else
+ ;;
+ *)
test "$with_gnu_ld" != yes && break
- fi
+ ;;
+ esac
fi
done
IFS="$lt_save_ifs"
@@ -1882,9 +1901,10 @@ AC_PROG_LD_GNU
# AC_PROG_LD_GNU
# --------------
AC_DEFUN([AC_PROG_LD_GNU],
-[AC_CACHE_CHECK([if the linker ($LD) is GNU ld], lt_cv_prog_gnu_ld,
+[AC_REQUIRE([AC_PROG_EGREP])dnl
+AC_CACHE_CHECK([if the linker ($LD) is GNU ld], lt_cv_prog_gnu_ld,
[# I'd rather use --version here, but apparently some GNU ld's only accept -v.
-if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then
+if $LD -v 2>&1 </dev/null | $EGREP '(GNU|with BFD)' 1>&5; then
lt_cv_prog_gnu_ld=yes
else
lt_cv_prog_gnu_ld=no
@@ -1927,7 +1947,7 @@ lt_cv_deplibs_check_method='unknown'
# 'pass_all' -- all dependencies passed with no checks.
# 'test_compile' -- check by making test program.
# 'file_magic [[regex]]' -- check by looking for files in library path
-# which responds to the $file_magic_cmd with a given egrep regex.
+# which responds to the $file_magic_cmd with a given extended regex.
# If you have `file' or equivalent on your system and you're not sure
# whether `pass_all' will *always* work, you probably want this one.
@@ -2126,16 +2146,23 @@ else
# Adding the `sed 1q' prevents false positives on HP-UX, which says:
# nm: unknown option "B" ignored
# Tru64's nm complains that /dev/null is an invalid object file
- if ("$tmp_nm" -B /dev/null 2>&1 | sed '1q'; exit 0) | egrep
'(/dev/null|Invalid file or object type)' >/dev/null; then
+ case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in
+ */dev/null* | *'Invalid file or object type'*)
lt_cv_path_NM="$tmp_nm -B"
break
- elif ("$tmp_nm" -p /dev/null 2>&1 | sed '1q'; exit 0) | egrep /dev/null
>/dev/null; then
- lt_cv_path_NM="$tmp_nm -p"
- break
- else
- lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
- continue # so that we can try to find one that supports BSD flags
- fi
+ ;;
+ *)
+ case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
+ */dev/null*)
+ lt_cv_path_NM="$tmp_nm -p"
+ break
+ ;;
+ *)
+ lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
+ continue # so that we can try to find one that supports BSD flags
+ ;;
+ esac
+ esac
fi
done
IFS="$lt_save_ifs"
@@ -2328,7 +2355,7 @@ if test "$GCC" = no; then
fi
if test -n "$_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)"; then
AC_MSG_WARN([`$CC' requires `$_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)' to build
shared libraries])
- if echo "$old_CC $old_CFLAGS " | egrep -e "[[
]]$]_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)[[[ ]]" >/dev/null; then :
+ if echo "$old_CC $old_CFLAGS " | grep "[[
]]$]_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)[[[ ]]" >/dev/null; then :
else
AC_MSG_WARN([add `$_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)' to the CC or
CFLAGS env variable and reconfigure])
_LT_AC_TAGVAR(lt_cv_prog_cc_can_build_shared, $1)=no
@@ -2468,7 +2495,7 @@ if test "$GXX" = yes; then
# Check if GNU C++ uses GNU ld as the underlying linker, since the
# archiving commands below assume that GNU ld is being used.
if eval "`$CC -print-prog-name=ld` --version 2>&1" | \
- egrep 'GNU ld' > /dev/null; then
+ grep 'GNU ld' > /dev/null; then
with_gnu_ld=yes
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects
$libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o
$lib'
@@ -2484,7 +2511,7 @@ if test "$GXX" = yes; then
# ancient GNU ld didn't support --whole-archive et. al.
if eval "`$CC -print-prog-name=ld` --help 2>&1" | \
- egrep 'no-whole-archive' > /dev/null; then
+ grep 'no-whole-archive' > /dev/null; then
_LT_AC_TAGVAR(whole_archive_flag_spec,
$1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
else
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
@@ -2504,7 +2531,7 @@ if test "$GXX" = yes; then
# Commands to make compiler produce verbose output that lists
# what "hidden" libraries, object files and flags are used when
# linking a shared library.
- output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 |
egrep "\-L"'
+ output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep
"\-L"'
else
GXX=no
@@ -2644,7 +2671,7 @@ case $host_os in
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
_LT_AC_TAGVAR(always_export_symbols, $1)=no
- if $LD --help 2>&1 | egrep 'auto-import' > /dev/null; then
+ if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects
$libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname
${wl}--image-base=0x10000000 ${wl}--out-implib,$lib'
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared -nostdlib
$predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o
$output_objdir/$soname ${wl}-retain-symbols-file $wl$export_symbols
${wl}--out-implib,$lib'
else
@@ -2656,7 +2683,7 @@ case $host_os in
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
_LT_AC_TAGVAR(always_export_symbols, $1)=no
- if $LD --help 2>&1 | egrep 'auto-import' > /dev/null; then
+ if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then
_LT_AC_TAGVAR(archive_cmds, $1)='$CC '$lt_cv_cc_dll_switch' $libobjs
$deplibs $compiler_flags -o $output_objdir/$soname ${wl}--out-implib,${lib}'
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC '$lt_cv_cc_dll_switch'
$libobjs $deplibs $compiler_flags -o $output_objdir/$soname
${wl}-retain-symbols-file $wl$export_symbols ${wl}--out-implib,${lib}'
else
@@ -2741,7 +2768,7 @@ case $host_os in
# explicitly linking system object files so we need to strip them
# from the output so that they don't get included in the library
# 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; echo $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; echo $list'
;;
*)
if test "$GXX" = yes; then
@@ -2811,7 +2838,7 @@ case $host_os in
# explicitly linking system object files so we need to strip them
# from the output so that they don't get included in the library
# dependencies.
- output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o
libconftest.so 2>&1 | egrep "ld"`; rm -f libconftest.so; list=""; for z in
$templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *)
list="$list $z";;esac; done; echo $list'
+ output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o
libconftest.so 2>&1 | grep "ld"`; rm -f libconftest.so; list=""; for z in
$templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *)
list="$list $z";;esac; done; echo $list'
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath,$libdir'
_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
@@ -2870,7 +2897,7 @@ case $host_os in
_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
fi
# Workaround some broken pre-1.5 toolchains
- output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 |
egrep conftest.$objext | sed -e "s:-lgcc -lc -lgcc::"'
+ output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 |
grep conftest.$objext | sed -e "s:-lgcc -lc -lgcc::"'
;;
osf3*)
case $cc_basename in
@@ -2923,7 +2950,7 @@ case $host_os in
# Commands to make compiler produce verbose output that lists
# what "hidden" libraries, object files and flags are used when
# linking a shared library.
- output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1
| egrep "\-L"'
+ output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1
| grep "\-L"'
else
# FIXME: insert proper C++ library support
@@ -2986,7 +3013,7 @@ case $host_os in
# Commands to make compiler produce verbose output that lists
# what "hidden" libraries, object files and flags are used when
# linking a shared library.
- output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1
| egrep "\-L"'
+ output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1
| grep "\-L"'
else
# FIXME: insert proper C++ library support
@@ -3061,7 +3088,7 @@ case $host_os in
# explicitly linking system object files so we need to strip them
# from the output so that they don't get included in the library
# dependencies.
- output_verbose_link_cmd='templist=`$CC -G $CFLAGS -v conftest.$objext
2>&1 | egrep "\-R|\-L"`; list=""; for z in $templist; do case $z in
conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac;
done; echo $list'
+ output_verbose_link_cmd='templist=`$CC -G $CFLAGS -v conftest.$objext
2>&1 | grep "\-[[LR]]"`; list=""; for z in $templist; do case $z in
conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac;
done; echo $list'
# Archives containing C++ object files must be created using
# "CC -xar", where "CC" is the Sun C++ compiler. This is
@@ -3080,7 +3107,7 @@ case $host_os in
# GNU C++ compiler with Solaris linker
if test "$GXX" = yes && test "$with_gnu_ld" = no; then
_LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-z ${wl}defs'
- if $CC --version | egrep -v '^2\.7' > /dev/null; then
+ if $CC --version | grep -v '^2\.7' > /dev/null; then
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $LDFLAGS
$predep_objects $libobjs $deplibs $postdep_objects $linker_flags ${wl}-h
$wl$soname -o $lib'
_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 -nostdlib ${wl}-M $wl$lib.exp -o $lib
$predep_objects $libobjs $deplibs $postdep_objects $linker_flags~$rm $lib.exp'
@@ -3088,7 +3115,7 @@ case $host_os in
# Commands to make compiler produce verbose output that lists
# what "hidden" libraries, object files and flags are used when
# linking a shared library.
- output_verbose_link_cmd="$CC -shared $CFLAGS -v conftest.$objext
2>&1 | egrep \"\-L\""
+ output_verbose_link_cmd="$CC -shared $CFLAGS -v conftest.$objext
2>&1 | grep \"\-L\""
else
# g++ 2.7 appears to require `-G' NOT `-shared' on this
# platform.
@@ -3099,7 +3126,7 @@ case $host_os in
# Commands to make compiler produce verbose output that lists
# what "hidden" libraries, object files and flags are used when
# linking a shared library.
- output_verbose_link_cmd="$CC -G $CFLAGS -v conftest.$objext 2>&1 |
egrep \"\-L\""
+ output_verbose_link_cmd="$CC -G $CFLAGS -v conftest.$objext 2>&1 |
grep \"\-L\""
fi
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $wl$libdir'
@@ -3469,7 +3496,7 @@ if test -f "$ltmain"; then
# Now quote all the things that may contain metacharacters while being
# careful not to overquote the AC_SUBSTed values. We take copies of the
# variables and quote the copies for generation of the libtool script.
- for var in echo old_CC old_CFLAGS AR AR_FLAGS RANLIB LN_S LTCC NM SED SHELL \
+ for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC NM SED
SHELL \
libname_spec library_names_spec soname_spec extract_expsyms_cmds \
old_striplib striplib file_magic_cmd finish_cmds finish_eval \
deplibs_check_method reload_flag reload_cmds need_locks \
@@ -3624,6 +3651,9 @@ CC=$lt_[]_LT_AC_TAGVAR(compiler, $1)
# Is the compiler the GNU C compiler?
with_gcc=$_LT_AC_TAGVAR(GCC, $1)
+# An ERE matcher.
+EGREP=$lt_EGREP
+
# The linker used to build libraries.
LD=$lt_[]_LT_AC_TAGVAR(LD, $1)
@@ -3997,9 +4027,10 @@ mingw*)
esac
# If we're using GNU nm, then use its standard symbol codes.
-if $NM -V 2>&1 | egrep '(GNU|with BFD)' > /dev/null; then
- symcode='[[ABCDGISTW]]'
-fi
+case `$NM -V 2>&1` in
+*GNU* | *'with BFD'*)
+ symcode='[[ABCDGISTW]]' ;;
+esac
# Try without a prefix undercore, then with it.
for ac_symprfx in "" "_"; do
@@ -4035,8 +4066,8 @@ EOF
fi
# Make sure that we snagged all the symbols we need.
- if egrep ' nm_test_var$' "$nlist" >/dev/null; then
- if egrep ' nm_test_func$' "$nlist" >/dev/null; then
+ if grep ' nm_test_var$' "$nlist" >/dev/null; then
+ if grep ' nm_test_func$' "$nlist" >/dev/null; then
cat <<EOF > conftest.$ac_ext
#ifdef __cplusplus
extern "C" {
@@ -4544,7 +4575,7 @@ ifelse([$1],[CXX],[
aix4* | aix5*)
# If we're using GNU nm, then we don't want the "-C" option.
# -C means demangle to AIX nm, but means don't demangle with GNU nm
- if $NM -V 2>&1 | egrep '(GNU)' > /dev/null; then
+ if $NM -V 2>&1 | grep 'GNU' > /dev/null; then
_LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience |
awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) &&
([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols'
else
_LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience
| awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) &&
([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols'
@@ -4580,7 +4611,7 @@ ifelse([$1],[CXX],[
# include_expsyms should be a list of space-separated symbols to be *always*
# included in the symbol list
_LT_AC_TAGVAR(include_expsyms, $1)=
- # exclude_expsyms can be an egrep regular expression of symbols to exclude
+ # exclude_expsyms can be an extended regexp of symbols to exclude
# it will be wrapped by ` (' and `)$', so one must not match beginning or
# end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
# as well as any symbol that contains `d'.
@@ -4644,7 +4675,7 @@ EOF
;;
beos*)
- if $LD --help 2>&1 | egrep ': supported targets:.* elf' > /dev/null; then
+ if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
_LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
# Joseph Beckenbach <address@hidden> says some releases of gcc
# support --undefined. This deserves some investigation. FIXME
@@ -4660,7 +4691,7 @@ EOF
_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
_LT_AC_TAGVAR(always_export_symbols, $1)=no
- if $LD --help 2>&1 | egrep 'auto-import' > /dev/null; then
+ if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs
$compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000
${wl}--out-implib,$lib'
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs
$compiler_flags -o $output_objdir/$soname ${wl}-retain-symbols-file
$wl$export_symbols ${wl}--out-implib,$lib'
else
@@ -4679,7 +4710,7 @@ EOF
;;
solaris* | sysv5*)
- if $LD -v 2>&1 | egrep 'BFD 2\.8' > /dev/null; then
+ if $LD -v 2>&1 | grep 'BFD 2\.8' > /dev/null; then
_LT_AC_TAGVAR(ld_shlibs, $1)=no
cat <<EOF 1>&2
@@ -4691,7 +4722,7 @@ EOF
*** used, and then restart.
EOF
- elif $LD --help 2>&1 | egrep ': supported targets:.* elf' > /dev/null;
then
+ elif $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null;
then
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs
$compiler_flags ${wl}-soname $wl$soname -o $lib'
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs
$compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file
$wl$export_symbols -o $lib'
else
@@ -4707,7 +4738,7 @@ EOF
;;
*)
- if $LD --help 2>&1 | egrep ': supported targets:.* elf' > /dev/null; then
+ if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs
$compiler_flags ${wl}-soname $wl$soname -o $lib'
_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs
$compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file
$wl$export_symbols -o $lib'
else
@@ -4727,7 +4758,7 @@ EOF
;;
*)
# ancient GNU ld didn't support --whole-archive et. al.
- if $LD --help 2>&1 | egrep 'no-whole-archive' > /dev/null; then
+ if $LD --help 2>&1 | grep 'no-whole-archive' > /dev/null; then
_LT_AC_TAGVAR(whole_archive_flag_spec,
$1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
else
_LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
@@ -4762,7 +4793,7 @@ EOF
else
# If we're using GNU nm, then we don't want the "-C" option.
# -C means demangle to AIX nm, but means don't demangle with GNU nm
- if $NM -V 2>&1 | egrep '(GNU)' > /dev/null; then
+ if $NM -V 2>&1 | grep 'GNU' > /dev/null; then
_LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs
$convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 ==
"B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u >
$export_symbols'
else
_LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs
$convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 ==
"B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u >
$export_symbols'
Index: libtoolize.in
===================================================================
RCS file: /cvsroot/libtool/libtool/libtoolize.in,v
retrieving revision 1.18
diff -p -u -r1.18 libtoolize.in
--- libtoolize.in 28 Nov 2001 00:23:58 -0000 1.18
+++ libtoolize.in 24 Oct 2002 06:06:36 -0000
@@ -158,7 +158,7 @@ fi
files='config.guess config.sub ltmain.sh'
auxdir=.
-auxdirline=`egrep '^AC_CONFIG_AUX_DIR' $configure_ac 2>/dev/null`
+auxdirline=`grep '^AC_CONFIG_AUX_DIR' $configure_ac 2>/dev/null`
if test -n "$auxdirline"; then
# Handle explicit AC_CONFIG_AUX_DIR settings.
auxdir=`echo "$auxdirline" | sed 's/^AC_CONFIG_AUX_DIR(\([^)]*\)).*$/\1/'`
@@ -193,12 +193,12 @@ else
fi
if test -z "$automake"; then
- if egrep '^A[MC]_PROG_LIBTOOL' $configure_ac >/dev/null 2>&1; then :
+ if grep '^A[MC]_PROG_LIBTOOL' $configure_ac >/dev/null 2>&1; then :
else
echo "Remember to add \`AC_PROG_LIBTOOL' to \`$configure_ac'."
fi
- if egrep '^AC_PROG_RANLIB' $configure_ac >/dev/null 2>&1; then
+ if grep '^AC_PROG_RANLIB' $configure_ac >/dev/null 2>&1; then
echo "Using \`AC_PROG_RANLIB' is rendered obsolete by \`AC_PROG_LIBTOOL'"
fi
@@ -208,7 +208,7 @@ if test -z "$automake"; then
updatemsg="add the contents of \`$libtool_m4' to \`aclocal.m4'"
fi
- if egrep '^AC_DEFUN\(\[A[MC]_PROG_LIBTOOL' aclocal.m4 >/dev/null 2>&1; then
+ if grep '^AC_DEFUN(\[A[MC]_PROG_LIBTOOL' aclocal.m4 >/dev/null 2>&1; then
# Check the version number on libtool.m4 and the one used in aclocal.m4.
instserial=`grep '^# serial ' $libtool_m4 | grep 'A[MC]_PROG_LIBTOOL' |
sed -e 's/^# serial \([0-9][0-9]*\).*$/\1/; q'`
@@ -242,7 +242,7 @@ if test -z "$automake"; then
updatemsg="add the contents of \`$ltdl_m4' to \`aclocal.m4'"
fi
- if egrep '^AC_DEFUN\(AC_LIB_LTDL' aclocal.m4 >/dev/null 2>&1; then
+ if grep '^AC_DEFUN(AC_LIB_LTDL' aclocal.m4 >/dev/null 2>&1; then
# Check the version number on ltdl.m4 and the one used in aclocal.m4.
instserial=`grep '^# serial ' $ltdl_m4 | grep 'AC_LIB_LTDL' | sed -e
's/^# serial \([0-9][0-9]*\).*$/\1/; q'`
Index: ltdl.m4
===================================================================
RCS file: /cvsroot/libtool/libtool/ltdl.m4,v
retrieving revision 1.44
diff -p -u -r1.44 ltdl.m4
--- ltdl.m4 22 Oct 2002 19:29:28 -0000 1.44
+++ ltdl.m4 24 Oct 2002 06:06:37 -0000
@@ -364,10 +364,10 @@ EOF
ac_nlist=conftest.nm
if AC_TRY_EVAL(NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \>
$ac_nlist) && test -s "$ac_nlist"; then
# See whether the symbols have a leading underscore.
- if egrep '^. _nm_test_func' "$ac_nlist" >/dev/null; then
+ if grep '^. _nm_test_func' "$ac_nlist" >/dev/null; then
ac_cv_sys_symbol_underscore=yes
else
- if egrep '^. nm_test_func ' "$ac_nlist" >/dev/null; then
+ if grep '^. nm_test_func ' "$ac_nlist" >/dev/null; then
:
else
echo "configure: cannot find nm_test_func in $ac_nlist" >&AC_FD_CC
Index: ltmain.in
===================================================================
RCS file: /cvsroot/libtool/libtool/ltmain.in,v
retrieving revision 1.303
diff -p -u -r1.303 ltmain.in
--- ltmain.in 23 Oct 2002 14:36:30 -0000 1.303
+++ ltmain.in 24 Oct 2002 06:06:38 -0000
@@ -955,7 +955,7 @@ EOF
# A libtool-controlled object.
# Check to see that this really is a libtool object.
- if (${SED} -e '2q' $arg | egrep "^# Generated by .*$PACKAGE")
>/dev/null 2>&1; then
+ if (${SED} -e '2q' $arg | grep "^# Generated by .*$PACKAGE")
>/dev/null 2>&1; then
pic_object=
non_pic_object=
@@ -1378,7 +1378,7 @@ EOF
# A libtool-controlled object.
# Check to see that this really is a libtool object.
- if (${SED} -e '2q' $arg | egrep "^# Generated by .*$PACKAGE")
>/dev/null 2>&1; then
+ if (${SED} -e '2q' $arg | grep "^# Generated by .*$PACKAGE") >/dev/null
2>&1; then
pic_object=
non_pic_object=
@@ -1845,7 +1845,7 @@ EOF
fi
# Check to see that this really is a libtool archive.
- if (${SED} -e '2q' $lib | egrep "^# Generated by .*$PACKAGE")
>/dev/null 2>&1; then :
+ if (${SED} -e '2q' $lib | grep "^# Generated by .*$PACKAGE") >/dev/null
2>&1; then :
else
$echo "$modename: \`$lib' is not a valid libtool archive" 1>&2
exit 1
@@ -2990,7 +2990,7 @@ EOF
done
if eval $file_magic_cmd \"\$potlib\" 2>/dev/null \
| ${SED} 10q \
- | egrep "$file_magic_regex" > /dev/null; then
+ | $EGREP "$file_magic_regex" > /dev/null; then
newdeplibs="$newdeplibs $a_deplib"
a_deplib=""
break 2
@@ -3032,7 +3032,7 @@ EOF
potlib="$potent_lib" # see symlink-check above in file_magic
test
if eval echo \"$potent_lib\" 2>/dev/null \
| ${SED} 10q \
- | egrep "$match_pattern_regex" > /dev/null; then
+ | $EGREP "$match_pattern_regex" > /dev/null; then
newdeplibs="$newdeplibs $a_deplib"
a_deplib=""
break 2
@@ -3244,8 +3244,8 @@ EOF
done
IFS="$save_ifs"
if test -n "$export_symbols_regex"; then
- $show "egrep -e \"$export_symbols_regex\" \"$export_symbols\" >
\"${export_symbols}T\""
- $run eval 'egrep -e "$export_symbols_regex" "$export_symbols" >
"${export_symbols}T"'
+ $show "$EGREP -e \"$export_symbols_regex\" \"$export_symbols\" >
\"${export_symbols}T\""
+ $run eval '$EGREP -e "$export_symbols_regex" "$export_symbols" >
"${export_symbols}T"'
$show "$mv \"${export_symbols}T\" \"$export_symbols\""
$run eval '$mv "${export_symbols}T" "$export_symbols"'
fi
@@ -3794,12 +3794,12 @@ extern \"C\" {
done
if test -n "$exclude_expsyms"; then
- $run eval 'egrep -v " ($exclude_expsyms)$" "$nlist" > "$nlist"T'
+ $run eval '$EGREP -v " ($exclude_expsyms)$" "$nlist" > "$nlist"T'
$run eval '$mv "$nlist"T "$nlist"'
fi
if test -n "$export_symbols_regex"; then
- $run eval 'egrep -e "$export_symbols_regex" "$nlist" > "$nlist"T'
+ $run eval '$EGREP -e "$export_symbols_regex" "$nlist" > "$nlist"T'
$run eval '$mv "$nlist"T "$nlist"'
fi
@@ -3827,7 +3827,7 @@ extern \"C\" {
test -f "$nlist" || : > "$nlist"
if test -n "$exclude_expsyms"; then
- egrep -v " ($exclude_expsyms)$" "$nlist" > "$nlist"T
+ $EGREP -v " ($exclude_expsyms)$" "$nlist" > "$nlist"T
$mv "$nlist"T "$nlist"
fi
@@ -4686,7 +4686,7 @@ relink_command=\"$relink_command\""
*.la)
# Check to see that this really is a libtool archive.
- if (${SED} -e '2q' $file | egrep "^# Generated by .*$PACKAGE")
>/dev/null 2>&1; then :
+ if (${SED} -e '2q' $file | grep "^# Generated by .*$PACKAGE")
>/dev/null 2>&1; then :
else
$echo "$modename: \`$file' is not a valid libtool archive" 1>&2
$echo "$help" 1>&2
@@ -4856,7 +4856,7 @@ relink_command=\"$relink_command\""
wrapper=$file
;;
esac
- if (${SED} -e '4q' $wrapper | egrep "^# Generated by
.*$PACKAGE")>/dev/null 2>&1; then
+ if (${SED} -e '4q' $wrapper | grep "^# Generated by
.*$PACKAGE")>/dev/null 2>&1; then
notinst_deplibs=
relink_command=
@@ -5090,7 +5090,7 @@ relink_command=\"$relink_command\""
case $file in
*.la)
# Check to see that this really is a libtool archive.
- if (${SED} -e '2q' $file | egrep "^# Generated by .*$PACKAGE")
>/dev/null 2>&1; then :
+ if (${SED} -e '2q' $file | grep "^# Generated by .*$PACKAGE")
>/dev/null 2>&1; then :
else
$echo "$modename: \`$lib' is not a valid libtool archive" 1>&2
$echo "$help" 1>&2
@@ -5161,7 +5161,7 @@ relink_command=\"$relink_command\""
-*) ;;
*)
# Do a test to see if this is really a libtool program.
- if (${SED} -e '4q' $file | egrep "^# Generated by .*$PACKAGE")
>/dev/null 2>&1; then
+ if (${SED} -e '4q' $file | grep "^# Generated by .*$PACKAGE")
>/dev/null 2>&1; then
# If there is no directory component, then add one.
case $file in
*/* | *\\*) . $file ;;
@@ -5270,7 +5270,7 @@ relink_command=\"$relink_command\""
case $name in
*.la)
# Possibly a libtool archive, so verify it.
- if (${SED} -e '2q' $file | egrep "^# Generated by .*$PACKAGE")
>/dev/null 2>&1; then
+ if (${SED} -e '2q' $file | grep "^# Generated by .*$PACKAGE")
>/dev/null 2>&1; then
. $dir/$name
# Delete the libtool libraries and symlinks.
@@ -5317,7 +5317,7 @@ relink_command=\"$relink_command\""
*.lo)
# Possibly a libtool object, so verify it.
- if (${SED} -e '2q' $file | egrep "^# Generated by .*$PACKAGE")
>/dev/null 2>&1; then
+ if (${SED} -e '2q' $file | grep "^# Generated by .*$PACKAGE")
>/dev/null 2>&1; then
# Read the .lo file
. $dir/$name
@@ -5339,7 +5339,7 @@ relink_command=\"$relink_command\""
*)
# Do a test to see if this is a libtool program.
if test "$mode" = clean &&
- (${SED} -e '4q' $file | egrep "^# Generated by .*$PACKAGE")
>/dev/null 2>&1; then
+ (${SED} -e '4q' $file | grep "^# Generated by .*$PACKAGE")
>/dev/null 2>&1; then
relink_command=
. $dir/$file
Index: demo/Makefile.am
===================================================================
RCS file: /cvsroot/libtool/libtool/demo/Makefile.am,v
retrieving revision 1.28
diff -p -u -r1.28 Makefile.am
--- demo/Makefile.am 1 Jun 2002 14:09:50 -0000 1.28
+++ demo/Makefile.am 24 Oct 2002 06:06:38 -0000
@@ -72,12 +72,13 @@ $(srcdir)/acinclude.m4:
# Test programs to see what gets hardcoded.
.PHONY: hardcode
hardcode: $(hardcode_tests)
-SET_HARDCODE_FLAGS = eval `$(LIBTOOL) --config | egrep -e '^(hardcode_.*|wl)='`
+SET_HARDCODE_FLAGS = \
+ eval `$(LIBTOOL) --config | sed -n -e '/^hardcode_.*=/p; /^wl=/p'`
hc-direct: $(hell_OBJECTS) $(hell_DEPENDENCIES) $(libdir)/libhello.la
@rm -f hc-direct
@echo "You may ignore any linking errors from the following command:"
@shlib=./$(objdir)/libhello.a; \
- eval "`egrep '^library_names' libhello.la`"; \
+ eval "`grep '^library_names' libhello.la`"; \
for lib in $$library_names; do \
shlib="./$(objdir)/$$lib"; \
done; \
Index: doc/libtool.texi
===================================================================
RCS file: /cvsroot/libtool/libtool/doc/libtool.texi,v
retrieving revision 1.125
diff -p -u -r1.125 libtool.texi
--- doc/libtool.texi 20 Jun 2002 06:58:38 -0000 1.125
+++ doc/libtool.texi 24 Oct 2002 06:06:40 -0000
@@ -3986,7 +3986,7 @@ writes libtool makes sure @samp{$deplibs
@vindex file_magic_test_file
looks in the library link path for libraries that have the right
libname. Then it runs @samp{$file_magic_cmd} on the library and checks
-for a match against @var{regex} using @code{egrep}. When
+for a match against the extended regular expression @var{regex}. When
@var{file_magic_test_file} is set by @file{libtool.m4}, it is used as an
argument to @samp{$file_magic_cmd} in order to verify whether the
regular expression matches its output, and warn the user otherwise.
Index: pdemo/Makefile.am
===================================================================
RCS file: /cvsroot/libtool/libtool/pdemo/Makefile.am,v
retrieving revision 1.5
diff -p -u -r1.5 Makefile.am
--- pdemo/Makefile.am 1 Jun 2002 14:09:50 -0000 1.5
+++ pdemo/Makefile.am 24 Oct 2002 06:06:40 -0000
@@ -72,12 +72,13 @@ $(srcdir)/acinclude.m4:
# Test programs to see what gets hardcoded.
.PHONY: hardcode
hardcode: $(hardcode_tests)
-SET_HARDCODE_FLAGS = eval `$(LIBTOOL) --config | egrep -e '^(hardcode_.*|wl)='`
+SET_HARDCODE_FLAGS = \
+ eval `$(LIBTOOL) --config | sed -n -e '/^hardcode_.*=/p; /^wl=/p'`
hc-direct: $(hell_OBJECTS) $(hell_DEPENDENCIES) $(libdir)/libhello.la
@rm -f hc-direct
@echo "You may ignore any linking errors from the following command:"
@shlib=./$(objdir)/libhello.a; \
- eval "`egrep '^library_names' libhello.la`"; \
+ eval "`grep '^library_names' libhello.la`"; \
for lib in $$library_names; do \
shlib="./$(objdir)/$$lib"; \
done; \
Index: tests/assign.test
===================================================================
RCS file: /cvsroot/libtool/libtool/tests/assign.test,v
retrieving revision 1.2
diff -p -u -r1.2 assign.test
--- tests/assign.test 6 Sep 2000 17:31:09 -0000 1.2
+++ tests/assign.test 24 Oct 2002 06:06:40 -0000
@@ -12,7 +12,7 @@ fi
. $srcdir/defs || exit 1
# Check that test -e isn't used in our portable shell scripts.
-if egrep -n '[^ ]=[^ ].*(break|continue)' $srcdir/../ltmain.sh; then
+if $EGREP -n '[^ ]=[^ ].*(break|continue)' $srcdir/../ltmain.sh; then
echo "cannot use \`break' or \`continue' on the same line as an assignment"
exit 1
fi
Index: tests/build-relink.test
===================================================================
RCS file: /cvsroot/libtool/libtool/tests/build-relink.test,v
retrieving revision 1.12
diff -p -u -r1.12 build-relink.test
--- tests/build-relink.test 3 Mar 2002 03:19:55 -0000 1.12
+++ tests/build-relink.test 24 Oct 2002 06:06:40 -0000
@@ -19,7 +19,7 @@ fi
# Check to make sure we have a dynamic library.
library_names=NONE
-eval `egrep -e '^library_names=' ./libhello.la 2>/dev/null`
+eval `grep '^library_names=' ./libhello.la 2>/dev/null`
if test "$library_names" = NONE; then
echo "library_names not set in ../demo/libhello.la" 1>&2
@@ -31,35 +31,35 @@ fi
# Unfortunately, we need access to libtool internals for this test.
objdir=NONE
-eval `egrep -e '^objdir=' ./libtool 2>/dev/null`
+eval `grep '^objdir=' ./libtool 2>/dev/null`
if test "$objdir" = NONE; then
echo "objdir not set in ../demo/libtool" 1>&2
exit 1
fi
shlibpath_overrides_runpath=NONE
-eval `egrep -e '^shlibpath_overrides_runpath=' ./libtool 2>/dev/null`
+eval `grep '^shlibpath_overrides_runpath=' ./libtool 2>/dev/null`
if test "$shlibpath_overrides_runpath" = NONE; then
echo "shlibpath_overrides_runpath not set in ../demo/libtool" 1>&2
exit 1
fi
hardcode_action=NONE
-eval `egrep -e '^hardcode_action=' ./libtool 2>/dev/null`
+eval `grep '^hardcode_action=' ./libtool 2>/dev/null`
if test "$hardcode_action" = NONE; then
echo "hardcode_action not set in ../demo/libtool" 1>&2
exit 1
fi
hardcode_direct=NONE
-eval `egrep -e '^hardcode_direct=' ./libtool 2>/dev/null`
+eval `grep '^hardcode_direct=' ./libtool 2>/dev/null`
if test "$hardcode_direct" = NONE; then
echo "hardcode_direct not set in ../demo/libtool" 1>&2
exit 1
fi
hardcode_into_libs=NONE
-eval `egrep -e '^hardcode_into_libs=' ./libtool 2>/dev/null`
+eval `grep '^hardcode_into_libs=' ./libtool 2>/dev/null`
if test "$hardcode_into_libs" = NONE; then
echo "hardcode_into_libs not set in ../demo/libtool" 1>&2
exit 1
Index: tests/build-relink2.test
===================================================================
RCS file: /cvsroot/libtool/libtool/tests/build-relink2.test,v
retrieving revision 1.6
diff -p -u -r1.6 build-relink2.test
--- tests/build-relink2.test 31 May 2002 06:56:10 -0000 1.6
+++ tests/build-relink2.test 24 Oct 2002 06:06:40 -0000
@@ -20,7 +20,7 @@ fi
# Check to make sure we have a dynamic library.
library_names=NONE
-eval `egrep -e '^library_names=' ./l3/libl3.la 2>/dev/null`
+eval `grep '^library_names=' ./l3/libl3.la 2>/dev/null`
if test "$library_names" = NONE; then
echo "library_names not set in ../depdemo/l3/libl3.la" 1>&2
@@ -32,35 +32,35 @@ fi
# Unfortunately, we need access to libtool internals for this test.
objdir=NONE
-eval `egrep -e '^objdir=' ./libtool 2>/dev/null`
+eval `grep '^objdir=' ./libtool 2>/dev/null`
if test "$objdir" = NONE; then
echo "objdir not set in ../depdemo/libtool" 1>&2
exit 1
fi
shlibpath_overrides_runpath=NONE
-eval `egrep -e '^shlibpath_overrides_runpath=' ./libtool 2>/dev/null`
+eval `grep '^shlibpath_overrides_runpath=' ./libtool 2>/dev/null`
if test "$shlibpath_overrides_runpath" = NONE; then
echo "shlibpath_overrides_runpath not set in ../depdemo/libtool" 1>&2
exit 1
fi
hardcode_action=NONE
-eval `egrep -e '^hardcode_action=' ./libtool 2>/dev/null`
+eval `grep '^hardcode_action=' ./libtool 2>/dev/null`
if test "$hardcode_action" = NONE; then
echo "hardcode_action not set in ../depdemo/libtool" 1>&2
exit 1
fi
hardcode_direct=NONE
-eval `egrep -e '^hardcode_direct=' ./libtool 2>/dev/null`
+eval `grep '^hardcode_direct=' ./libtool 2>/dev/null`
if test "$hardcode_direct" = NONE; then
echo "hardcode_direct not set in ../depdemo/libtool" 1>&2
exit 1
fi
hardcode_into_libs=NONE
-eval `egrep -e '^hardcode_into_libs=' ./libtool 2>/dev/null`
+eval `grep '^hardcode_into_libs=' ./libtool 2>/dev/null`
if test "$hardcode_into_libs" = NONE; then
echo "hardcode_into_libs not set in ../depdemo/libtool" 1>&2
exit 1
Index: tests/cdemo-conf.test
===================================================================
RCS file: /cvsroot/libtool/libtool/tests/cdemo-conf.test,v
retrieving revision 1.3
diff -p -u -r1.3 cdemo-conf.test
--- tests/cdemo-conf.test 4 Sep 2000 07:46:01 -0000 1.3
+++ tests/cdemo-conf.test 24 Oct 2002 06:06:40 -0000
@@ -27,8 +27,8 @@ rm -f config.cache
echo "= Configuring in ../cdemo (prefix=$prefix)"
CONFIG_SITE=/dev/null/config/site ${CONFIG_SHELL-/bin/sh}
$srcdir/../cdemo/configure --srcdir=$srcdir/../cdemo --prefix=$prefix || exit 1
-if egrep '^build_old_libs=yes' libtool > /dev/null &&
- egrep '^build_libtool_libs=yes' libtool > /dev/null; then :
+if grep '^build_old_libs=yes' libtool > /dev/null &&
+ grep '^build_libtool_libs=yes' libtool > /dev/null; then :
else rm -f Makefile && exit 77
fi
Index: tests/cdemo-shared.test
===================================================================
RCS file: /cvsroot/libtool/libtool/tests/cdemo-shared.test,v
retrieving revision 1.3
diff -p -u -r1.3 cdemo-shared.test
--- tests/cdemo-shared.test 4 Sep 2000 07:46:01 -0000 1.3
+++ tests/cdemo-shared.test 24 Oct 2002 06:06:40 -0000
@@ -27,8 +27,8 @@ rm -f config.cache
echo "= Configuring in ../cdemo (prefix=$prefix) with --disable-static"
CONFIG_SITE=/dev/null/config/site ${CONFIG_SHELL-/bin/sh}
$srcdir/../cdemo/configure --srcdir=$srcdir/../cdemo --prefix=$prefix
--disable-static || exit 1
-if egrep '^build_old_libs=no' libtool > /dev/null &&
- egrep '^build_libtool_libs=yes' libtool > /dev/null; then :
+if grep '^build_old_libs=no' libtool > /dev/null &&
+ grep '^build_libtool_libs=yes' libtool > /dev/null; then :
else rm -f Makefile && exit 77
fi
Index: tests/cdemo-static.test
===================================================================
RCS file: /cvsroot/libtool/libtool/tests/cdemo-static.test,v
retrieving revision 1.4
diff -p -u -r1.4 cdemo-static.test
--- tests/cdemo-static.test 4 Sep 2000 07:46:01 -0000 1.4
+++ tests/cdemo-static.test 24 Oct 2002 06:06:40 -0000
@@ -27,8 +27,8 @@ rm -f config.cache
echo "= Configuring in ../cdemo (prefix=$prefix) with --disable-shared"
CONFIG_SITE=/dev/null/config/site ${CONFIG_SHELL-/bin/sh}
$srcdir/../cdemo/configure --srcdir=$srcdir/../cdemo --prefix=$prefix
--disable-shared || exit 1
-if egrep '^build_old_libs=yes' libtool > /dev/null &&
- egrep '^build_libtool_libs=no' libtool > /dev/null; then :
+if grep '^build_old_libs=yes' libtool > /dev/null &&
+ grep '^build_libtool_libs=no' libtool > /dev/null; then :
else rm -f Makefile && exit 77
fi
Index: tests/defs
===================================================================
RCS file: /cvsroot/libtool/libtool/tests/defs,v
retrieving revision 1.2
diff -p -u -r1.2 defs
--- tests/defs 30 Jun 2001 20:31:34 -0000 1.2
+++ tests/defs 24 Oct 2002 06:06:40 -0000
@@ -14,6 +14,17 @@ libtool="../libtool"
make="${MAKE-make}"
SHELL="${CONFIG_SHELL-/bin/sh}"
+if echo a | (grep -E '(a|b)') >/dev/null 2>&1; then
+ EGREP='grep -E'
+else
+ EGREP='egrep'
+fi
+if echo 'ab*c' | (grep -F 'ab*c') >/dev/null 2>&1; then
+ FGREP='grep -F'
+else
+ FGREP='fgrep'
+fi
+
prefix="./_inst"
if test "$need_prefix" = yes; then
# An absolute path to a test installation directory.
Index: tests/demo-conf.test
===================================================================
RCS file: /cvsroot/libtool/libtool/tests/demo-conf.test,v
retrieving revision 1.3
diff -p -u -r1.3 demo-conf.test
--- tests/demo-conf.test 4 Sep 2000 07:46:01 -0000 1.3
+++ tests/demo-conf.test 24 Oct 2002 06:06:40 -0000
@@ -27,8 +27,8 @@ rm -f config.cache
echo "= Configuring in ../demo (prefix=$prefix)"
CONFIG_SITE=/dev/null/config/site ${CONFIG_SHELL-/bin/sh}
$srcdir/../demo/configure --srcdir=$srcdir/../demo --prefix=$prefix || exit 1
-if egrep '^build_old_libs=yes' libtool > /dev/null &&
- egrep '^build_libtool_libs=yes' libtool > /dev/null; then :
+if grep '^build_old_libs=yes' libtool > /dev/null &&
+ grep '^build_libtool_libs=yes' libtool > /dev/null; then :
else rm -f Makefile && exit 77
fi
Index: tests/demo-exec.test
===================================================================
RCS file: /cvsroot/libtool/libtool/tests/demo-exec.test,v
retrieving revision 1.6
diff -p -u -r1.6 demo-exec.test
--- tests/demo-exec.test 3 Mar 2002 03:19:55 -0000 1.6
+++ tests/demo-exec.test 24 Oct 2002 06:06:40 -0000
@@ -32,7 +32,7 @@ else
status=1
fi
-if ../demo/helldl | egrep -e '(Welcome to .*GNU Hell|unsupported)'; then :
+if ../demo/helldl | $EGREP -e '(Welcome to .*GNU Hell|unsupported)'; then :
else
echo "$0: cannot execute ../demo/helldl" 1>&2
status=1
Index: tests/demo-inst.test
===================================================================
RCS file: /cvsroot/libtool/libtool/tests/demo-inst.test,v
retrieving revision 1.6
diff -p -u -r1.6 demo-inst.test
--- tests/demo-inst.test 3 Mar 2002 03:19:55 -0000 1.6
+++ tests/demo-inst.test 24 Oct 2002 06:06:40 -0000
@@ -43,7 +43,7 @@ else
status=1
fi
-if $prefix/bin/helldl | egrep -e '(Welcome to .*GNU Hell|unsupported)'; then :
+if $prefix/bin/helldl | $EGREP -e '(Welcome to .*GNU Hell|unsupported)'; then :
else
echo "$0: cannot execute $prefix/bin/helldl" 1>&2
Index: tests/demo-nofast.test
===================================================================
RCS file: /cvsroot/libtool/libtool/tests/demo-nofast.test,v
retrieving revision 1.3
diff -p -u -r1.3 demo-nofast.test
--- tests/demo-nofast.test 4 Sep 2000 07:46:01 -0000 1.3
+++ tests/demo-nofast.test 24 Oct 2002 06:06:40 -0000
@@ -27,7 +27,7 @@ rm -f config.cache
echo "= Configuring in ../demo (prefix=$prefix)"
CONFIG_SITE=/dev/null/config/site ${CONFIG_SHELL-/bin/sh}
$srcdir/../demo/configure --srcdir=$srcdir/../demo --prefix=$prefix
--enable-fast-install=no || exit 1
-if egrep '^hardcode_action=relink' libtool > /dev/null; then
+if grep '^hardcode_action=relink' libtool > /dev/null; then
rm -f Makefile && exit 77
fi
Index: tests/demo-shared.test
===================================================================
RCS file: /cvsroot/libtool/libtool/tests/demo-shared.test,v
retrieving revision 1.3
diff -p -u -r1.3 demo-shared.test
--- tests/demo-shared.test 4 Sep 2000 07:46:01 -0000 1.3
+++ tests/demo-shared.test 24 Oct 2002 06:06:40 -0000
@@ -27,8 +27,8 @@ rm -f config.cache
echo "= Configuring in ../demo (prefix=$prefix) with --disable-static"
CONFIG_SITE=/dev/null/config/site ${CONFIG_SHELL-/bin/sh}
$srcdir/../demo/configure --srcdir=$srcdir/../demo --prefix=$prefix
--disable-static || exit 1
-if egrep '^build_old_libs=no' libtool > /dev/null &&
- egrep '^build_libtool_libs=yes' libtool > /dev/null; then :
+if grep '^build_old_libs=no' libtool > /dev/null &&
+ grep '^build_libtool_libs=yes' libtool > /dev/null; then :
else rm -f Makefile && exit 77
fi
Index: tests/demo-static.test
===================================================================
RCS file: /cvsroot/libtool/libtool/tests/demo-static.test,v
retrieving revision 1.3
diff -p -u -r1.3 demo-static.test
--- tests/demo-static.test 4 Sep 2000 07:46:01 -0000 1.3
+++ tests/demo-static.test 24 Oct 2002 06:06:40 -0000
@@ -27,8 +27,8 @@ rm -f config.cache
echo "= Configuring in ../demo (prefix=$prefix) with --disable-shared"
CONFIG_SITE=/dev/null/config/site ${CONFIG_SHELL-/bin/sh}
$srcdir/../demo/configure --srcdir=$srcdir/../demo --prefix=$prefix
--disable-shared || exit 1
-if egrep '^build_old_libs=yes' libtool > /dev/null &&
- egrep '^build_libtool_libs=no' libtool > /dev/null; then :
+if grep '^build_old_libs=yes' libtool > /dev/null &&
+ grep '^build_libtool_libs=no' libtool > /dev/null; then :
else rm -f Makefile && exit 77
fi
Index: tests/depdemo-conf.test
===================================================================
RCS file: /cvsroot/libtool/libtool/tests/depdemo-conf.test,v
retrieving revision 1.4
diff -p -u -r1.4 depdemo-conf.test
--- tests/depdemo-conf.test 4 Sep 2000 07:46:01 -0000 1.4
+++ tests/depdemo-conf.test 24 Oct 2002 06:06:40 -0000
@@ -27,8 +27,8 @@ rm -f config.cache
echo "= Configuring in ../depdemo (prefix=$prefix)"
CONFIG_SITE=/dev/null/config/site ${CONFIG_SHELL-/bin/sh}
$srcdir/../depdemo/configure --srcdir=$srcdir/../depdemo --prefix=$prefix ||
exit 1
-if egrep '^build_old_libs=yes' libtool > /dev/null &&
- egrep '^build_libtool_libs=yes' libtool > /dev/null; then :
+if grep '^build_old_libs=yes' libtool > /dev/null &&
+ grep '^build_libtool_libs=yes' libtool > /dev/null; then :
else rm -f Makefile && exit 77
fi
Index: tests/depdemo-nofast.test
===================================================================
RCS file: /cvsroot/libtool/libtool/tests/depdemo-nofast.test,v
retrieving revision 1.3
diff -p -u -r1.3 depdemo-nofast.test
--- tests/depdemo-nofast.test 4 Sep 2000 07:46:01 -0000 1.3
+++ tests/depdemo-nofast.test 24 Oct 2002 06:06:40 -0000
@@ -27,7 +27,7 @@ rm -f config.cache
echo "= Configuring in ../depdemo (prefix=$prefix)"
CONFIG_SITE=/dev/null/config/site ${CONFIG_SHELL-/bin/sh}
$srcdir/../depdemo/configure --srcdir=$srcdir/../depdemo --prefix=$prefix
--enable-fast-install=no || exit 1
-if egrep '^hardcode_action=relink' libtool > /dev/null; then
+if grep '^hardcode_action=relink' libtool > /dev/null; then
rm -f Makefile && exit 77
fi
Index: tests/depdemo-shared.test
===================================================================
RCS file: /cvsroot/libtool/libtool/tests/depdemo-shared.test,v
retrieving revision 1.4
diff -p -u -r1.4 depdemo-shared.test
--- tests/depdemo-shared.test 4 Sep 2000 07:46:01 -0000 1.4
+++ tests/depdemo-shared.test 24 Oct 2002 06:06:40 -0000
@@ -27,8 +27,8 @@ rm -f config.cache
echo "= Configuring in ../depdemo (prefix=$prefix) with --disable-static"
CONFIG_SITE=/dev/null/config/site ${CONFIG_SHELL-/bin/sh}
$srcdir/../depdemo/configure --srcdir=$srcdir/../depdemo --prefix=$prefix
--disable-static || exit 1
-if egrep '^build_old_libs=no' libtool > /dev/null &&
- egrep '^build_libtool_libs=yes' libtool > /dev/null; then :
+if grep '^build_old_libs=no' libtool > /dev/null &&
+ grep '^build_libtool_libs=yes' libtool > /dev/null; then :
else rm -f Makefile && exit 77
fi
Index: tests/depdemo-static.test
===================================================================
RCS file: /cvsroot/libtool/libtool/tests/depdemo-static.test,v
retrieving revision 1.4
diff -p -u -r1.4 depdemo-static.test
--- tests/depdemo-static.test 4 Sep 2000 07:46:01 -0000 1.4
+++ tests/depdemo-static.test 24 Oct 2002 06:06:40 -0000
@@ -27,8 +27,8 @@ rm -f config.cache
echo "= Configuring in ../depdemo (prefix=$prefix) with --disable-shared"
CONFIG_SITE=/dev/null/config/site ${CONFIG_SHELL-/bin/sh}
$srcdir/../depdemo/configure --srcdir=$srcdir/../depdemo --prefix=$prefix
--disable-shared || exit 1
-if egrep '^build_old_libs=yes' libtool > /dev/null &&
- egrep '^build_libtool_libs=no' libtool > /dev/null; then :
+if grep '^build_old_libs=yes' libtool > /dev/null &&
+ grep '^build_libtool_libs=no' libtool > /dev/null; then :
else rm -f Makefile && exit 77
fi
Index: tests/f77demo-conf.test
===================================================================
RCS file: /cvsroot/libtool/libtool/tests/f77demo-conf.test,v
retrieving revision 1.1
diff -p -u -r1.1 f77demo-conf.test
--- tests/f77demo-conf.test 31 Jul 2002 20:15:28 -0000 1.1
+++ tests/f77demo-conf.test 24 Oct 2002 06:06:40 -0000
@@ -27,8 +27,8 @@ rm -f config.cache
echo "= Configuring in ../f77demo (prefix=$prefix)"
CONFIG_SITE=/dev/null/config/site ${CONFIG_SHELL-/bin/sh}
$srcdir/../f77demo/configure --srcdir=$srcdir/../f77demo --prefix=$prefix ||
exit 1
-if egrep '^build_old_libs=yes' libtool > /dev/null &&
- egrep '^build_libtool_libs=yes' libtool > /dev/null; then :
+if $EGREP '^build_old_libs=yes' libtool > /dev/null &&
+ $EGREP '^build_libtool_libs=yes' libtool > /dev/null; then :
else rm -f Makefile && exit 77
fi
Index: tests/f77demo-exec.test
===================================================================
RCS file: /cvsroot/libtool/libtool/tests/f77demo-exec.test,v
retrieving revision 1.1
diff -p -u -r1.1 f77demo-exec.test
--- tests/f77demo-exec.test 31 Jul 2002 20:15:28 -0000 1.1
+++ tests/f77demo-exec.test 24 Oct 2002 06:06:40 -0000
@@ -10,7 +10,7 @@ if test -z "$srcdir"; then
fi
. $srcdir/defs || exit 1
-if test -f ../f77demo/fprogram -a -f ../f77demo/cprogram; then :
+if test -f ../f77demo/fprogram && test -f ../f77demo/cprogram; then :
else
echo "You must run f77demo-make.test before running $0" 1>&2
exit 77
Index: tests/f77demo-shared.test
===================================================================
RCS file: /cvsroot/libtool/libtool/tests/f77demo-shared.test,v
retrieving revision 1.1
diff -p -u -r1.1 f77demo-shared.test
--- tests/f77demo-shared.test 31 Jul 2002 20:15:28 -0000 1.1
+++ tests/f77demo-shared.test 24 Oct 2002 06:06:40 -0000
@@ -27,8 +27,8 @@ rm -f config.cache
echo "= Configuring in ../f77demo (prefix=$prefix) with --disable-static"
CONFIG_SITE=/dev/null/config/site ${CONFIG_SHELL-/bin/sh}
$srcdir/../f77demo/configure --srcdir=$srcdir/../f77demo --prefix=$prefix
--disable-static || exit 1
-if egrep '^build_old_libs=no' libtool > /dev/null &&
- egrep '^build_libtool_libs=yes' libtool > /dev/null; then :
+if $EGREP '^build_old_libs=no' libtool > /dev/null &&
+ $EGREP '^build_libtool_libs=yes' libtool > /dev/null; then :
else rm -f Makefile && exit 77
fi
Index: tests/f77demo-static.test
===================================================================
RCS file: /cvsroot/libtool/libtool/tests/f77demo-static.test,v
retrieving revision 1.1
diff -p -u -r1.1 f77demo-static.test
--- tests/f77demo-static.test 31 Jul 2002 20:15:28 -0000 1.1
+++ tests/f77demo-static.test 24 Oct 2002 06:06:40 -0000
@@ -27,8 +27,8 @@ rm -f config.cache
echo "= Configuring in ../f77demo (prefix=$prefix) with --disable-shared"
CONFIG_SITE=/dev/null/config/site ${CONFIG_SHELL-/bin/sh}
$srcdir/../f77demo/configure --srcdir=$srcdir/../f77demo --prefix=$prefix
--disable-shared || exit 1
-if egrep '^build_old_libs=yes' libtool > /dev/null &&
- egrep '^build_libtool_libs=no' libtool > /dev/null; then :
+if $EGREP '^build_old_libs=yes' libtool > /dev/null &&
+ $EGREP '^build_libtool_libs=no' libtool > /dev/null; then :
else rm -f Makefile && exit 77
fi
Index: tests/hardcode.test
===================================================================
RCS file: /cvsroot/libtool/libtool/tests/hardcode.test,v
retrieving revision 1.5
diff -p -u -r1.5 hardcode.test
--- tests/hardcode.test 30 May 2002 20:35:43 -0000 1.5
+++ tests/hardcode.test 24 Oct 2002 06:06:40 -0000
@@ -19,7 +19,7 @@ fi
# Unfortunately, we need access to libtool internals for this test.
objdir=NONE
-eval `egrep -e '^objdir=' ./libtool 2>/dev/null`
+eval `grep '^objdir=' ./libtool 2>/dev/null`
if test "$objdir" = NONE; then
echo "objdir not set in ../demo/libtool" 1>&2
exit 1
@@ -27,7 +27,7 @@ fi
# Check to make sure we have a dynamic library.
library_names=NONE
-eval `egrep -e '^library_names=' ./libhello.la 2>/dev/null`
+eval `grep '^library_names=' ./libhello.la 2>/dev/null`
if test "$library_names" = NONE; then
echo "library_names not set in ../demo/libhello.la" 1>&2
@@ -48,7 +48,7 @@ hardcode_shlibpath_var=NONE
hardcode_libdir_flag_spec=NONE
# Suck in all the hardcode_* variable settings.
-eval `./libtool --config | egrep -e '^hardcode_' 2>/dev/null`
+eval `./libtool --config | grep '^hardcode_' 2>/dev/null`
if test "$hardcode_direct" = NONE; then
echo "hardcode_direct not set in ../demo/libtool" 1>&2
@@ -101,12 +101,12 @@ for file in hc-*; do
# AIX fgrep also has a limited line length, so we turn unprintable
# characters into newlines.
if cat $file | (tr '\000-\037\200-\377' '\n' || cat) 2>/dev/null \
- | fgrep "$objdir" > /dev/null 2>&1; then
+ | $FGREP "$objdir" > /dev/null 2>&1; then
hardcoded=yes
- elif fgrep "$objdir" $file > /dev/null 2>&1; then
+ elif $FGREP "$objdir" $file > /dev/null 2>&1; then
# We retry fgrep without tr, in case the above lead to a false negative.
hardcoded=yes
- elif (sed -e '1!d' $file | egrep 'unsupported') >/dev/null 2>&1; then
+ elif (sed -e '1!d' $file | grep 'unsupported') >/dev/null 2>&1; then
hardcoded=unsupported
fi
Index: tests/mdemo-conf.test
===================================================================
RCS file: /cvsroot/libtool/libtool/tests/mdemo-conf.test,v
retrieving revision 1.6
diff -p -u -r1.6 mdemo-conf.test
--- tests/mdemo-conf.test 4 Sep 2000 07:46:01 -0000 1.6
+++ tests/mdemo-conf.test 24 Oct 2002 06:06:40 -0000
@@ -27,8 +27,8 @@ rm -f config.cache
echo "= Configuring in ../mdemo (prefix=$prefix)"
CONFIG_SITE=/dev/null/config/site ${CONFIG_SHELL-/bin/sh}
$srcdir/../mdemo/configure --srcdir=$srcdir/../mdemo --prefix=$prefix || exit 1
-if egrep '^build_old_libs=yes' libtool > /dev/null &&
- egrep '^build_libtool_libs=yes' libtool > /dev/null; then :
+if grep '^build_old_libs=yes' libtool > /dev/null &&
+ grep '^build_libtool_libs=yes' libtool > /dev/null; then :
else rm -f Makefile && exit 77
fi
Index: tests/mdemo-shared.test
===================================================================
RCS file: /cvsroot/libtool/libtool/tests/mdemo-shared.test,v
retrieving revision 1.4
diff -p -u -r1.4 mdemo-shared.test
--- tests/mdemo-shared.test 4 Sep 2000 07:46:01 -0000 1.4
+++ tests/mdemo-shared.test 24 Oct 2002 06:06:40 -0000
@@ -27,8 +27,8 @@ rm -f config.cache
echo "= Configuring in ../mdemo (prefix=$prefix) with --disable-static"
CONFIG_SITE=/dev/null/config/site ${CONFIG_SHELL-/bin/sh}
$srcdir/../mdemo/configure --srcdir=$srcdir/../mdemo --prefix=$prefix
--disable-static || exit 1
-if egrep '^build_old_libs=no' libtool > /dev/null &&
- egrep '^build_libtool_libs=yes' libtool > /dev/null; then :
+if grep '^build_old_libs=no' libtool > /dev/null &&
+ grep '^build_libtool_libs=yes' libtool > /dev/null; then :
else rm -f Makefile && exit 77
fi
Index: tests/mdemo-static.test
===================================================================
RCS file: /cvsroot/libtool/libtool/tests/mdemo-static.test,v
retrieving revision 1.4
diff -p -u -r1.4 mdemo-static.test
--- tests/mdemo-static.test 4 Sep 2000 07:46:01 -0000 1.4
+++ tests/mdemo-static.test 24 Oct 2002 06:06:40 -0000
@@ -27,8 +27,8 @@ rm -f config.cache
echo "= Configuring in ../mdemo (prefix=$prefix) with --disable-shared"
CONFIG_SITE=/dev/null/config/site ${CONFIG_SHELL-/bin/sh}
$srcdir/../mdemo/configure --srcdir=$srcdir/../mdemo --prefix=$prefix
--disable-shared || exit 1
-if egrep '^build_old_libs=yes' libtool > /dev/null &&
- egrep '^build_libtool_libs=no' libtool > /dev/null; then :
+if grep '^build_old_libs=yes' libtool > /dev/null &&
+ grep '^build_libtool_libs=no' libtool > /dev/null; then :
else rm -f Makefile && exit 77
fi
Index: tests/pdemo-conf.test
===================================================================
RCS file: /cvsroot/libtool/libtool/tests/pdemo-conf.test,v
retrieving revision 1.2
diff -p -u -r1.2 pdemo-conf.test
--- tests/pdemo-conf.test 6 Jun 2001 14:53:29 -0000 1.2
+++ tests/pdemo-conf.test 24 Oct 2002 06:06:40 -0000
@@ -27,8 +27,8 @@ rm -f config.cache
echo "= Configuring in ../pdemo (prefix=$prefix)"
CONFIG_SITE=/dev/null/config/site ${CONFIG_SHELL-/bin/sh}
$srcdir/../pdemo/configure --srcdir=$srcdir/../pdemo --prefix=$prefix || exit 1
-if egrep '^build_old_libs=yes' libtool > /dev/null &&
- egrep '^build_libtool_libs=yes' libtool > /dev/null; then :
+if grep '^build_old_libs=yes' libtool > /dev/null &&
+ grep '^build_libtool_libs=yes' libtool > /dev/null; then :
else rm -f Makefile && exit 77
fi
Index: tests/pdemo-exec.test
===================================================================
RCS file: /cvsroot/libtool/libtool/tests/pdemo-exec.test,v
retrieving revision 1.4
diff -p -u -r1.4 pdemo-exec.test
--- tests/pdemo-exec.test 1 Jun 2002 14:54:51 -0000 1.4
+++ tests/pdemo-exec.test 24 Oct 2002 06:06:40 -0000
@@ -32,7 +32,7 @@ else
status=1
fi
-if ../pdemo/helldl | egrep -e '(Welcome to .*GNU Hell|unsupported)'; then :
+if ../pdemo/helldl | $EGREP -e '(Welcome to .*GNU Hell|unsupported)'; then :
else
echo "$0: cannot execute ../pdemo/helldl" 1>&2
status=1
Index: tests/pdemo-inst.test
===================================================================
RCS file: /cvsroot/libtool/libtool/tests/pdemo-inst.test,v
retrieving revision 1.3
diff -p -u -r1.3 pdemo-inst.test
--- tests/pdemo-inst.test 1 Jun 2002 14:09:50 -0000 1.3
+++ tests/pdemo-inst.test 24 Oct 2002 06:06:40 -0000
@@ -43,7 +43,7 @@ else
status=1
fi
-if $prefix/bin/helldl | egrep -e '(Welcome to .*GNU Hell|unsupported)'; then :
+if $prefix/bin/helldl | $EGREP -e '(Welcome to .*GNU Hell|unsupported)'; then :
else
echo "$0: cannot execute $prefix/bin/helldl" 1>&2
Index: tests/sh.test
===================================================================
RCS file: /cvsroot/libtool/libtool/tests/sh.test,v
retrieving revision 1.8
diff -p -u -r1.8 sh.test
--- tests/sh.test 29 Jul 2001 16:35:50 -0000 1.8
+++ tests/sh.test 24 Oct 2002 06:06:40 -0000
@@ -15,61 +15,61 @@ status=0
scripts="$srcdir/../ltmain.sh"
# Check for bad binary operators.
-if egrep -n -e "if[ ]+[\"']?\\$.*(=|-[lg][te]|-eq|-ne)" $scripts; then
+if $EGREP -n -e "if[ ]+[\"']?\\$.*(=|-[lg][te]|-eq|-ne)" $scripts; then
echo "use \`if test \$something =' instead of \`if \$something ='"
status=1
fi
# Check for bad unary operators.
-if egrep -n -e 'if[ ]+-' $scripts; then
+if $EGREP -n -e 'if[ ]+-' $scripts; then
echo "use \`if test -X' instead of \`if -X'"
status=1
fi
# Check for using `[' instead of `test'.
-if egrep -n -e 'if[ ]+\[' $scripts; then
+if $EGREP -n -e 'if[ ]+\[' $scripts; then
echo "use \`if test' instead of \`if ['"
status=1
fi
-if egrep -n -e 'test[ ]+(![ ])?(-.[ ]+)?"?[.,_x]' $scripts; then
+if $EGREP -n -e 'test[ ]+(![ ])?(-.[ ]+)?"?[.,_x]' $scripts;
then
echo "use \`test \"X...\"' instead of \`test \"x...\"'"
status=1
fi
# Check for using test X... instead of test "X...
-if egrep -n -e 'test[ ]+(![ ])?(-.[ ]+)?X' $scripts; then
+if $EGREP -n -e 'test[ ]+(![ ])?(-.[ ]+)?X' $scripts; then
echo "use \`test \"X...\"' instead of \`test X'"
status=1
fi
# Check for using test $... instead of test "$...
-if egrep -n -e 'test[ ]+(![ ])?(-.[ ]+)?X?\$' $scripts; then
+if $EGREP -n -e 'test[ ]+(![ ])?(-.[ ]+)?X?\$' $scripts; then
echo "use \`test \"\$...\"' instead of \`test \$'"
status=1
fi
# Never use test -e.
-if egrep -n -e 'test[ ]+(![ ])?-e' $scripts; then
+if $EGREP -n -e 'test[ ]+(![ ])?-e' $scripts; then
echo "use \`test -f' instead of \`test -e'"
status=1
fi
# Check for problems with variable assignments.
-if egrep -n -e '[^ ]=[^ ].*(break|continue)' $scripts; then
+if $EGREP -n -e '[^ ]=[^ ].*(break|continue)' $scripts; then
echo "assignments on the same line as a \`break' or \`continue' may have no
effect"
status=1
fi
# Check for uses of Xsed without corresponding echo "X
-if egrep -n -e '\$Xsed' $scripts | egrep -v -n -e '\$echo \\*"X'; then
+if $EGREP -n -e '\$Xsed' $scripts | $EGREP -v -n -e '\$echo \\*"X'; then
echo "occurrences of \`\$Xsed\' without \`echo \"X\' on the same line"
status=1
fi
# Check for quotes within backquotes within quotes "`"bar"`"
-if egrep -n -e '"[^`"]*`[^"`]*"[^"`]*".*`[^`"]*"' $scripts | \
- egrep -v "### testsuite: skip nested quoting test$"; then
+if $EGREP -n -e '"[^`"]*`[^"`]*"[^"`]*".*`[^`"]*"' $scripts | \
+ $EGREP -v "### testsuite: skip nested quoting test$"; then
echo "nested quotes are dangerous"
status=1
fi
Index: tests/tagdemo-conf.test
===================================================================
RCS file: /cvsroot/libtool/libtool/tests/tagdemo-conf.test,v
retrieving revision 1.2
diff -p -u -r1.2 tagdemo-conf.test
--- tests/tagdemo-conf.test 6 Jun 2001 14:53:29 -0000 1.2
+++ tests/tagdemo-conf.test 24 Oct 2002 06:06:40 -0000
@@ -27,8 +27,8 @@ rm -f config.cache
echo "= Configuring in ../tagdemo (prefix=$prefix)"
CONFIG_SITE=/dev/null/config/site ${CONFIG_SHELL-/bin/sh}
$srcdir/../tagdemo/configure --srcdir=$srcdir/../tagdemo --prefix=$prefix ||
exit 1
-if egrep '^build_old_libs=yes' libtool > /dev/null &&
- egrep '^build_libtool_libs=yes' libtool > /dev/null; then :
+if grep '^build_old_libs=yes' libtool > /dev/null &&
+ grep '^build_libtool_libs=yes' libtool > /dev/null; then :
else rm -f Makefile && exit 77
fi
Index: tests/tagdemo-shared.test
===================================================================
RCS file: /cvsroot/libtool/libtool/tests/tagdemo-shared.test,v
retrieving revision 1.2
diff -p -u -r1.2 tagdemo-shared.test
--- tests/tagdemo-shared.test 6 Jun 2001 14:53:29 -0000 1.2
+++ tests/tagdemo-shared.test 24 Oct 2002 06:06:40 -0000
@@ -27,8 +27,8 @@ rm -f config.cache
echo "= Configuring in ../tagdemo (prefix=$prefix) with --disable-static"
CONFIG_SITE=/dev/null/config/site ${CONFIG_SHELL-/bin/sh}
$srcdir/../tagdemo/configure --srcdir=$srcdir/../tagdemo --prefix=$prefix
--disable-static || exit 1
-if egrep '^build_old_libs=no' libtool > /dev/null &&
- egrep '^build_libtool_libs=yes' libtool > /dev/null; then :
+if grep '^build_old_libs=no' libtool > /dev/null &&
+ grep '^build_libtool_libs=yes' libtool > /dev/null; then :
else rm -f Makefile && exit 77
fi
Index: tests/tagdemo-static.test
===================================================================
RCS file: /cvsroot/libtool/libtool/tests/tagdemo-static.test,v
retrieving revision 1.2
diff -p -u -r1.2 tagdemo-static.test
--- tests/tagdemo-static.test 6 Jun 2001 14:53:29 -0000 1.2
+++ tests/tagdemo-static.test 24 Oct 2002 06:06:40 -0000
@@ -27,8 +27,8 @@ rm -f config.cache
echo "= Configuring in ../tagdemo (prefix=$prefix) with --disable-shared"
CONFIG_SITE=/dev/null/config/site ${CONFIG_SHELL-/bin/sh}
$srcdir/../tagdemo/configure --srcdir=$srcdir/../tagdemo --prefix=$prefix
--disable-shared || exit 1
-if egrep '^build_old_libs=yes' libtool > /dev/null &&
- egrep '^build_libtool_libs=no' libtool > /dev/null; then :
+if grep '^build_old_libs=yes' libtool > /dev/null &&
+ grep '^build_libtool_libs=no' libtool > /dev/null; then :
else rm -f Makefile && exit 77
fi
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- libtool support for hosts with strict "grep", "test",
Paul Eggert <=