made switching supported ifaces easier
parent
2038c9de8c
commit
6cb935ea52
|
@ -1,4 +1,5 @@
|
|||
{ pkgs
|
||||
, lib
|
||||
, stdenvNoCC
|
||||
, cxx ? pkgs.gfortran12
|
||||
, cc ? pkgs.gfortran12
|
||||
|
@ -8,6 +9,8 @@
|
|||
, python39Packages
|
||||
, gtest
|
||||
, src ? { outPath = ./../icon-charm; }
|
||||
, cIfaceSupport ? false
|
||||
, fortranIfaceSupport ? false
|
||||
}:
|
||||
|
||||
stdenvNoCC.mkDerivation {
|
||||
|
@ -30,7 +33,15 @@ stdenvNoCC.mkDerivation {
|
|||
"-DCMAKE_CXX_COMPILER=${cxx}/bin/c++"
|
||||
"-DCMAKE_C_COMPILER=${cc}/bin/cc"
|
||||
"-DCMAKE_FORTRAN_COMPILER=${f77}/bin/f77"
|
||||
"-DMM_ENABLE_FORTRAN:BOOL=OFF"
|
||||
] ++ lib.optional (cIfaceSupport && !fortranIfaceSupport) [
|
||||
"-DMM_ENABLE_C=ON"
|
||||
] ++ lib.optional fortranIfaceSupport [
|
||||
"-DMM_ENABLE_C=ON"
|
||||
"-DMM_ENABLE_FORTRAN=ON"
|
||||
] ++ lib.optional (!fortranIfaceSupport) [
|
||||
"-DMM_ENABLE_FORTRAN=OFF"
|
||||
] ++ lib.optional (!cIfaceSupport && !fortranIfaceSupport) [
|
||||
"-DMM_ENABLE_C=OFF"
|
||||
];
|
||||
|
||||
doCheck = true;
|
||||
|
|
Loading…
Reference in New Issue