2014-01-05 02:57:21 +01:00
|
|
|
{ stdenv, fetchurl, kernel }:
|
2011-09-15 17:18:45 +02:00
|
|
|
|
2017-02-28 15:10:26 +01:00
|
|
|
assert stdenv.lib.versionOlder kernel.version "4.10";
|
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
name = "e1000e-${version}-${kernel.version}";
|
|
|
|
version = "3.3.5.3";
|
2011-09-15 17:18:45 +02:00
|
|
|
|
|
|
|
src = fetchurl {
|
2017-02-28 15:10:26 +01:00
|
|
|
url = "mirror://sourceforge/e1000/e1000e-${version}.tar.gz";
|
|
|
|
sha256 = "1ajz3vdnf1y307k585w95r6jlh4ah8d74bq36gdkjl1z5hgiqi9q";
|
2011-09-15 17:18:45 +02:00
|
|
|
};
|
|
|
|
|
2016-08-13 16:25:29 +02:00
|
|
|
hardeningDisable = [ "pic" ];
|
|
|
|
|
2011-09-15 17:18:45 +02:00
|
|
|
configurePhase = ''
|
|
|
|
cd src
|
2014-01-05 02:57:21 +01:00
|
|
|
kernel_version=${kernel.modDirVersion}
|
|
|
|
sed -i -e 's|/lib/modules|${kernel.dev}/lib/modules|' Makefile
|
2011-09-15 17:18:45 +02:00
|
|
|
export makeFlags="BUILD_KERNEL=$kernel_version"
|
|
|
|
'';
|
|
|
|
|
|
|
|
installPhase = ''
|
|
|
|
install -v -D -m 644 e1000e.ko "$out/lib/modules/$kernel_version/kernel/drivers/net/e1000e/e1000e.ko"
|
|
|
|
'';
|
|
|
|
|
2011-09-15 18:24:27 +02:00
|
|
|
dontStrip = true;
|
|
|
|
|
|
|
|
enableParallelBuilding = true;
|
|
|
|
|
2011-09-15 17:18:45 +02:00
|
|
|
meta = {
|
|
|
|
description = "Linux kernel drivers for Intel Ethernet adapters and LOMs (LAN On Motherboard)";
|
2017-08-01 22:03:30 +02:00
|
|
|
homepage = http://e1000.sf.net/;
|
2011-09-15 17:18:45 +02:00
|
|
|
license = stdenv.lib.licenses.gpl2;
|
|
|
|
};
|
|
|
|
}
|