summary refs log tree commit diff
path: root/pkgs/os-specific/linux/libselinux
diff options
context:
space:
mode:
authorMikael Brockman <mikael@brockman.se>2016-08-19 18:30:22 +0300
committerMikael Brockman <mikael@brockman.se>2016-08-19 19:06:25 +0300
commit1f50e2412f888d5f811e08c32890994275913807 (patch)
tree4a3dff112b7dc295ccc9b995376e0a6937b5d3ba /pkgs/os-specific/linux/libselinux
parent904ee1bebc3a514688e3d96e76463b112b352644 (diff)
downloadnixpkgs-1f50e2412f888d5f811e08c32890994275913807.tar
nixpkgs-1f50e2412f888d5f811e08c32890994275913807.tar.gz
nixpkgs-1f50e2412f888d5f811e08c32890994275913807.tar.bz2
nixpkgs-1f50e2412f888d5f811e08c32890994275913807.tar.lz
nixpkgs-1f50e2412f888d5f811e08c32890994275913807.tar.xz
nixpkgs-1f50e2412f888d5f811e08c32890994275913807.tar.zst
nixpkgs-1f50e2412f888d5f811e08c32890994275913807.zip
libselinux: fix Python binding
Applies unreleased patch from upstream.
Diffstat (limited to 'pkgs/os-specific/linux/libselinux')
-rw-r--r--pkgs/os-specific/linux/libselinux/default.nix11
1 files changed, 10 insertions, 1 deletions
diff --git a/pkgs/os-specific/linux/libselinux/default.nix b/pkgs/os-specific/linux/libselinux/default.nix
index 22ff351e45a..1327a349474 100644
--- a/pkgs/os-specific/linux/libselinux/default.nix
+++ b/pkgs/os-specific/linux/libselinux/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, libsepol, pcre
+{ stdenv, fetchurl, fetchpatch, pkgconfig, libsepol, pcre
 , enablePython ? true, swig ? null, python ? null
 }:
 
@@ -21,6 +21,15 @@ stdenv.mkDerivation rec {
 
   NIX_CFLAGS_COMPILE = "-fstack-protector-all -std=gnu89";
 
+  # Unreleased upstream patch that fixes Python package issue arising
+  # from recent SWIG changes.
+  patches = optional enablePython (fetchpatch {
+    name = "fix-python-swig.patch";
+    url = "https://github.com/SELinuxProject/selinux/commit/a9604c30a5e2f71007d31aa6ba41cf7b95d94822.patch";
+    sha256 = "0mjrclh0sd8m7vq0wvl6pg29ss415j3kn0266v8ixy4fprafagfp";
+    stripLen = 1;
+  });
+
   postPatch = optionalString enablePython ''
     sed -i -e 's|\$(LIBDIR)/libsepol.a|${libsepol}/lib/libsepol.a|' src/Makefile
   '';