3
0
Fork 0
forked from mirrors/nixpkgs

add linuxPackages.dpdk: libs and drivers for fast packet processing

This commit is contained in:
Domen Kožar 2016-04-20 16:11:34 +01:00
parent 50df762e71
commit e6899cc80c
2 changed files with 42 additions and 0 deletions

View file

@ -0,0 +1,40 @@
{ stdenv, lib, kernel, fetchurl }:
assert lib.versionAtLeast kernel.version "3.18";
stdenv.mkDerivation rec {
name = "dpdk-${version}-${kernel.version}";
version = "16.04";
src = fetchurl {
url = "http://dpdk.org/browse/dpdk/snapshot/dpdk-${version}.tar.gz";
sha256 = "0yrz3nnhv65v2jzz726bjswkn8ffqc1sr699qypc9m78qrdljcfn";
};
RTE_KERNELDIR = "${kernel.dev}/lib/modules/${kernel.modDirVersion}/build";
RTE_TARGET = "x86_64-native-linuxapp-gcc";
enableParallelBuilding = true;
outputs = [ "out" "examples" ];
buildPhase = ''
make T=x86_64-native-linuxapp-gcc config
make T=x86_64-native-linuxapp-gcc install
make T=x86_64-native-linuxapp-gcc examples
'';
installPhase = ''
cp -pr x86_64-native-linuxapp-gcc/{app,lib,include,kmod} $out/
mkdir $examples
cp -pr examples/* $examples/
'';
meta = with stdenv.lib; {
description = "Set of libraries and drivers for fast packet processing";
homepage = http://dpdk.org/;
license = with licenses; [ lgpl21 gpl2 bsd2 ];
platforms = platforms.linux;
maintainers = [ maintainers.iElectric ];
};
}

View file

@ -10652,6 +10652,8 @@ in
cpupower = callPackage ../os-specific/linux/cpupower { };
dpdk = callPackage ../os-specific/linux/dpdk { };
e1000e = callPackage ../os-specific/linux/e1000e {};
v4l2loopback = callPackage ../os-specific/linux/v4l2loopback { };