Add GDAL 3.0.0 (#11733)
* Add GDAL 3.0.0 * Clarify PROJ version requirements
This commit is contained in:
parent
17f20d0f32
commit
de51be45b9
1 changed files with 31 additions and 16 deletions
|
@ -18,7 +18,7 @@ class Gdal(AutotoolsPackage):
|
|||
"""
|
||||
|
||||
homepage = "http://www.gdal.org/"
|
||||
url = "http://download.osgeo.org/gdal/2.4.0/gdal-2.4.0.tar.xz"
|
||||
url = "http://download.osgeo.org/gdal/3.0.0/gdal-3.0.0.tar.xz"
|
||||
list_url = "http://download.osgeo.org/gdal/"
|
||||
list_depth = 1
|
||||
|
||||
|
@ -29,6 +29,7 @@ class Gdal(AutotoolsPackage):
|
|||
'osgeo.gdal_array', 'osgeo.gdalconst'
|
||||
]
|
||||
|
||||
version('3.0.0', sha256='ad316fa052d94d9606e90b20a514b92b2dd64e3142dfdbd8f10981a5fcd5c43e')
|
||||
version('2.4.1', sha256='fd51b4900b2fc49b98d8714f55fc8a78ebfd07218357f93fb796791115a5a1ad')
|
||||
version('2.4.0', sha256='c3791dcc6d37e59f6efa86e2df2a55a4485237b0a48e330ae08949f0cdf00f27')
|
||||
version('2.3.3', sha256='c3635e41766a648f945d235b922e3c5306e26a2ee5bbd730d2181e242f5f46fe')
|
||||
|
@ -85,13 +86,14 @@ class Gdal(AutotoolsPackage):
|
|||
# GDAL depends on GNUmake on Unix platforms.
|
||||
# https://trac.osgeo.org/gdal/wiki/BuildingOnUnix
|
||||
depends_on('gmake', type='build')
|
||||
depends_on('pkgconfig', type='build')
|
||||
depends_on('pkgconfig@0.25:', type='build')
|
||||
|
||||
# Required dependencies
|
||||
depends_on('libtiff@3.6.0:') # 3.9.0+ needed to pass testsuite
|
||||
depends_on('libgeotiff@1.2.1:')
|
||||
depends_on('libgeotiff@1.5:', when='@3:')
|
||||
depends_on('json-c', when='@2.3:')
|
||||
depends_on('json-c@0.12.1', when='@:2.2.99')
|
||||
depends_on('json-c@0.12.1', when='@:2.2')
|
||||
|
||||
# Optional dependencies
|
||||
depends_on('libtool', type='build', when='+libtool')
|
||||
|
@ -123,7 +125,10 @@ class Gdal(AutotoolsPackage):
|
|||
depends_on('opencl', when='+opencl')
|
||||
depends_on('poppler', when='+poppler')
|
||||
depends_on('poppler@:0.63', when='@:2.3.0 +poppler')
|
||||
depends_on('proj', when='+proj @2.3:')
|
||||
depends_on('proj@:4', when='+proj @2.3.0:2.3.999')
|
||||
depends_on('proj@:5', when='+proj @2.4.0:2.4.999')
|
||||
depends_on('proj@:6', when='+proj @2.5:2.999')
|
||||
depends_on('proj@6:', when='+proj @3:')
|
||||
depends_on('perl', type=('build', 'run'), when='+perl')
|
||||
depends_on('python', type=('build', 'link', 'run'), when='+python')
|
||||
# swig/python/setup.py
|
||||
|
@ -164,6 +169,28 @@ def configure_args(self):
|
|||
'--with-libjson-c={0}'.format(spec['json-c'].prefix),
|
||||
]
|
||||
|
||||
# Optional dependencies
|
||||
if spec.satisfies('@3:'):
|
||||
args.extend([
|
||||
'--disable-driver-bsb',
|
||||
'--disable-driver-mrf',
|
||||
])
|
||||
|
||||
if '+grib' in spec:
|
||||
args.append('--enable-driver-grib')
|
||||
else:
|
||||
args.append('--disable-driver-grib')
|
||||
else:
|
||||
args.append('--without-bsb')
|
||||
|
||||
if '+grib' in spec:
|
||||
args.append('--with-grib=yes')
|
||||
else:
|
||||
args.append('--with-grib=no')
|
||||
|
||||
if spec.satisfies('@2.3:'):
|
||||
args.append('--with-mrf=no')
|
||||
|
||||
if spec.satisfies('@2.3:'):
|
||||
if '+zstd' in spec:
|
||||
args.append('--with-zstd={0}'.format(spec['zstd'].prefix))
|
||||
|
@ -172,10 +199,6 @@ def configure_args(self):
|
|||
|
||||
if '+proj' in spec:
|
||||
args.append('--with-proj={0}'.format(spec['proj'].prefix))
|
||||
if spec.satisfies('^proj@5.0:5.999'):
|
||||
args.append('--with-proj5-api=yes')
|
||||
else:
|
||||
args.append('--with-proj5-api=no')
|
||||
else:
|
||||
args.append('--with-proj=no')
|
||||
|
||||
|
@ -203,7 +226,6 @@ def configure_args(self):
|
|||
else:
|
||||
args.append('--with-kea=no')
|
||||
|
||||
# Optional dependencies
|
||||
if '+libtool' in spec:
|
||||
args.append('--with-libtool=yes')
|
||||
else:
|
||||
|
@ -375,11 +397,6 @@ def configure_args(self):
|
|||
else:
|
||||
args.append('--with-armadillo=no')
|
||||
|
||||
if '+grib' in spec:
|
||||
args.append('--with-grib=yes')
|
||||
else:
|
||||
args.append('--with-grib=no')
|
||||
|
||||
# TODO: add packages for these dependencies
|
||||
args.extend([
|
||||
# https://trac.osgeo.org/gdal/wiki/GRASS
|
||||
|
@ -403,7 +420,6 @@ def configure_args(self):
|
|||
'--with-mrsid_lidar=no',
|
||||
# https://trac.osgeo.org/gdal/wiki/MSG
|
||||
'--with-msg=no',
|
||||
'--with-bsb=no',
|
||||
# https://trac.osgeo.org/gdal/wiki/Oracle
|
||||
'--with-oci=no',
|
||||
'--with-mysql=no',
|
||||
|
@ -437,7 +453,6 @@ def configure_args(self):
|
|||
# https://trac.osgeo.org/gdal/wiki/DxfDwg
|
||||
'--with-teigha=no',
|
||||
'--with-sfcgal=no',
|
||||
'--with-mrf=no',
|
||||
])
|
||||
|
||||
# TODO: add packages for these dependencies (only for 2.1 and newer)
|
||||
|
|
Loading…
Reference in a new issue