subversion-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rhuij...@apache.org
Subject svn commit: r1449424 - /subversion/trunk/build/generator/gen_win.py
Date Sat, 23 Feb 2013 23:05:52 GMT
Author: rhuijben
Date: Sat Feb 23 23:05:51 2013
New Revision: 1449424

URL: http://svn.apache.org/r1449424
Log:
* build/generator/gen_win.py
  (_find_sqlite): Following up on r1449422, fix error message. Also use the
    optional 4th component of the version for diagnostics.

Modified:
    subversion/trunk/build/generator/gen_win.py

Modified: subversion/trunk/build/generator/gen_win.py
URL: http://svn.apache.org/viewvc/subversion/trunk/build/generator/gen_win.py?rev=1449424&r1=1449423&r2=1449424&view=diff
==============================================================================
--- subversion/trunk/build/generator/gen_win.py (original)
+++ subversion/trunk/build/generator/gen_win.py Sat Feb 23 23:05:51 2013
@@ -1578,15 +1578,20 @@ class WinGeneratorBase(GeneratorBase):
     fp = open(header_file)
     txt = fp.read()
     fp.close()
-    vermatch = re.search(r'^\s*#define\s+SQLITE_VERSION\s+"(\d+)\.(\d+)\.(\d+)(?:\.\d)?"',
txt, re.M)
+    vermatch = re.search(r'^\s*#define\s+SQLITE_VERSION\s+"(\d+)\.(\d+)\.(\d+)(?:\.(\d))?"',
txt, re.M)
 
-    version = tuple(map(int, vermatch.groups()))
+    version = vermatch.groups()
+    
+    # Sqlite doesn't add patch numbers for their ordinary releases
+    if not version[3]:
+      version = version[0:3]
 
+    version = tuple(map(int, version))
 
-    self.sqlite_version = '%d.%d.%d' % version
+    self.sqlite_version = '.'.join(str(v) for v in version)
 
     if version < minimal_sqlite_version:
-      sys.stderr.write("ERROR: aprutil %s or higher is required "
+      sys.stderr.write("ERROR: sqlite %s or higher is required "
                        "(%s found)\n" % (
                           '.'.join(str(v) for v in minimal_sqlite_version),
                           self.sqlite_version))



Mime
View raw message