2023-01-20 10:41:00 +00:00
|
|
|
{ lib
|
|
|
|
, stdenv
|
|
|
|
, fetchFromGitHub
|
|
|
|
, pkg-config
|
|
|
|
, autoreconfHook
|
|
|
|
, enablePsm2 ? (stdenv.isx86_64 && stdenv.isLinux)
|
|
|
|
, libpsm2
|
|
|
|
, enableOpx ? (stdenv.isx86_64 && stdenv.isLinux)
|
|
|
|
, libuuid
|
|
|
|
, numactl
|
|
|
|
}:
|
2021-09-22 15:38:15 +00:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "libfabric";
|
2024-01-02 11:29:13 +00:00
|
|
|
version = "1.20.0";
|
2021-09-22 15:38:15 +00:00
|
|
|
|
|
|
|
enableParallelBuilding = true;
|
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "ofiwg";
|
|
|
|
repo = pname;
|
|
|
|
rev = "v${version}";
|
2024-01-02 11:29:13 +00:00
|
|
|
sha256 = "sha256-woRkm/5kLIv1ypSlCosP/ewYgnSXQJYzkuOqdHvEH8I=";
|
2021-09-22 15:38:15 +00:00
|
|
|
};
|
|
|
|
|
2023-10-19 13:55:26 +00:00
|
|
|
outputs = [ "out" "dev" "man" ];
|
|
|
|
|
2021-09-22 15:38:15 +00:00
|
|
|
nativeBuildInputs = [ pkg-config autoreconfHook ];
|
|
|
|
|
2023-03-15 16:39:30 +00:00
|
|
|
buildInputs = lib.optionals enableOpx [ libuuid numactl ] ++ lib.optionals enablePsm2 [ libpsm2 ];
|
2021-09-22 15:38:15 +00:00
|
|
|
|
2023-01-20 10:41:00 +00:00
|
|
|
configureFlags = [
|
|
|
|
(if enablePsm2 then "--enable-psm2=${libpsm2}" else "--disable-psm2")
|
|
|
|
(if enableOpx then "--enable-opx" else "--disable-opx")
|
|
|
|
];
|
2021-09-22 15:38:15 +00:00
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
homepage = "https://ofiwg.github.io/libfabric/";
|
|
|
|
description = "Open Fabric Interfaces";
|
|
|
|
license = with licenses; [ gpl2 bsd2 ];
|
|
|
|
platforms = platforms.all;
|
|
|
|
maintainers = [ maintainers.bzizou ];
|
|
|
|
};
|
|
|
|
}
|