From mboxrd@z Thu Jan 1 00:00:00 1970 Return-path: Received: from mail-he1eur04on0600.outbound.protection.outlook.com ([2a01:111:f400:fe0d::600] helo=EUR04-HE1-obe.outbound.protection.outlook.com) by metis.ext.pengutronix.de with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1iwpkg-0004cJ-AH for ptxdist@pengutronix.de; Wed, 29 Jan 2020 16:59:42 +0100 Received: from nbmx01.hytera.de (unknown [172.21.102.22]) by ibmx32.hytera.de (Postfix) with ESMTP id E5C8EAD8F for ; Wed, 29 Jan 2020 16:59:26 +0100 (CET) References: <20200107184021.4649-1-christian.hermann@hytera.de> <20200124163027.GA15722@pengutronix.de> From: Christian Hermann Message-ID: Date: Wed, 29 Jan 2020 16:59:34 +0100 MIME-Version: 1.0 In-Reply-To: <20200124163027.GA15722@pengutronix.de> Content-Language: en-US Subject: Re: [ptxdist] [PATCH] configure: fix regex for determining host tool versions List-Id: PTXdist Development Mailing List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: ptxdist@pengutronix.de Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset="us-ascii"; Format="flowed" Errors-To: ptxdist-bounces@pengutronix.de Sender: "ptxdist" To: ptxdist@pengutronix.de You're right, the patch is bogus. I cannot remember nor find the case where I was bit by original issue (failing version comparison). Until then, please discard this. On 24.01.20 17:30, Michael Olbrich wrote: > On Tue, Jan 07, 2020 at 07:40:21PM +0100, Christian Hermann wrote: >> Previously, all of those _VERSION were empty on my system >> >> Signed-off-by: Christian Hermann >> --- >> configure.ac | 12 ++++++------ >> 1 file changed, 6 insertions(+), 6 deletions(-) >> >> diff --git a/configure.ac b/configure.ac >> index 0549c38da..db2d85f77 100644 >> --- a/configure.ac >> +++ b/configure.ac >> @@ -160,7 +160,7 @@ if test -z "$SED"; then >> fi >> >> AC_MSG_CHECKING([sed version]) >> -SED_VERSION=`$SED --version 2>/dev/null | $SED -ne "1 s/.*GNU.*\s\([[0-9\+\.]]\+\).*/\1/p"` >> +SED_VERSION=`$SED --version 2>/dev/null | $SED -ne "1 s/.*GNU.*\s\([0-9\+\.]\+\).*/\1/p"` > > This makes no sense. The '[' must be escaped for m4. How does this line > look like in the generated configure script for you? (with and without this > change). > > Michael > >> case "$SED_VERSION" in >> 3.*) AC_MSG_ERROR([we need at least GNU sed 4.x but found $SED_VERSION]) ;; >> 4.*) ;; >> @@ -209,7 +209,7 @@ dnl Check for awk >> AC_PROG_AWK >> AC_PATH_PROGS(AWK, ${AWK},) >> AC_MSG_CHECKING([awk version]) >> -AWK_VERSION=`$AWK --version 2>/dev/null | $SED -ne "s/GNU [[Aa]]wk \([[0-9\.]]*\)/\1/p"` >> +AWK_VERSION=`$AWK --version 2>/dev/null | $SED -ne "s/GNU [Aa]wk \([0-9\.]*\)/\1/p"` >> case "$AWK_VERSION" in >> "") AC_MSG_ERROR([we need GNU awk]) ;; >> *) ;; >> @@ -242,7 +242,7 @@ else >> fi >> >> AC_MSG_CHECKING([yacc/bison version]) >> -YACC_VERSION=`$YACC --version 2>/dev/null | $SED -ne "s/.*GNU Bison.* \([[0-9.]]*\).*/\1/p"` >> +YACC_VERSION=`$YACC --version 2>/dev/null | $SED -ne "s/.*GNU Bison.* \([0-9.]*\).*/\1/p"` >> case "${YACC_VERSION}" in >> 1.*) >> AC_MSG_ERROR([$YACC_VERSION, your bison version is too old, install 2.3 or sth. like that]) ;; >> @@ -283,7 +283,7 @@ if test -z "$WGET"; then >> fi >> >> AC_MSG_CHECKING([find version]) >> -FIND_VERSION=`$GNU_find --version 2>/dev/null | $SED -ne "s/.*\s\+\([[0-9]]\+\.[[0-9]]\+\.[[0-9]]\+\).*$/\1/p"` >> +FIND_VERSION=`$GNU_find --version 2>/dev/null | $SED -ne "s/.*\s\+\([0-9]\+\.[0-9]\+\.[0-9]\+\).*$/\1/p"` >> case "$FIND_VERSION" in >> 4.*) ;; >> *) AC_MSG_ERROR([we need at least GNU find 4.x]) ;; >> @@ -295,7 +295,7 @@ AC_PATH_PROGS(MAKE, gmake gnumake make,, $PATH) >> if test -z "$MAKE"; then >> AC_MSG_ERROR([make could not be found, please install]) >> fi >> -MAKE_VERSION=`$MAKE --version 2>/dev/null | $SED -ne "s/^GNU Make \([[0-9]]\+\.[[0-9.]]\+\).*$/\1/p"` >> +MAKE_VERSION=`$MAKE --version 2>/dev/null | $SED -ne "s/^GNU Make \([0-9]\+\.[0-9.]\+\).*$/\1/p"` >> MINOR_MAKE_VERSION="${MAKE_VERSION#*.}" >> MAJOR_MAKE_VERSION="${MAKE_VERSION%.*}" >> if test -z "${MAJOR_MAKE_VERSION}" -o -z "${MINOR_MAKE_VERSION}" ; then >> @@ -347,7 +347,7 @@ dnl >> dnl Check for Python 2.x >> dnl >> AC_MSG_CHECKING([Python version]) >> -PYTHON_VERSION=`$PYTHON --version 2>&1 | $SED -ne "1 s/Python \([[0-9\+\.]]\+\).*/\1/p"` >> +PYTHON_VERSION=`$PYTHON --version 2>&1 | $SED -ne "1 s/Python \([0-9\+\.]\+\).*/\1/p"` >> case "$PYTHON_VERSION" in >> 2.*) ;; >> *) AC_MSG_ERROR([we need Python version 2.x but found $PYTHON_VERSION]) ;; >> -- >> 2.24.1 >> >> >> _______________________________________________ >> ptxdist mailing list >> ptxdist@pengutronix.de >> > _______________________________________________ ptxdist mailing list ptxdist@pengutronix.de