depot/third_party/nixpkgs/pkgs/os-specific/linux/checkpolicy/default.nix
Default email 8ac5e011d6 Project import generated by Copybara.
GitOrigin-RevId: 2c3273caa153ee8eb5786bc8141b85b859e7efd7
2020-04-24 19:36:52 -04:00

24 lines
603 B
Nix

{ stdenv, fetchurl, bison, flex, libsepol }:
stdenv.mkDerivation rec {
pname = "checkpolicy";
version = "2.9";
inherit (libsepol) se_release se_url;
src = fetchurl {
url = "${se_url}/${se_release}/checkpolicy-${version}.tar.gz";
sha256 = "13jz6f8zdrijvn5w1j102b36fs41z0q8ii74axw48cj550mw6im9";
};
nativeBuildInputs = [ bison flex ];
buildInputs = [ libsepol ];
makeFlags = [
"PREFIX=$(out)"
"LIBSEPOLA=${stdenv.lib.getLib libsepol}/lib/libsepol.a"
];
meta = removeAttrs libsepol.meta ["outputsToInstall"] // {
description = "SELinux policy compiler";
};
}