2013-03-24 12:45:00 +01:00
|
|
|
{ stdenv, fetchurl, kernelDev, perl }:
|
2010-08-02 15:57:57 +02:00
|
|
|
|
2008-01-28 20:34:00 +01:00
|
|
|
stdenv.mkDerivation {
|
2013-03-24 12:45:00 +01:00
|
|
|
name = "ndiswrapper-1.56-${kernelDev.version}";
|
2007-12-05 22:25:47 +01:00
|
|
|
|
|
|
|
# need at least .config and include
|
2013-03-24 12:45:00 +01:00
|
|
|
kernel = kernelDev;
|
2007-12-05 22:25:47 +01:00
|
|
|
|
|
|
|
buildPhase = "
|
2008-06-15 17:11:19 +02:00
|
|
|
echo make KBUILD=$(echo \$kernel/lib/modules/*/build);
|
|
|
|
echo -n $kernel/lib/modules/*/build > kbuild_path
|
|
|
|
make KBUILD=$(echo \$kernel/lib/modules/*/build);
|
2007-12-05 22:25:47 +01:00
|
|
|
";
|
|
|
|
|
2008-06-15 18:24:19 +02:00
|
|
|
installPhase = ''
|
|
|
|
make install KBUILD=$(cat kbuild_path) DESTDIR=$out
|
|
|
|
mv $out/usr/sbin/* $out/sbin/
|
|
|
|
mv $out/usr/share $out/
|
|
|
|
rm -r $out/usr
|
2008-06-15 19:30:34 +02:00
|
|
|
|
|
|
|
patchShebangs $out/sbin
|
2008-06-15 18:24:19 +02:00
|
|
|
'';
|
2008-06-15 17:11:19 +02:00
|
|
|
|
2007-12-05 22:25:47 +01:00
|
|
|
# should we use unstable?
|
2010-08-02 15:57:57 +02:00
|
|
|
src = fetchurl {
|
2013-07-14 02:31:12 +02:00
|
|
|
url = mirror://sourceforge/ndiswrapper/ndiswrapper-1.56.tar.gz;
|
2011-06-19 14:29:41 +02:00
|
|
|
sha256 = "10yqg1a08v6z1qm1qr1v4rbhl35c90gzrazapr09vp372hky8f57";
|
2007-12-05 22:25:47 +01:00
|
|
|
};
|
|
|
|
|
2013-03-24 12:45:00 +01:00
|
|
|
buildInputs = [ kernelDev perl ];
|
2008-01-28 20:34:00 +01:00
|
|
|
|
|
|
|
# this is a patch against svn head, not stable version
|
|
|
|
patches = [./prefix.patch];
|
2007-12-05 22:25:47 +01:00
|
|
|
|
|
|
|
meta = {
|
2010-08-02 15:57:57 +02:00
|
|
|
description = "Ndis driver wrapper for the Linux kernel";
|
|
|
|
homepage = http://sourceforge.net/projects/ndiswrapper;
|
|
|
|
license = "GPL";
|
2007-12-05 22:25:47 +01:00
|
|
|
};
|
|
|
|
}
|