mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-01-22 21:04:30 +00:00
571c71e6f7
We are migrating packages that meet below requirements: 1. using `callPackage` 2. called path is a directory 3. overriding set is empty (`{ }`) 4. not containing path expressions other than relative path (to makenixpkgs-vet happy) 5. not referenced by nix files outside of the directory, other than`pkgs/top-level/all-packages.nix` 6. not referencing nix files outside of the directory 7. not referencing `default.nix` (since it's changed to `package.nix`) 8. `outPath` doesn't change after migration The tool is here: https://github.com/Aleksanaa/by-name-migrate.
98 lines
1.5 KiB
Nix
98 lines
1.5 KiB
Nix
{ lib, stdenv
|
|
, fetchFromGitHub
|
|
, ncurses
|
|
, python3
|
|
, cunit
|
|
, dpdk
|
|
, fuse3
|
|
, libaio
|
|
, libbsd
|
|
, libuuid
|
|
, numactl
|
|
, openssl
|
|
, pkg-config
|
|
, zlib
|
|
, zstd
|
|
, libpcap
|
|
, libnl
|
|
, elfutils
|
|
, jansson
|
|
, ensureNewerSourcesForZipFilesHook
|
|
}:
|
|
|
|
stdenv.mkDerivation rec {
|
|
pname = "spdk";
|
|
|
|
version = "24.09";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "spdk";
|
|
repo = "spdk";
|
|
rev = "v${version}";
|
|
hash = "sha256-27mbIycenOk51PLQrAfU1cZcjiWddNtxoyC6Q9wxqFg=";
|
|
fetchSubmodules = true;
|
|
};
|
|
|
|
nativeBuildInputs = [
|
|
python3
|
|
python3.pkgs.pip
|
|
python3.pkgs.setuptools
|
|
python3.pkgs.wheel
|
|
python3.pkgs.wrapPython
|
|
pkg-config
|
|
ensureNewerSourcesForZipFilesHook
|
|
];
|
|
|
|
buildInputs = [
|
|
cunit
|
|
dpdk
|
|
fuse3
|
|
jansson
|
|
libaio
|
|
libbsd
|
|
elfutils
|
|
libuuid
|
|
libpcap
|
|
libnl
|
|
numactl
|
|
openssl
|
|
ncurses
|
|
zlib
|
|
zstd
|
|
];
|
|
|
|
propagatedBuildInputs = [
|
|
python3.pkgs.configshell
|
|
];
|
|
|
|
postPatch = ''
|
|
patchShebangs .
|
|
'';
|
|
|
|
enableParallelBuilding = true;
|
|
|
|
configureFlags = [
|
|
"--with-dpdk=${dpdk}"
|
|
];
|
|
|
|
postCheck = ''
|
|
python3 -m spdk
|
|
'';
|
|
|
|
postFixup = ''
|
|
wrapPythonPrograms
|
|
'';
|
|
|
|
env.NIX_CFLAGS_COMPILE = "-mssse3"; # Necessary to compile.
|
|
# otherwise does not find strncpy when compiling
|
|
env.NIX_LDFLAGS = "-lbsd";
|
|
|
|
meta = with lib; {
|
|
description = "Set of libraries for fast user-mode storage";
|
|
homepage = "https://spdk.io/";
|
|
license = licenses.bsd3;
|
|
platforms = [ "x86_64-linux" ];
|
|
maintainers = with maintainers; [ orivej ];
|
|
};
|
|
}
|