audit: pull upstream fix for linux-headers-5.15 (#144077)

Co-authored-by: Sandro <sandro.jaeckel@gmail.com>
This commit is contained in:
Sergei Trofimovich 2021-11-28 02:48:51 +00:00 committed by GitHub
parent 8887db8787
commit 50a148ddf4
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -1,6 +1,7 @@
{ {
lib, stdenv, buildPackages, fetchurl, fetchpatch, lib, stdenv, buildPackages, fetchurl, fetchpatch,
runCommand, runCommand,
autoreconfHook,
autoconf, automake, libtool, autoconf, automake, libtool,
enablePython ? false, python ? null, enablePython ? false, python ? null,
}: }:
@ -19,8 +20,7 @@ stdenv.mkDerivation rec {
outputs = [ "bin" "dev" "out" "man" ]; outputs = [ "bin" "dev" "out" "man" ];
depsBuildBuild = [ buildPackages.stdenv.cc ]; depsBuildBuild = [ buildPackages.stdenv.cc ];
nativeBuildInputs = lib.optionals stdenv.hostPlatform.isMusl nativeBuildInputs = [ autoreconfHook ];
[ autoconf automake libtool ];
buildInputs = lib.optional enablePython python; buildInputs = lib.optional enablePython python;
configureFlags = [ configureFlags = [
@ -44,8 +44,7 @@ stdenv.mkDerivation rec {
url = "https://github.com/linux-audit/audit-userspace/commit/017e6c6ab95df55f34e339d2139def83e5dada1f.patch"; url = "https://github.com/linux-audit/audit-userspace/commit/017e6c6ab95df55f34e339d2139def83e5dada1f.patch";
sha256 = "100xa1rzkv0mvhjbfgpfm72f7c4p68syflvgc3xm6pxgrqqmfq8h"; sha256 = "100xa1rzkv0mvhjbfgpfm72f7c4p68syflvgc3xm6pxgrqqmfq8h";
}) })
]
++ lib.optional stdenv.hostPlatform.isMusl [
( (
let patch = fetchpatch { let patch = fetchpatch {
url = "https://github.com/linux-audit/audit-userspace/commit/d579a08bb1cde71f939c13ac6b2261052ae9f77e.patch"; url = "https://github.com/linux-audit/audit-userspace/commit/d579a08bb1cde71f939c13ac6b2261052ae9f77e.patch";
@ -60,6 +59,14 @@ stdenv.mkDerivation rec {
'-* Copyright (c) 2007-09,2011-16 Red Hat Inc., Durham, North Carolina.' '-* Copyright (c) 2007-09,2011-16 Red Hat Inc., Durham, North Carolina.'
'' ''
) )
# upstream fix for linux-headers-5.15 which removed ipx.h
(fetchpatch {
name = "no-ipx.patch";
url = "https://github.com/linux-audit/audit-userspace/commit/6b09724c69d91668418ddb3af00da6db6755208c.patch";
sha256 = "0qjq41ridyamajz9v9nyplgq7f8nn3fxw375s9sa5a0igsrx9pm0";
excludes = [ "ChangeLog" ];
})
]; ];
prePatch = '' prePatch = ''