couchdb-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From nsla...@apache.org
Subject svn commit: r662528 - /incubator/couchdb/trunk/configure.ac
Date Mon, 02 Jun 2008 19:29:19 GMT
Author: nslater
Date: Mon Jun  2 12:29:19 2008
New Revision: 662528

URL: http://svn.apache.org/viewvc?rev=662528&view=rev
Log:
correct Erlang version checking

Modified:
    incubator/couchdb/trunk/configure.ac

Modified: incubator/couchdb/trunk/configure.ac
URL: http://svn.apache.org/viewvc/incubator/couchdb/trunk/configure.ac?rev=662528&r1=662527&r2=662528&view=diff
==============================================================================
--- incubator/couchdb/trunk/configure.ac (original)
+++ incubator/couchdb/trunk/configure.ac Mon Jun  2 12:29:19 2008
@@ -104,8 +104,16 @@
     AC_MSG_ERROR([Could not find the `erl' executable. Is Erlang installed?])
 fi
 
-if test $(${ERL} -version 2>&1 | sed "s/[[^0-9]]//g") -le 550; then
-    AC_MSG_ERROR([The installed Erlang version is less than 5.5.0 (R11B).])
+erlang_version_error="The installed Erlang version is less than 5.5.0 (R11B)."
+
+version=$(${ERL} -version 2>&1 | ${SED} "s/[[^0-9]]/ /g")
+
+if test $(echo $version | ${AWK} "{print \$1}") -lt 5; then
+    AC_MSG_ERROR([$erlang_version_error])
+fi
+
+if test $(echo $version | ${AWK} "{print \$2}") -lt 5; then
+    AC_MSG_ERROR([$erlang_version_error])
 fi
 
 AC_PATH_PROG([ERLC], [erlc])



Mime
View raw message