summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--var/spack/repos/builtin/packages/pktools/package.py42
1 files changed, 42 insertions, 0 deletions
diff --git a/var/spack/repos/builtin/packages/pktools/package.py b/var/spack/repos/builtin/packages/pktools/package.py
new file mode 100644
index 0000000000..db60c3ddc8
--- /dev/null
+++ b/var/spack/repos/builtin/packages/pktools/package.py
@@ -0,0 +1,42 @@
+# Copyright 2013-2019 Lawrence Livermore National Security, LLC and other
+# Spack Project Developers. See the top-level COPYRIGHT file for details.
+#
+# SPDX-License-Identifier: (Apache-2.0 OR MIT)
+
+
+from spack import *
+
+
+class Pktools(CMakePackage):
+ """Processing Kernel for geospatial data"""
+
+ homepage = "http://pktools.nongnu.org/html/index.html"
+ url = "http://download.savannah.gnu.org/releases/pktools/pktools-2.6.7.tar.gz"
+
+ version('2.6.7.1', sha256='519b6a500ce3c5ef3793c1cda1f5377f13b7d7591b5ccc376b2bd1de4bd4f7e5')
+ version('2.6.7', sha256='f566647e93037cc01cebfe17ea554d798177fe5081887c70223dcca817f4fe7f')
+
+ variant('fann', default=True, description='Build with libfann to enable related programs')
+ variant('liblas', default=False, description='Build with libLAS support')
+
+ depends_on('gdal')
+ depends_on('gsl')
+ depends_on('armadillo')
+ depends_on('nlopt')
+ depends_on('boost')
+ depends_on('fann', when='+fann')
+ depends_on('liblas', when='+liblas')
+
+ def cmake_args(self):
+ args = []
+ args.append('-DCMAKE_CXX_STANDARD=11')
+ args.append('-DPKTOOLS_WITH_UTILITIES=ON')
+ if '+fann' in self.spec:
+ args.append('-DBUILD_WITH_FANN=ON')
+ else:
+ args.append('-DBUILD_WITH_FANN=OFF')
+ if '+liblas' in self.spec:
+ args.append('-DBUILD_WITH_LIBLAS=ON')
+ else:
+ args.append('-DBUILD_WITH_LIBLAS=OFF')
+ return args