diff options
-rw-r--r-- | var/spack/repos/builtin/packages/mmg/package.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/var/spack/repos/builtin/packages/mmg/package.py b/var/spack/repos/builtin/packages/mmg/package.py index 3443aacb73..55744c3452 100644 --- a/var/spack/repos/builtin/packages/mmg/package.py +++ b/var/spack/repos/builtin/packages/mmg/package.py @@ -34,17 +34,17 @@ class Mmg(CMakePackage): variant('shared', default=True, description='Enables the build of shared libraries') variant('scotch', default=True, description='Enable SCOTCH library support') variant('doc', default=False, description='Build documentation') + variant('vtk', default=False, when='@5.5.0:', description='Enable VTK I/O support') depends_on('scotch', when='+scotch') depends_on('doxygen', when='+doc') + depends_on('vtk', when='+vtk') def cmake_args(self): args = [] - if '+scotch' in self.spec: - args.append('-DUSE_SCOTCH=ON') - else: - args.append('-DUSE_SCOTCH=OFF') + args.append(self.define_from_variant('USE_SCOTCH', 'scotch')) + args.append(self.define_from_variant('USE_VTK', 'vtk')) if '+shared' in self.spec: args.append('-DLIBMMG3D_SHARED=ON') |