2020-07-13 16:46:44 +02:00
|
|
|
{
|
|
|
|
stdenv
|
2020-10-08 17:42:17 +02:00
|
|
|
, cc
|
2021-02-23 18:24:21 +01:00
|
|
|
, nanos6
|
|
|
|
, mcxx
|
|
|
|
, mpi
|
|
|
|
, tampi
|
2021-04-20 18:12:17 +02:00
|
|
|
, gitBranch ? "garlic/seq"
|
|
|
|
, gitCommit ? null
|
|
|
|
, garlicTools
|
2020-07-13 16:46:44 +02:00
|
|
|
}:
|
|
|
|
|
2021-04-20 18:12:17 +02:00
|
|
|
let
|
|
|
|
gitSource = garlicTools.fetchGarlicApp {
|
|
|
|
appName = "hpcg";
|
|
|
|
inherit gitCommit gitBranch;
|
|
|
|
gitTable = import ./git-table.nix;
|
2020-07-13 16:46:44 +02:00
|
|
|
};
|
2021-04-20 18:12:17 +02:00
|
|
|
in
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
name = "hpcg";
|
2020-07-13 16:46:44 +02:00
|
|
|
|
2021-04-20 18:12:17 +02:00
|
|
|
inherit (gitSource) src gitBranch gitCommit;
|
2020-07-13 16:46:44 +02:00
|
|
|
|
2021-04-20 18:12:17 +02:00
|
|
|
buildInputs = [
|
|
|
|
cc nanos6 mcxx mpi tampi
|
|
|
|
];
|
2020-07-13 16:46:44 +02:00
|
|
|
|
2021-04-20 18:12:17 +02:00
|
|
|
makeFlags = [
|
|
|
|
"CC=${cc.CC}"
|
|
|
|
"CXX=${cc.CXX}"
|
|
|
|
];
|
2020-10-08 18:24:56 +02:00
|
|
|
|
2021-04-20 18:12:17 +02:00
|
|
|
enableParallelBuilding = true;
|
2020-07-13 16:46:44 +02:00
|
|
|
|
2021-04-20 18:12:17 +02:00
|
|
|
installPhase = ''
|
|
|
|
mkdir -p $out/bin
|
|
|
|
cp bin/* $out/bin/
|
|
|
|
'';
|
2020-07-13 16:46:44 +02:00
|
|
|
|
2021-04-20 18:12:17 +02:00
|
|
|
programPath = "/bin/xhpcg";
|
2020-10-13 17:05:36 +02:00
|
|
|
|
2021-04-06 19:19:24 +02:00
|
|
|
hardeningDisable = [ "all" ];
|
2021-04-20 18:12:17 +02:00
|
|
|
}
|