Skip to content
Merged
Changes from 5 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion easybuild/easyblocks/g/gromacs.py
Original file line number Diff line number Diff line change
Expand Up @@ -190,9 +190,15 @@ def configure_step(self):
self.cfg.update('configopts', "-DGMX_GPU=CUDA -DCUDA_TOOLKIT_ROOT_DIR=%s" % cuda)
else:
self.cfg.update('configopts', "-DGMX_GPU=ON -DCUDA_TOOLKIT_ROOT_DIR=%s" % cuda)

# Set CUDA capabilities based on template value.
if '-DGMX_CUDA_TARGET_SM' not in self.cfg['configopts']:
cuda_cc_semicolon_sep = self.cfg.get_cuda_cc_template_value("cuda_cc_semicolon_sep").replace('.', '')
self.cfg.update('configopts',
'-DGMX_CUDA_TARGET_SM="%s"' % cuda_cc_semicolon_sep)
else:
# explicitly disable GPU support if CUDA is not available,
# to avoid that GROMACS find and uses a system-wide CUDA compiler
# to avoid that GROMACS finds and uses a system-wide CUDA compiler
self.cfg.update('configopts', "-DGMX_GPU=OFF")

# check whether PLUMED is loaded as a dependency
Expand Down