Apply compiler filters to GROMACS installation. (#21621)

The GROMACS package embeds references to its build tool chain.
Use the Spack utilities to make sure these references are correct
outside of the isolated Spack build environment.
This commit is contained in:
M. Eric Irrgang
2021-02-11 17:52:32 +03:00
committed by GitHub
parent fd8eac7052
commit dea9334189

View File

@@ -3,6 +3,8 @@
# #
# SPDX-License-Identifier: (Apache-2.0 OR MIT) # SPDX-License-Identifier: (Apache-2.0 OR MIT)
import os
class Gromacs(CMakePackage): class Gromacs(CMakePackage):
"""GROMACS (GROningen MAchine for Chemical Simulations) is a molecular """GROMACS (GROningen MAchine for Chemical Simulations) is a molecular
@@ -117,6 +119,13 @@ class Gromacs(CMakePackage):
patch('gmxDetectCpu-cmake-3.14.patch', when='@2018:2019.3^cmake@3.14.0:') patch('gmxDetectCpu-cmake-3.14.patch', when='@2018:2019.3^cmake@3.14.0:')
patch('gmxDetectSimd-cmake-3.14.patch', when='@:2017.99^cmake@3.14.0:') patch('gmxDetectSimd-cmake-3.14.patch', when='@:2017.99^cmake@3.14.0:')
filter_compiler_wrappers(
'*.cmake',
relative_root=os.path.join('share', 'cmake', 'gromacs_mpi'))
filter_compiler_wrappers(
'*.cmake',
relative_root=os.path.join('share', 'cmake', 'gromacs'))
def patch(self): def patch(self):
if '+plumed' in self.spec: if '+plumed' in self.spec:
self.spec['plumed'].package.apply_patch(self) self.spec['plumed'].package.apply_patch(self)