1{ stdenv, fetchFromGitHub, autoreconfHook, pkgconfig, bison, flex
2, python, swig2, tcl, libsepol, libselinux, libxml2, sqlite, bzip2 }:
3
4stdenv.mkDerivation rec {
5 name = "setools-2015-02-12";
6
7 src = fetchFromGitHub {
8 owner = "TresysTechnology";
9 repo = "setools3";
10 rev = "f1e5b208d507171968ca4d2eeefd7980f1004a3c";
11 sha256 = "02gzy2kpszhr13f0d9qfiwh2hj4201g2x366j53v5n5qz481aykd";
12 };
13
14 configureFlags = [
15 "--disable-gui"
16 "--with-sepol-devel=${libsepol}"
17 "--with-selinux-devel=${libselinux}"
18 "--with-tcl=${tcl}/lib"
19 ];
20
21 hardeningDisable = [ "format" ];
22
23 NIX_CFLAGS_COMPILE = "-fstack-protector-all";
24 NIX_LDFLAGS = "-L${libsepol}/lib -L${libselinux}/lib";
25
26 nativeBuildInputs = [ autoreconfHook pkgconfig python swig2 bison flex ];
27 buildInputs = [ tcl libxml2 sqlite bzip2 ];
28
29 meta = {
30 description = "SELinux Tools";
31 homepage = "http://oss.tresys.com/projects/setools/";
32 license = stdenv.lib.licenses.gpl2;
33 platforms = stdenv.lib.platforms.linux;
34 };
35}