bscpkgs/garlic/apps/heat/default.nix

48 lines
730 B
Nix
Raw Normal View History

{
stdenv
, mpi
, tampi
2020-11-05 19:52:37 +01:00
, clangOmpss2
, bsx ? 1024
, bsy ? 1024
}:
stdenv.mkDerivation rec {
2020-07-27 13:17:08 +02:00
name = "heat";
2020-11-05 19:52:37 +01:00
extension = if (bsx == bsy)
then "${toString bsx}bs.exe"
else "${toString bsx}x${toString bsy}bs.exe";
2020-11-05 19:52:37 +01:00
variant = "heat_ompss";
target = "${variant}.${extension}";
makeFlags = [
"BSX=${toString bsx}"
"BSY=${toString bsy}"
target
];
src = ~/heat;
#src = builtins.fetchGit {
# url = "ssh://git@bscpm02.bsc.es/garlic/apps/heat.git";
# ref = "garlic";
#};
buildInputs = [
mpi
2020-11-05 19:52:37 +01:00
clangOmpss2
tampi
];
2020-11-05 19:52:37 +01:00
programPath = "/bin/${target}";
installPhase = ''
mkdir -p $out/bin
2020-11-05 19:52:37 +01:00
cp ${target} $out/bin/
mkdir -p $out/etc
cp heat.conf $out/etc/
'';
}