diff options
Diffstat (limited to 'var')
-rw-r--r-- | var/spack/repos/builtin/packages/libbeagle/package.py | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/var/spack/repos/builtin/packages/libbeagle/package.py b/var/spack/repos/builtin/packages/libbeagle/package.py index 50b0fd4f34..0e6dc470d2 100644 --- a/var/spack/repos/builtin/packages/libbeagle/package.py +++ b/var/spack/repos/builtin/packages/libbeagle/package.py @@ -25,8 +25,10 @@ class Libbeagle(AutotoolsPackage, CudaPackage): depends_on('subversion', type='build') depends_on('pkgconfig', type='build') depends_on('java', type='build') + depends_on('opencl', when='+opencl') cuda_arch_values = CudaPackage.cuda_arch_values + variant('opencl', default=False, description='Include OpenCL (GPU) support') variant( 'cuda_arch', description='CUDA architecture', @@ -54,6 +56,9 @@ class Libbeagle(AutotoolsPackage, CudaPackage): filter_file('-L$with_cuda/lib', '-L$with_cuda/lib64/stubs', 'configure.ac', string=True) + def autoreconf(self, spec, prefix): + which('bash')('autogen.sh') + def configure_args(self): args = [ # Since spack will inject architecture flags turn off -march=native @@ -62,8 +67,13 @@ class Libbeagle(AutotoolsPackage, CudaPackage): ] if '+cuda' in self.spec: - args.append('--with-cuda=%s' % self.spec['cuda'].prefix) + args.append('--with-cuda={0}'.format(self.spec['cuda'].prefix)) else: args.append('--without-cuda') + if '+opencl' in self.spec: + args.append('--with-opencl={0}'.format(self.spec['opencl'].prefix)) + else: + args.append('--without-opencl') + return args |