diff options
author | Bruno Haible <bruno@clisp.org> | 2006-06-09 20:23:12 +0000 |
---|---|---|
committer | Bruno Haible <bruno@clisp.org> | 2009-06-23 12:13:22 +0200 |
commit | c8ecdf93c75e0cd190c9db00de3bd67801c8f4cf (patch) | |
tree | a3d186d086627085bf4c8cfae249ab068e6bec45 /gettext-tools/tests/lang-php | |
parent | b83b91e1eef5d017dde3b37f26c1e75ed9652f53 (diff) | |
download | external_gettext-c8ecdf93c75e0cd190c9db00de3bd67801c8f4cf.zip external_gettext-c8ecdf93c75e0cd190c9db00de3bd67801c8f4cf.tar.gz external_gettext-c8ecdf93c75e0cd190c9db00de3bd67801c8f4cf.tar.bz2 |
Fix version recognition.
Diffstat (limited to 'gettext-tools/tests/lang-php')
-rwxr-xr-x | gettext-tools/tests/lang-php | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/gettext-tools/tests/lang-php b/gettext-tools/tests/lang-php index 987274c..a42f944 100755 --- a/gettext-tools/tests/lang-php +++ b/gettext-tools/tests/lang-php @@ -66,9 +66,12 @@ test -d fr/LC_MESSAGES || mkdir fr/LC_MESSAGES ${MSGFMT} -o fr/LC_MESSAGES/prog.mo fr.po # Test for presence of php version 4.0 or newer. -case `(php -v) 2>/dev/null` in +(php -v) >/dev/null 2>/dev/null +test $? -le 1 \ + || { echo "Skipping test: php not found"; rm -fr $tmpfiles; exit 77; } +case `php -v | sed -n -e 1p | sed -e 's/^[^0-9]*//'` in [4-9].*) ;; - *) echo "Skipping test: php not found or too old"; rm -fr $tmpfiles; exit 77;; + *) echo "Skipping test: php version too old"; rm -fr $tmpfiles; exit 77;; esac # Test which of the fr_FR locales are installed. |