diff options
author | iarspider <iarspider@gmail.com> | 2022-05-04 20:19:43 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-05-04 11:19:43 -0700 |
commit | 0be5dea13f63b8a9c51a7dd68fb0146f711a38d9 (patch) | |
tree | 704c962e968b62ca8f11e8e9f1ccce541f57789e /var | |
parent | b6f2a70f7b6db98b52aa6cf743bfc4b4a949281c (diff) | |
download | spack-0be5dea13f63b8a9c51a7dd68fb0146f711a38d9.tar.gz spack-0be5dea13f63b8a9c51a7dd68fb0146f711a38d9.tar.bz2 spack-0be5dea13f63b8a9c51a7dd68fb0146f711a38d9.tar.xz spack-0be5dea13f63b8a9c51a7dd68fb0146f711a38d9.zip |
Fix professor recipe (#30002)
* [WIP] Cleanup professor dependencies
* Add dependency on ROOT
* Remove direct dependency on wxwidgets
* `prof-I` tool requires matplotlib with wxwidgets backend, made that optional
* Update package.py
* Update package.py (#38)
* Update package.py
* Update package.py
Diffstat (limited to 'var')
-rw-r--r-- | var/spack/repos/builtin/packages/professor/package.py | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/var/spack/repos/builtin/packages/professor/package.py b/var/spack/repos/builtin/packages/professor/package.py index 45770092bc..4f3ef78154 100644 --- a/var/spack/repos/builtin/packages/professor/package.py +++ b/var/spack/repos/builtin/packages/professor/package.py @@ -2,6 +2,7 @@ # Spack Project Developers. See the top-level COPYRIGHT file for details. # # SPDX-License-Identifier: (Apache-2.0 OR MIT) +import os from spack import * @@ -16,13 +17,24 @@ class Professor(Package): version('2.3.3', sha256='60c5ba00894c809e2c31018bccf22935a9e1f51c0184468efbdd5d27b211009f') - depends_on('wxwidgets') + variant('interactive', default=True, + description='Install prof-I (Interactive parametrization explorer)') + depends_on('yoda') depends_on('eigen') depends_on('py-cython') depends_on('py-iminuit') depends_on('py-matplotlib') + depends_on('py-matplotlib backend=wx', when='+interactive') + depends_on('root') + + extends('python') + + def setup_build_environment(self, env): + env.set('PROF_VERSION', self.spec.version) def install(self, spec, prefix): make() make('PREFIX={0}'.format(prefix), "install") + if self.spec.satisfies('~interactive'): + os.remove(join_path(prefix.bin, 'prof2-I')) |