diff options
author | Jan Tojnar <jtojnar@gmail.com> | 2019-12-30 04:52:45 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-12-30 04:52:45 +0100 |
commit | ea4da9b5fa0f549be7795655cbe85741bff9df65 (patch) | |
tree | 295454b2dd216cfc42926b538eb7a0573abbc7a2 /pkgs/applications/science | |
parent | 1b20a627d561784afe8ab1b62fb6ba5ad2d15010 (diff) | |
parent | 318e1ee4ab1168575f480bf918cd5ff0e9c843a3 (diff) |
Merge pull request #76674 from jtojnar/structured-attrs-masterable
treewide: structured-attrs fixes
Diffstat (limited to 'pkgs/applications/science')
-rw-r--r-- | pkgs/applications/science/molecular-dynamics/gromacs/default.nix | 34 |
1 files changed, 22 insertions, 12 deletions
diff --git a/pkgs/applications/science/molecular-dynamics/gromacs/default.nix b/pkgs/applications/science/molecular-dynamics/gromacs/default.nix index d720f5ea0787f..4dc6f038ce7f7 100644 --- a/pkgs/applications/science/molecular-dynamics/gromacs/default.nix +++ b/pkgs/applications/science/molecular-dynamics/gromacs/default.nix @@ -1,4 +1,6 @@ -{ stdenv, fetchurl, cmake +{ stdenv +, fetchurl +, cmake , singlePrec ? true , mpiEnabled ? false , fftw @@ -6,7 +8,6 @@ , perl }: - stdenv.mkDerivation { name = "gromacs-2019.4"; @@ -19,18 +20,27 @@ stdenv.mkDerivation { buildInputs = [ fftw perl ] ++ (stdenv.lib.optionals mpiEnabled [ openmpi ]); - cmakeFlags = '' - ${if singlePrec then "-DGMX_DOUBLE=OFF" else "-DGMX_DOUBLE=ON -DGMX_DEFAULT_SUFFIX=OFF"} - ${if mpiEnabled then "-DGMX_MPI:BOOL=TRUE - -DGMX_CPU_ACCELERATION:STRING=SSE4.1 - -DGMX_OPENMP:BOOL=TRUE - -DGMX_THREAD_MPI:BOOL=FALSE" - else "-DGMX_MPI:BOOL=FALSE" } - ''; + cmakeFlags = ( + if singlePrec then [ + "-DGMX_DOUBLE=OFF" + ] else [ + "-DGMX_DOUBLE=ON" + "-DGMX_DEFAULT_SUFFIX=OFF" + ] + ) ++ ( + if mpiEnabled then [ + "-DGMX_MPI:BOOL=TRUE" + "-DGMX_CPU_ACCELERATION:STRING=SSE4.1" + "-DGMX_OPENMP:BOOL=TRUE" + "-DGMX_THREAD_MPI:BOOL=FALSE" + ] else [ + "-DGMX_MPI:BOOL=FALSE" + ] + ); meta = with stdenv.lib; { - homepage = "http://www.gromacs.org"; - license = licenses.gpl2; + homepage = "http://www.gromacs.org"; + license = licenses.gpl2; description = "Molecular dynamics software package"; longDescription = '' GROMACS is a versatile package to perform molecular dynamics, |