Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

handle broken mapnik-config version better - refs #94

  • Loading branch information...
commit b5d3f1517f7886eca90c43b94573bac81573d113 1 parent fb65a04
@springmeyer springmeyer authored
Showing with 10 additions and 7 deletions.
  1. +10 −7 wscript
View
17 wscript
@@ -32,14 +32,17 @@ def write_mapnik_settings(fonts='undefined',input_plugins='undefined'):
def ensure_min_mapnik_version(conf,min_version='2.1.0'):
found_version = popen("%s --version" % conf.env['MAPNIK_CONFIG']).readline().strip().replace('-pre','')
- f_parts = found_version.split('.')
- found_version_num = (f_parts[0]*100000)+(f_parts[1]*100)+f_parts[2]
- m_parts = min_version.split('.')
- min_version_num = (m_parts[0]*100000)+(m_parts[1]*100)+m_parts[2]
- if found_version_num == min_version_num:
- Utils.pprint('GREEN', 'Sweet, found compatible mapnik version %s (via mapnik-config)' % (found_version))
+ if not found_version:
+ Utils.pprint('RED',"Warning: Incompatible libmapnik version found (using mapnik-config --version), this 'node-mapnik' requires 'mapnik %s'" % min_version)
else:
- Utils.pprint('RED',"Warning: Incompatible libmapnik version found, this 'node-mapnik' requires 'mapnik %s'" % min_version)
+ f_parts = found_version.split('.')
+ found_version_num = (f_parts[0]*100000)+(f_parts[1]*100)+f_parts[2]
+ m_parts = min_version.split('.')
+ min_version_num = (m_parts[0]*100000)+(m_parts[1]*100)+m_parts[2]
+ if found_version_num == min_version_num:
+ Utils.pprint('GREEN', 'Sweet, found compatible mapnik version %s (via mapnik-config)' % (found_version))
+ else:
+ Utils.pprint('RED',"Warning: Incompatible libmapnik version found (using mapnik-config --version), this 'node-mapnik' requires 'mapnik %s'" % min_version)
def set_options(opt):

0 comments on commit b5d3f15

Please sign in to comment.
Something went wrong with that request. Please try again.