summaryrefslogtreecommitdiff
path: root/var
diff options
context:
space:
mode:
Diffstat (limited to 'var')
-rw-r--r--var/spack/repos/builtin/packages/gdal/package.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/var/spack/repos/builtin/packages/gdal/package.py b/var/spack/repos/builtin/packages/gdal/package.py
index e5a727b66d..a24d7d07da 100644
--- a/var/spack/repos/builtin/packages/gdal/package.py
+++ b/var/spack/repos/builtin/packages/gdal/package.py
@@ -165,6 +165,12 @@ class Gdal(AutotoolsPackage):
conflicts('+mdb', when='~java', msg='MDB driver requires Java')
+ executables = ['^gdal-config$']
+
+ @classmethod
+ def determine_version(cls, exe):
+ return Executable(exe)('--version', output=str, error=str).rstrip()
+
def setup_build_environment(self, env):
# Needed to install Python bindings to GDAL installation
# prefix instead of Python installation prefix.