summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authortruelight <truelight@openttd.org>2007-02-19 18:47:55 +0000
committertruelight <truelight@openttd.org>2007-02-19 18:47:55 +0000
commit25b7ff3d3b9e8007114607c30267b259af4492da (patch)
tree9c3d7fa8cbcdaa87c0f2b831e4ff876a841aa0f1
parent246ea5b195b8715599264578124a74d78f2bd2d9 (diff)
downloadopenttd-25b7ff3d3b9e8007114607c30267b259af4492da.tar.xz
(svn r8812) -Revert r7880: those changes assumed a GNU-grep, which isn't always available. Reverted back to a bit more ugly way of writing greps, but at least they are not bound to the laws of GNU.
-rw-r--r--config.lib6
1 files changed, 3 insertions, 3 deletions
diff --git a/config.lib b/config.lib
index 6f9840681..80c8231bd 100644
--- a/config.lib
+++ b/config.lib
@@ -291,19 +291,19 @@ check_params() {
# Check if all params have valid values
# Endian only allows AUTO, LE and, BE
- if ! echo $endian | grep -Eq "^(AUTO|LE|BE)$"; then
+ if [ -z "`echo $endian | grep '^AUTO$\|^LE$\|^BE$'`" ]; then
echo "configure: error: invalid option --endian=$endian"
echo " Available options are: --endian=[AUTO|LE|BE]"
exit 1
fi
# OS only allows DETECT, UNIX, OSX, FREEBSD, MORPHOS, BEOS, SUNOS, CYGWIN, MINGW, OS2, WINCE, and PSP
- if ! echo $os | grep -Eq "^(DETECT|UNIX|OSX|FREEBSD|MORPHOS|BEOS|SUNOS|CYGWIN|MINGW|OS2|WINCE|PSP)$"; then
+ if [ -z "`echo $os | grep '^DETECT$\|^UNIX$\|^OSX$\|^FREEBSD$\|^MORPHOS$\|^BEOS$\|^SUNOS$\|^CYGWIN$\|^MINGW$\|^OS2$\|^WINCE$\|^PSP$'`" ]; then
echo "configure: error: invalid option --os=$os"
echo " Available options are: --os=[DETECT|UNIX|OSX|FREEBSD|MORPHOS|BEOS|SUNOS|CYGWIN|MINGW|OS2|WINCE|PSP]"
exit 1
fi
# enable_debug should be between 0 and 4
- if ! echo $enable_debug | grep -q "^[0123]$"; then
+ if [ -z "`echo $enable_debug | grep '^[0123]$'`" ]; then
echo "configure: error: invalid option --enable-debug=$enable_debug"
echo " Available options are: --enable-debug[=0123]"
exit 1