diff --git a/pkgs/os-specific/bsd/freebsd/pkgs/libnvmf.nix b/pkgs/os-specific/bsd/freebsd/pkgs/libnvmf.nix new file mode 100644 index 000000000000..d52f05a5efc6 --- /dev/null +++ b/pkgs/os-specific/bsd/freebsd/pkgs/libnvmf.nix @@ -0,0 +1,21 @@ +{ + mkDerivation, + libnv, +}: +mkDerivation { + path = "lib/libnvmf"; + extraPaths = [ + "sys/libkern" + "sys/dev/nvmf" + ]; + buildInputs = [ libnv ]; + + postPatch = '' + sed -E -i -e '/INTERNALLIB/d' lib/libnvmf/Makefile + ''; + postInstall = '' + ln -s libnvmf.a $out/lib/libnvmf_pie.a + ''; + + alwaysKeepStatic = true; +}