easyblock = 'ConfigureMake'

name = 'GEOS'
version = '3.5.0'

homepage = 'http://trac.osgeo.org/geos'
description = """GEOS (Geometry Engine - Open Source) is a C++ port of the  Java Topology Suite (JTS)"""

toolchain = {'name': 'intel', 'version': '2015b'}

source_urls = ['http://download.osgeo.org/geos/']
sources = [SOURCELOWER_TAR_BZ2]

pyver = '2.7.10'
pyshortver = '.'.join(pyver.split('.')[0:2])
versionsuffix = '-Python-%s' % pyver

dependencies = [('Python', pyver)]

builddependencies = [('SWIG', '3.0.7', versionsuffix)]

configopts = '--enable-python'

modextrapaths = {'PYTHONPATH': 'lib/python%s/site-packages' % pyshortver}

sanity_check_paths = {
    'files': ['bin/geos-config', 'lib/libgeos.%s' % SHLIB_EXT, 'lib/libgeos.a', 'include/geos.h'],
    'dirs': ['lib/python%s/site-packages/geos' % pyshortver]
}

moduleclass = 'math'
