Author: cazfi
Date: Mon Jan  4 13:34:54 2016
New Revision: 31344

URL: http://svn.gna.org/viewcvs/freeciv?rev=31344&view=rev
Log:
Made autogen.sh version detection to work even when some perl-based tool has
internal problems resulting in warnings being printed on launch.

Reported by Christian Knoke <chrisk>

See bug #24259

Modified:
    branches/S2_5/autogen.sh

Modified: branches/S2_5/autogen.sh
URL: 
http://svn.gna.org/viewcvs/freeciv/branches/S2_5/autogen.sh?rev=31344&r1=31343&r2=31344&view=diff
==============================================================================
--- branches/S2_5/autogen.sh    (original)
+++ branches/S2_5/autogen.sh    Mon Jan  4 13:34:54 2016
@@ -177,8 +177,8 @@
     return 1
   }
 
-  # the following line is carefully crafted sed magic
-  pkg_version=`$PACKAGE --version 2>&1|head -n 1|sed 
's/([^)]*)//g;s/^[a-zA-Z\.\ \-]*//;s/ .*$//'`
+  # The following line is carefully crafted sed magic
+  pkg_version=`$PACKAGE --version 2>&1|grep -v " line " |head -n 1|sed 
's/([^)]*)//g;s/^[a-zA-Z\.\ \-]*//;s/ .*$//'`
   debug "pkg_version $pkg_version"
   pkg_major=`echo $pkg_version | cut -d. -f1`
   pkg_minor=`echo $pkg_version | sed s/[-,a-z,A-Z].*// | cut -d. -f2`
@@ -188,7 +188,7 @@
 
   debug "found major $pkg_major minor $pkg_minor micro $pkg_micro"
 
-  #start checking the version
+  # Start checking the version
   if [ "$pkg_major" -lt "$MAJOR" ]; then
     WRONG=1
   elif [ "$pkg_major" -eq "$MAJOR" ]; then


_______________________________________________
Freeciv-commits mailing list
Freeciv-commits@gna.org
https://mail.gna.org/listinfo/freeciv-commits

Reply via email to