* Refactoring: let linuxPackages.aufs and linuxPackages.aufs_util

evaluate to right AUFS for the kernel in question.

svn path=/nixpkgs/trunk/; revision=30322
This commit is contained in:
Eelco Dolstra 2011-11-08 15:05:54 +00:00
parent 756df1fb12
commit b26931a480
7 changed files with 35 additions and 35 deletions

View File

@ -1,16 +1,18 @@
{ stdenv, fetchurl, kernel, aufs2 }:
{ stdenv, fetchurl, kernel, aufs }:
assert aufs != null;
let version = "20100506"; in
stdenv.mkDerivation {
name = "aufs2-util-${version}";
name = "aufs2-util-${version}-${kernel.version}";
src = fetchurl {
url = "http://nixos.org/tarballs/aufs2-util-git-${version}.tar.bz2";
sha256 = "0ly0c3p8fjxqbk8k5rmm1a91wg8wcrvhi1lv4aawalkkk8rqbnwk";
};
buildInputs = [ aufs2 ];
buildInputs = [ aufs ];
makeFlags =
[ "KDIR=${kernel}/lib/modules/${kernel.version}/build"

View File

@ -1,9 +1,11 @@
{ stdenv, fetchgit, kernel, aufs2_1 }:
{ stdenv, fetchgit, kernel, aufs }:
assert aufs != null;
let version = "20110217"; in
stdenv.mkDerivation {
name = "aufs2.1-util-${version}";
name = "aufs2.1-util-${version}-${kernel.version}";
src = fetchgit {
url = "git://git.c3sl.ufpr.br/aufs/aufs2-util.git";
@ -11,7 +13,7 @@ stdenv.mkDerivation {
sha256 = "0fce5601b67efe8b5652a813ae612348bf4503aa71056cd31a5ed0406632e364";
};
buildInputs = [ aufs2_1 ];
buildInputs = [ aufs ];
makeFlags =
[ "KDIR=${kernel}/lib/modules/${kernel.version}/build"

View File

@ -8,7 +8,7 @@ let version =
else "20110408"; in
stdenv.mkDerivation {
name = "aufs2.1-${version}";
name = "aufs2.1-${version}-${kernel.version}";
src =
if (builtins.lessThan (builtins.compareVersions kernel.version "2.6.38") 0)

View File

@ -5,7 +5,7 @@ assert kernel.features ? aufsBase;
let version = "20100522"; in
stdenv.mkDerivation {
name = "aufs2-${version}";
name = "aufs2-${version}-${kernel.version}";
src =
if (builtins.lessThan (builtins.compareVersions kernel.version "2.6.35") 0) then

View File

@ -1,15 +1,17 @@
{ stdenv, fetchgit, kernel, aufs3 }:
{ stdenv, fetchgit, kernel, aufs }:
assert aufs != null;
stdenv.mkDerivation {
name = "aufs3-util-${aufs3.patch.version}";
name = "aufs3-util-${aufs.patch.version}-${kernel.version}";
src = fetchgit {
url = git://aufs.git.sourceforge.net/gitroot/aufs/aufs-util.git;
rev = aufs3.patch.utilRev;
sha256 = aufs3.patch.utilHash;
rev = aufs.patch.utilRev;
sha256 = aufs.patch.utilHash;
};
buildInputs = [ aufs3 ];
buildInputs = [ aufs ];
makeFlags =
[ "KDIR=${kernel}/lib/modules/${kernel.modDirVersion}/build"

View File

@ -12,7 +12,7 @@ let
in
stdenv.mkDerivation {
name = "aufs3-${patch.version}";
name = "aufs3-${patch.version}-${kernel.version}";
src = patch.patch.src;

View File

@ -5638,30 +5638,24 @@ let
ati_drivers_x11 = callPackage ../os-specific/linux/ati-drivers { };
aufs2 = if kernel.features ? aufs2 then
callPackage ../os-specific/linux/aufs2 { }
aufs =
if kernel.features ? aufs2 then
callPackage ../os-specific/linux/aufs2 { }
else if kernel.features ? aufs2_1 then
callPackage ../os-specific/linux/aufs2.1 { }
else if kernel.features ? aufs3 then
callPackage ../os-specific/linux/aufs3 { }
else null;
aufs2_1 = if kernel.features ? aufs2_1 then
callPackage ../os-specific/linux/aufs2.1 { }
aufs_util =
if kernel.features ? aufs2 then
callPackage ../os-specific/linux/aufs2-util { }
else if kernel.features ? aufs2_1 then
callPackage ../os-specific/linux/aufs2.1-util { }
else if kernel.features ? aufs3 then
callPackage ../os-specific/linux/aufs3-util { }
else null;
aufs3 = if kernel.features ? aufs3 then
callPackage ../os-specific/linux/aufs3 { }
else null;
aufs2_util = if kernel.features ? aufs2 then
callPackage ../os-specific/linux/aufs2-util { }
else null;
aufs2_1_util = if kernel.features ? aufs2_1 then
callPackage ../os-specific/linux/aufs2.1-util { }
else null;
aufs3_util = if kernel.features ? aufs3 then
callPackage ../os-specific/linux/aufs3-util { }
else null;
blcr = callPackage ../os-specific/linux/blcr {
#libtool = libtool_1_5; # libtool 2 causes a fork bomb
};