From b18a354c888c38c9373b48db8c32b93838df159a Mon Sep 17 00:00:00 2001 From: "William A. Kennington III" Date: Fri, 31 Jul 2015 12:40:17 -0700 Subject: [PATCH] libselinux: 2.3 -> 2.4 --- pkgs/os-specific/linux/libselinux/default.nix | 23 +++++++++++-------- 1 file changed, 13 insertions(+), 10 deletions(-) diff --git a/pkgs/os-specific/linux/libselinux/default.nix b/pkgs/os-specific/linux/libselinux/default.nix index 746f49b519dd..69e5fa856e36 100644 --- a/pkgs/os-specific/linux/libselinux/default.nix +++ b/pkgs/os-specific/linux/libselinux/default.nix @@ -8,12 +8,12 @@ with stdenv.lib; stdenv.mkDerivation rec { name = "libselinux-${version}"; - version = "2.3"; + version = "2.4"; inherit (libsepol) se_release se_url; src = fetchurl { url = "${se_url}/${se_release}/libselinux-${version}.tar.gz"; - sha256 = "1ckpiv6m5c07rp5vawlhv02w5rq8kc0n95fh2ckq2jnqxi1hn7hb"; + sha256 = "0yqg73ns97jwjh1iyv0jr5qxb8k5sqq5ywfkx11lzfn5yj8k0126"; }; buildInputs = [ pkgconfig libsepol pcre ] @@ -23,16 +23,19 @@ stdenv.mkDerivation rec { sed -i -e 's|\$(LIBDIR)/libsepol.a|${libsepol}/lib/libsepol.a|' src/Makefile ''; - installFlags = [ "PREFIX=$(out)" "DESTDIR=$(out)" ]; - installTargets = [ "install" ] ++ optional enablePython "install-pywrap"; + NIX_CFLAGS_COMPILE = "-std=gnu89"; - # TODO: Figure out why the build incorrectly links libselinux.so - postInstall = '' - rm $out/lib/libselinux.so - ln -s libselinux.so.1 $out/lib/libselinux.so + preBuild = '' + # Build fails without this precreated + mkdir -p $out/include + + makeFlagsArray+=("PREFIX=$out") + makeFlagsArray+=("DESTDIR=$out") ''; - meta = { - inherit (libsepol.meta) homepage platforms maintainers; + installTargets = [ "install" ] ++ optional enablePython "install-pywrap"; + + meta = libsepol.meta // { + description = "SELinux core library"; }; }