Split libcap package
libcap can be splitted for free (just cd subdir; make install). So I've decided not to raise up disscussions "should we build cap_pam.so?" etc. svn path=/nixpkgs/branches/stdenv-updates/; revision=23967
This commit is contained in:
parent
c911c64f9b
commit
25de2c279b
5 changed files with 71 additions and 6 deletions
|
@ -1,17 +1,29 @@
|
|||
{stdenv, fetchurl, attr, perl, pam}:
|
||||
{stdenv, fetchurl, attr, perl}:
|
||||
|
||||
assert stdenv.isLinux;
|
||||
|
||||
stdenv.mkDerivation {
|
||||
name = "libcap-2.19";
|
||||
stdenv.mkDerivation rec {
|
||||
name = "libcap-${version}";
|
||||
version = "2.19";
|
||||
|
||||
src = fetchurl {
|
||||
url = mirror://kernel/linux/libs/security/linux-privs/kernel-2.6/libcap-2.19.tar.gz;
|
||||
url = "mirror://kernel/linux/libs/security/linux-privs/kernel-2.6/${name}.tar.gz";
|
||||
sha256 = "0fdsz9j741npvh222f8p1y6l516z9liibiwdpdr3a4zg53m0pw45";
|
||||
};
|
||||
|
||||
buildNativeInputs = [perl];
|
||||
buildInputs = [attr pam];
|
||||
propagatedBuildInputs = [attr];
|
||||
|
||||
makeFlags = "PAM_CAP=yes lib=lib prefix=$(out)";
|
||||
preConfigure = "cd libcap";
|
||||
|
||||
makeFlags = "lib=lib prefix=$(out)";
|
||||
|
||||
passthru = {
|
||||
postinst = n : ''
|
||||
ensureDir $out/share/doc/${n}
|
||||
cp ../License $out/share/doc/${n}/License
|
||||
'';
|
||||
};
|
||||
|
||||
postInstall = passthru.postinst name;
|
||||
}
|
||||
|
|
15
pkgs/os-specific/linux/libcap/man.nix
Normal file
15
pkgs/os-specific/linux/libcap/man.nix
Normal file
|
@ -0,0 +1,15 @@
|
|||
{stdenv, libcap}:
|
||||
|
||||
assert stdenv.isLinux;
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
name = "libcap-docs-${libcap.version}";
|
||||
|
||||
inherit (libcap) src;
|
||||
|
||||
makeFlags = "MANDIR=$(out)/share/man";
|
||||
|
||||
preConfigure = "cd doc";
|
||||
|
||||
postInstall = libcap.postinst name;
|
||||
}
|
17
pkgs/os-specific/linux/libcap/pam.nix
Normal file
17
pkgs/os-specific/linux/libcap/pam.nix
Normal file
|
@ -0,0 +1,17 @@
|
|||
{stdenv, pam, libcap}:
|
||||
|
||||
assert stdenv.isLinux;
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
name = "cap_pam.so-${libcap.version}";
|
||||
|
||||
inherit (libcap) src;
|
||||
|
||||
buildInputs = [ libcap pam ];
|
||||
|
||||
preConfigure = "cd pam_cap";
|
||||
|
||||
makeFlags = "${libcap.makeFlags} PAM_CAP=yes";
|
||||
|
||||
postInstall = libcap.postinst name;
|
||||
}
|
15
pkgs/os-specific/linux/libcap/progs.nix
Normal file
15
pkgs/os-specific/linux/libcap/progs.nix
Normal file
|
@ -0,0 +1,15 @@
|
|||
{stdenv, libcap}:
|
||||
|
||||
assert stdenv.isLinux;
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
name = "libcap-progs-${libcap.version}";
|
||||
|
||||
inherit (libcap) src makeFlags;
|
||||
|
||||
buildInputs = [ libcap ];
|
||||
|
||||
preConfigure = "cd progs";
|
||||
|
||||
postInstall = libcap.postinst name;
|
||||
}
|
|
@ -4769,6 +4769,12 @@ let
|
|||
|
||||
libcap = callPackage ../os-specific/linux/libcap { };
|
||||
|
||||
libcap_progs = callPackage ../os-specific/linux/libcap/progs.nix { };
|
||||
|
||||
libcap_pam = callPackage ../os-specific/linux/libcap/pam.nix { };
|
||||
|
||||
libcap_manpages = callPackage ../os-specific/linux/libcap/man.nix { };
|
||||
|
||||
libnscd = callPackage ../os-specific/linux/libnscd { };
|
||||
|
||||
libnotify = callPackage ../development/libraries/libnotify { };
|
||||
|
|
Loading…
Reference in a new issue