coreutils: add SELinux support
svn path=/nixpkgs/trunk/; revision=26543
This commit is contained in:
parent
1c9c082d00
commit
ac951a6469
@ -1,8 +1,11 @@
|
|||||||
{ stdenv, fetchurl, aclSupport ? false, acl ? null, perl, gmp ? null}:
|
{ stdenv, fetchurl, perl, gmp ? null
|
||||||
|
, aclSupport ? false, acl ? null
|
||||||
|
, selinuxSupport? false, libselinux ? null, libsepol ? null }:
|
||||||
|
|
||||||
assert aclSupport -> acl != null;
|
assert aclSupport -> acl != null;
|
||||||
|
assert selinuxSupport -> ( (libselinux != null) && (libsepol != null) );
|
||||||
|
|
||||||
stdenv.mkDerivation rec {
|
stdenv.mkDerivation (rec {
|
||||||
name = "coreutils-8.7";
|
name = "coreutils-8.7";
|
||||||
|
|
||||||
src = fetchurl {
|
src = fetchurl {
|
||||||
@ -11,11 +14,16 @@ stdenv.mkDerivation rec {
|
|||||||
};
|
};
|
||||||
|
|
||||||
buildNativeInputs = [ perl ];
|
buildNativeInputs = [ perl ];
|
||||||
buildInputs = [ gmp ] ++ stdenv.lib.optional aclSupport acl;
|
buildInputs = [ gmp ]
|
||||||
|
++ stdenv.lib.optional aclSupport acl
|
||||||
|
++ stdenv.lib.optional selinuxSupport libselinux
|
||||||
|
++ stdenv.lib.optional selinuxSupport libsepol;
|
||||||
|
|
||||||
crossAttrs = {
|
crossAttrs = {
|
||||||
buildInputs = [ gmp ]
|
buildInputs = [ gmp ]
|
||||||
++ stdenv.lib.optional aclSupport acl.hostDrv
|
++ stdenv.lib.optional aclSupport acl.hostDrv
|
||||||
|
++ stdenv.lib.optional selinuxSupport libselinux.hostDrv
|
||||||
|
++ stdenv.lib.optional selinuxSupport libsepol.hostDrv
|
||||||
++ stdenv.lib.optional (stdenv.gccCross.libc ? libiconv)
|
++ stdenv.lib.optional (stdenv.gccCross.libc ? libiconv)
|
||||||
stdenv.gccCross.libc.libiconv.hostDrv;
|
stdenv.gccCross.libc.libiconv.hostDrv;
|
||||||
|
|
||||||
@ -48,4 +56,5 @@ stdenv.mkDerivation rec {
|
|||||||
|
|
||||||
maintainers = [ stdenv.lib.maintainers.ludo ];
|
maintainers = [ stdenv.lib.maintainers.ludo ];
|
||||||
};
|
};
|
||||||
}
|
} // (if selinuxSupport then { NIX_LDFLAGS = "-lsepol"; } else { } ) )
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user