2021-02-05 17:12:51 +00:00
|
|
|
{ lib, stdenv, fetchFromGitHub, autoreconfHook, doxygen
|
2021-12-06 16:07:01 +00:00
|
|
|
, numactl, rdma-core, libbfd, libiberty, perl, zlib, symlinkJoin
|
|
|
|
, enableCuda ? false
|
|
|
|
, cudatoolkit
|
2020-04-24 23:36:52 +00:00
|
|
|
}:
|
|
|
|
|
2021-12-06 16:07:01 +00:00
|
|
|
let
|
|
|
|
# Needed for configure to find all libraries
|
|
|
|
cudatoolkit' = symlinkJoin {
|
|
|
|
inherit (cudatoolkit) name meta;
|
|
|
|
paths = [ cudatoolkit cudatoolkit.lib ];
|
|
|
|
};
|
|
|
|
|
|
|
|
in stdenv.mkDerivation rec {
|
2021-05-20 23:08:51 +00:00
|
|
|
pname = "ucx";
|
2021-10-06 13:57:05 +00:00
|
|
|
version = "1.11.2";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "openucx";
|
|
|
|
repo = "ucx";
|
|
|
|
rev = "v${version}";
|
2021-10-06 13:57:05 +00:00
|
|
|
sha256 = "0a4rbgr3hn3h42krb7lasfidhqcavacbpp1pv66l4lvfc0gkwi2i";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
nativeBuildInputs = [ autoreconfHook doxygen ];
|
|
|
|
|
2021-12-06 16:07:01 +00:00
|
|
|
buildInputs = [
|
|
|
|
libbfd
|
|
|
|
libiberty
|
|
|
|
numactl
|
|
|
|
perl
|
|
|
|
rdma-core
|
|
|
|
zlib
|
|
|
|
] ++ lib.optional enableCuda cudatoolkit;
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
configureFlags = [
|
|
|
|
"--with-rdmacm=${rdma-core}"
|
|
|
|
"--with-dc"
|
|
|
|
"--with-rc"
|
|
|
|
"--with-dm"
|
|
|
|
"--with-verbs=${rdma-core}"
|
2021-12-06 16:07:01 +00:00
|
|
|
] ++ lib.optional enableCuda "--with-cuda=${cudatoolkit'}";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
enableParallelBuilding = true;
|
|
|
|
|
2021-02-05 17:12:51 +00:00
|
|
|
meta = with lib; {
|
2020-04-24 23:36:52 +00:00
|
|
|
description = "Unified Communication X library";
|
|
|
|
homepage = "http://www.openucx.org";
|
|
|
|
license = licenses.bsd3;
|
|
|
|
platforms = platforms.linux;
|
|
|
|
maintainers = [ maintainers.markuskowa ];
|
|
|
|
};
|
|
|
|
}
|