From: Steve Grubb <sgrubb@redhat.com>
To: linux-audit@redhat.com
Subject: audit user space build problems
Date: Mon, 21 Feb 2022 16:50:22 -0500 [thread overview]
Message-ID: <2126549.NgBsaNRSFp@x2> (raw)
Hello,
Recently, distributions moved to building against gcc-12 for their latest OS
composes. It's been found in at least 2 distributions that the user space
package is failing to build. It's natural to think this is related to gcc-12
since it's the obvious change.
However, the problem is a combination of 2 things:
1) SWIG is making buggy code
2) The kernel changed to using flexible array members
The issue specifically is with struct audit_rules_data. At the bottom, it was
using buf[0]; But on 5.17, it uses buf[]; It turns out that gcc-12 is just
a coincidence and anything using gcc-12 also has the newest kernel.
The options are:
1) Report this as a SWIG bug and wait
2) Rewrite the libaudit python bindings to not use SWIG
3) Ask for buf[0]; to be reinstated in the kernel.
Of these, I think option 2 is the only viable long term option. It will take
some time to write new python bindings that preserve the SWIG api.
A short term fix might be for distros to copy the kernel header into the lib
directory and patch it to restore buf[0];, then change libaudit.c to include
"audit.h" instead of <linux/audit.h>. There may be other approaches.
Just wanted to let everyone know that new builds in distributions are running
into a problem. And a real fix will take a while.
Best,
-Steve
--
Linux-audit mailing list
Linux-audit@redhat.com
https://listman.redhat.com/mailman/listinfo/linux-audit
next reply other threads:[~2022-02-21 21:53 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-02-21 21:50 Steve Grubb [this message]
2022-02-24 3:39 ` audit user space build problems Steve Grubb
2022-02-28 15:37 ` Steve Grubb
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=2126549.NgBsaNRSFp@x2 \
--to=sgrubb@redhat.com \
--cc=linux-audit@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.