summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlexander Aring <alex.aring@googlemail.com>2013-01-07 23:36:05 +0100
committerMichael Olbrich <m.olbrich@pengutronix.de>2013-03-04 17:49:15 +0100
commitbee9759dce2607c13ed06f9ab033e4168500c727 (patch)
tree76b6a0f5ee0ac34b4a71ac25f04692568fc37488
parent4b8e6c83fdb425de99334b61d9ae07921f5a04b0 (diff)
downloadptxdist-bee9759dce2607c13ed06f9ab033e4168500c727.tar.gz
ptxdist-bee9759dce2607c13ed06f9ab033e4168500c727.tar.xz
configure.ac: change regex for sed versionptxdist-2012.12.1stable/ptxdist-2012.12.x
Change regex for sed version in configure.ac. This regex will match only on the first line and doesn't look for a 'version' pattern which is not available in sed version 4.2.2. The new regex will match in the first line of 'sed --version' in a pattern which starts with random character sequence(or zero) followed by whitespace character and several digits of pattern x.x....x which x is a number. This pattern will be save in the SED_VERSION variable. Signed-off-by: Alexander Aring <alex.aring@gmail.com> [mkl: add match for GNU in regex] Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de> (cherry picked from commit 2a89985c97422af3569eb6d268e3ccdc9c3fb0e5) Signed-off-by: Michael Olbrich <m.olbrich@pengutronix.de>
-rw-r--r--configure.ac2
1 files changed, 1 insertions, 1 deletions
diff --git a/configure.ac b/configure.ac
index d4c83b8a6..b6dc16dcf 100644
--- a/configure.ac
+++ b/configure.ac
@@ -116,7 +116,7 @@ if test -z "$SED"; then
fi
AC_MSG_CHECKING([sed version])
-SED_VERSION=`$SED --version 2>/dev/null | $SED -ne "s/.*version \([[0-9\.]]*\)/\1/p"`
+SED_VERSION=`$SED --version 2>/dev/null | $SED -ne "1 s/.*GNU.*\s\([[0-9\+\.]]\+\).*/\1/p"`
case "$SED_VERSION" in
3.*) AC_MSG_ERROR([we need at least GNU sed 4.x but found $SED_VERSION]) ;;
4.*) ;;