mirror of
https://github.com/MidnightCommander/mc
synced 2025-01-18 09:19:24 +03:00
* configure.in: Fix incorrect test for stdin support in grep -
it would always fail when configuring in an empty directory. Portability fixes - unset, backslashed space in here-documents. Eliminate all instances of "changeqoute".
This commit is contained in:
parent
f71979d546
commit
0152dda957
@ -1,5 +1,10 @@
|
|||||||
2001-05-26 Pavel Roskin <proski@gnu.org>
|
2001-05-26 Pavel Roskin <proski@gnu.org>
|
||||||
|
|
||||||
|
* configure.in: Fix incorrect test for stdin support in grep -
|
||||||
|
it would always fail when configuring in an empty directory.
|
||||||
|
Portability fixes - unset, backslashed space in here-documents.
|
||||||
|
Eliminate all instances of "changeqoute".
|
||||||
|
|
||||||
* configure.in: Define SCO_FLAVOR based on $host_os, not on the
|
* configure.in: Define SCO_FLAVOR based on $host_os, not on the
|
||||||
user choice.
|
user choice.
|
||||||
* acconfig.h: Changes for the above.
|
* acconfig.h: Changes for the above.
|
||||||
|
28
configure.in
28
configure.in
@ -513,31 +513,27 @@ dnl
|
|||||||
AC_CHECK_PROG(HAVE_FILECMD, file, true, false)
|
AC_CHECK_PROG(HAVE_FILECMD, file, true, false)
|
||||||
if $HAVE_FILECMD; then
|
if $HAVE_FILECMD; then
|
||||||
AC_MSG_CHECKING([for - option to file command])
|
AC_MSG_CHECKING([for - option to file command])
|
||||||
AC_CACHE_VAL(ac_cv_filestdin, [
|
AC_CACHE_VAL(ac_cv_filestdin, [[
|
||||||
cat > conftest.c <<EOF
|
cat > conftest.c <<\EOF
|
||||||
/* A comment */
|
/* A comment */
|
||||||
#if 0
|
#if 0
|
||||||
#endif
|
#endif
|
||||||
void main(void)
|
void main(void)
|
||||||
{ return; }
|
{ return; }
|
||||||
EOF
|
EOF
|
||||||
changequote(, )
|
cat > conftest.sed <<\EOF
|
||||||
cat > conftest.sed <<EOF
|
s/^[^:]*:[ ]*//
|
||||||
s/^[^:]*:[\ \ ]*//
|
s/[ ]*$//
|
||||||
s/[\ \ ]*$//
|
|
||||||
EOF
|
EOF
|
||||||
filehyphen_1=`file conftest.c 2>/dev/null | sed -f conftest.sed`
|
filehyphen_1=`file conftest.c 2>/dev/null | sed -f conftest.sed`
|
||||||
filehyphen_2=`cat conftest.c | file - 2>/dev/null | sed -f conftest.sed`
|
filehyphen_2=`cat conftest.c | file - 2>/dev/null | sed -f conftest.sed`
|
||||||
if test "$filehyphen_1" = "$filehyphen_2"; then
|
if test "x$filehyphen_1" = "x$filehyphen_2"; then
|
||||||
ac_cv_filestdin=yes
|
ac_cv_filestdin=yes
|
||||||
else
|
else
|
||||||
ac_cv_filestdin=no
|
ac_cv_filestdin=no
|
||||||
fi
|
fi
|
||||||
changequote([, ])
|
|
||||||
rm conftest.c conftest.sed
|
rm conftest.c conftest.sed
|
||||||
unset filehyphen_1
|
]])
|
||||||
unset filehyphen_2
|
|
||||||
])
|
|
||||||
|
|
||||||
if test x$ac_cv_filestdin = xyes; then
|
if test x$ac_cv_filestdin = xyes; then
|
||||||
AC_DEFINE(FILE_STDIN)
|
AC_DEFINE(FILE_STDIN)
|
||||||
@ -571,7 +567,7 @@ dnl Check to see if grep program allowes dash to denote stdin
|
|||||||
dnl
|
dnl
|
||||||
AC_MSG_CHECKING([for - option to grep command])
|
AC_MSG_CHECKING([for - option to grep command])
|
||||||
AC_CACHE_VAL(ac_cv_grep_stdin, [
|
AC_CACHE_VAL(ac_cv_grep_stdin, [
|
||||||
grep ac_cv_grep_stdin - > /dev/null 2>&1 < ./configure
|
echo "grep_test" | grep grep_test - >/dev/null 2>&1
|
||||||
if test $? = 0; then
|
if test $? = 0; then
|
||||||
ac_cv_grep_stdin=yes
|
ac_cv_grep_stdin=yes
|
||||||
else
|
else
|
||||||
@ -841,16 +837,12 @@ VERSION:NCURSES_VERSION
|
|||||||
EOF
|
EOF
|
||||||
if (eval "$ac_cpp conftest.$ac_ext") 2>&AC_FD_CC |
|
if (eval "$ac_cpp conftest.$ac_ext") 2>&AC_FD_CC |
|
||||||
egrep "VERSION:" >conftest.out 2>&1; then
|
egrep "VERSION:" >conftest.out 2>&1; then
|
||||||
changequote(,)dnl
|
ncurses_version=`cat conftest.out|sed -e 's/^[[^"]]*"//' -e 's/".*//'`
|
||||||
ncurses_version=`cat conftest.out|sed -e 's/^[^"]*"//' -e 's/".*//'`
|
|
||||||
changequote([,])dnl
|
|
||||||
fi
|
fi
|
||||||
rm -rf conftext*
|
rm -rf conftext*
|
||||||
AC_MSG_RESULT([$ncurses_version])
|
AC_MSG_RESULT([$ncurses_version])
|
||||||
case "$ncurses_version" in
|
case "$ncurses_version" in
|
||||||
changequote(,)dnl
|
4.[[01]])
|
||||||
4.[01])
|
|
||||||
changequote([,])dnl
|
|
||||||
AC_DEFINE(NCURSES_970530,2)
|
AC_DEFINE(NCURSES_970530,2)
|
||||||
;;
|
;;
|
||||||
1.9.9g)
|
1.9.9g)
|
||||||
|
Loading…
Reference in New Issue
Block a user