libsepol: pull upstream fix for -fno-common compiler

Fixes build failure against upstream gcc (defaults -fno-common)

+15 -1
+15 -1
pkgs/os-specific/linux/libsepol/default.nix
··· 1 - { lib, stdenv, fetchurl, flex }: 2 3 stdenv.mkDerivation rec { 4 pname = "libsepol"; ··· 12 url = "${se_url}/${se_release}/libsepol-${version}.tar.gz"; 13 sha256 = "0ygb6dh5lng91xs6xiqf5v0nxa68qmjc787p0s5h9w89364f2yjv"; 14 }; 15 16 postPatch = lib.optionalString stdenv.hostPlatform.isStatic '' 17 substituteInPlace src/Makefile --replace 'all: $(LIBA) $(LIBSO)' 'all: $(LIBA)'
··· 1 + { lib, stdenv, fetchurl, fetchpatch, flex }: 2 3 stdenv.mkDerivation rec { 4 pname = "libsepol"; ··· 12 url = "${se_url}/${se_release}/libsepol-${version}.tar.gz"; 13 sha256 = "0ygb6dh5lng91xs6xiqf5v0nxa68qmjc787p0s5h9w89364f2yjv"; 14 }; 15 + 16 + patches = [ 17 + # upstream build fix against -fno-common compilers like >=gcc-10 18 + (fetchpatch { 19 + url = "https://github.com/SELinuxProject/selinux/commit/a96e8c59ecac84096d870b42701a504791a8cc8c.patch"; 20 + sha256 = "0aybv4kzbhx8xq6s82dsh4ib76k59qzh2bgxmk44iq5cjnqn5rd6"; 21 + stripLen = 1; 22 + }) 23 + (fetchpatch { 24 + url = "https://github.com/SELinuxProject/selinux/commit/3d32fc24d6aff360a538c63dad08ca5c957551b0.patch"; 25 + sha256 = "1mphwdlj4d6mwmsp5xkpf6ci4rxhgbi3fm79d08h4jbzxaf4wny4"; 26 + stripLen = 1; 27 + }) 28 + ]; 29 30 postPatch = lib.optionalString stdenv.hostPlatform.isStatic '' 31 substituteInPlace src/Makefile --replace 'all: $(LIBA) $(LIBSO)' 'all: $(LIBA)'