summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAnders Hedlund <anders.hedlund@windriver.com>2013-08-01 10:24:14 -0700
committerMark Hatle <mark.hatle@windriver.com>2013-08-01 20:36:22 -0500
commit111815acce0d04b8b02e24df601a15a3ac94c48b (patch)
tree57b5bab52f0083c6e518bfdccc286d89d7624778
parenta530caf8288ec1d2e91c0b1f51e81fb6b3a165f1 (diff)
downloadmeta-selinux-111815acce0d04b8b02e24df601a15a3ac94c48b.tar.gz
audit: Fixed swig host contamination issue
CQID: 428272 The audit build uses swig to generate a python wrapper. Unfortunately, the swig info file references host include directories. Some of these were previously noticed and eliminated, but the one fixed here was not. Signed-off-by: Anders Hedlund <anders.hedlund@windriver.com> Signed-off-by: Joe Slater <jslater@windriver.com> Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
-rw-r--r--recipes-security/audit/audit/fix-swig-host-contamination.patch48
-rw-r--r--recipes-security/audit/audit_2.1.3.bb7
-rw-r--r--recipes-security/audit/audit_2.2.1.bb6
3 files changed, 56 insertions, 5 deletions
diff --git a/recipes-security/audit/audit/fix-swig-host-contamination.patch b/recipes-security/audit/audit/fix-swig-host-contamination.patch
new file mode 100644
index 0000000..16bb173
--- /dev/null
+++ b/recipes-security/audit/audit/fix-swig-host-contamination.patch
@@ -0,0 +1,48 @@
1audit: Fixed swig host contamination issue
2
3The audit build uses swig to generate a python wrapper.
4Unfortunately, the swig info file references host include
5directories. Some of these were previously noticed and
6eliminated, but the one fixed here was not.
7
8Upstream Status: pending
9
10Signed-off-by: Anders Hedlund <anders.hedlund@windriver.com>
11Signed-off-by: Joe Slater <jslater@windriver.com>
12
13Index: audit-2.2.1/swig/Makefile.am
14===================================================================
15--- audit-2.2.1.orig/swig/Makefile.am
16+++ audit-2.2.1/swig/Makefile.am
17@@ -25,6 +25,7 @@ AM_CFLAGS = -fPIC -DPIC -fno-strict-alia
18 PYLIBVER ?= python$(PYTHON_VERSION)
19 PYINC ?= /usr/include/$(PYLIBVER)
20 INCLUDES = -I. -I$(top_builddir) -I${top_srcdir}/lib -I$(PYINC)
21+STDINC ?= /usr/include
22 LIBS = $(top_builddir)/lib/libaudit.la
23 pyexec_PYTHON = audit.py
24 pyexec_LTLIBRARIES = _audit.la
25@@ -34,7 +35,7 @@ _audit_la_HEADERS: $(top_builddir)/confi
26 _audit_la_DEPENDENCIES =${top_srcdir}/lib/libaudit.h ${top_builddir}/lib/libaudit.la
27 nodist__audit_la_SOURCES = audit_wrap.c
28 audit.py audit_wrap.c: ${srcdir}/auditswig.i
29- swig -o audit_wrap.c -python ${INCLUDES} ${srcdir}/auditswig.i
30+ swig -o audit_wrap.c -python ${INCLUDES} -I$(STDINC) ${srcdir}/auditswig.i
31
32 CLEANFILES = audit.py* audit_wrap.c *~
33
34Index: audit-2.2.1/swig/auditswig.i
35===================================================================
36--- audit-2.2.1.orig/swig/auditswig.i
37+++ audit-2.2.1/swig/auditswig.i
38@@ -37,8 +37,8 @@ signed
39 #define __attribute(X) /*nothing*/
40 typedef unsigned __u32;
41 typedef unsigned uid_t;
42-%include "/usr/include/linux/audit.h"
43+%include "linux/audit.h"
44 #define __extension__ /*nothing*/
45-%include "/usr/include/stdint.h"
46+%include "stdint.h"
47 %include "../lib/libaudit.h"
48
diff --git a/recipes-security/audit/audit_2.1.3.bb b/recipes-security/audit/audit_2.1.3.bb
index 8c82918..4cd7554 100644
--- a/recipes-security/audit/audit_2.1.3.bb
+++ b/recipes-security/audit/audit_2.1.3.bb
@@ -4,7 +4,7 @@ storing and searching the audit records generated by the audit subsystem \
4in the Linux kernel." 4in the Linux kernel."
5HOMEPAGE = "http://people.redhat.com/sgrubb/audit/" 5HOMEPAGE = "http://people.redhat.com/sgrubb/audit/"
6SECTION = "base" 6SECTION = "base"
7PR = "r1" 7PR = "r2"
8LICENSE = "GPLv2+ & LGPLv2+" 8LICENSE = "GPLv2+ & LGPLv2+"
9LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f" 9LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f"
10 10
@@ -12,7 +12,8 @@ SRC_URI = "http://people.redhat.com/sgrubb/audit/audit-2.1.3.tar.gz \
12 file://disable-ldap.patch \ 12 file://disable-ldap.patch \
13 file://audit-python.patch" 13 file://audit-python.patch"
14 14
15SRC_URI += "file://audit-for-cross-compiling.patch" 15SRC_URI += "file://audit-for-cross-compiling.patch \
16 file://fix-swig-host-contamination.patch"
16 17
17inherit autotools pythonnative 18inherit autotools pythonnative
18 19
@@ -23,7 +24,7 @@ DEPENDS += "python tcp-wrappers libcap-ng linux-libc-headers (>= 2.6.30)"
23 24
24EXTRA_OECONF += "--without-prelude --with-libwrap --enable-gssapi-krb5=no --disable-ldap --with-libcap-ng=yes" 25EXTRA_OECONF += "--without-prelude --with-libwrap --enable-gssapi-krb5=no --disable-ldap --with-libcap-ng=yes"
25 26
26EXTRA_OEMAKE += "PYLIBVER='python${PYTHON_BASEVERSION}' PYINC='${STAGING_INCDIR}/$(PYLIBVER)'" 27EXTRA_OEMAKE += "PYLIBVER='python${PYTHON_BASEVERSION}' PYINC='${STAGING_INCDIR}/$(PYLIBVER)' STDINC='${STAGING_INCDIR}'"
27 28
28SUMMARY_audispd-plugins = "Plugins for the audit event dispatcher" 29SUMMARY_audispd-plugins = "Plugins for the audit event dispatcher"
29DESCRIPTION_audispd-plugins = "The audispd-plugins package provides plugins for the real-time \ 30DESCRIPTION_audispd-plugins = "The audispd-plugins package provides plugins for the real-time \
diff --git a/recipes-security/audit/audit_2.2.1.bb b/recipes-security/audit/audit_2.2.1.bb
index a58b9e1..e0b86e2 100644
--- a/recipes-security/audit/audit_2.2.1.bb
+++ b/recipes-security/audit/audit_2.2.1.bb
@@ -4,7 +4,7 @@ storing and searching the audit records generated by the audit subsystem \
4in the Linux kernel." 4in the Linux kernel."
5HOMEPAGE = "http://people.redhat.com/sgrubb/audit/" 5HOMEPAGE = "http://people.redhat.com/sgrubb/audit/"
6SECTION = "base" 6SECTION = "base"
7PR = "r6" 7PR = "r7"
8LICENSE = "GPLv2+ & LGPLv2+" 8LICENSE = "GPLv2+ & LGPLv2+"
9LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f" 9LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f"
10 10
@@ -15,7 +15,8 @@ SRC_URI = "http://people.redhat.com/sgrubb/audit/audit-${PV}.tar.gz \
15SRC_URI += "\ 15SRC_URI += "\
16 file://audit-python-configure.patch \ 16 file://audit-python-configure.patch \
17 file://audit-cross-compiling.patch \ 17 file://audit-cross-compiling.patch \
18 file://auditd" 18 file://auditd \
19 file://fix-swig-host-contamination.patch"
19 20
20inherit autotools pythonnative update-rc.d 21inherit autotools pythonnative update-rc.d
21 22
@@ -41,6 +42,7 @@ EXTRA_OECONF += "--without-prelude \
41EXTRA_OEMAKE += "PYLIBVER='python${PYTHON_BASEVERSION}' \ 42EXTRA_OEMAKE += "PYLIBVER='python${PYTHON_BASEVERSION}' \
42 PYINC='${STAGING_INCDIR}/$(PYLIBVER)' \ 43 PYINC='${STAGING_INCDIR}/$(PYLIBVER)' \
43 pyexecdir=${libdir}/python${PYTHON_BASEVERSION}/site-packages \ 44 pyexecdir=${libdir}/python${PYTHON_BASEVERSION}/site-packages \
45 STDINC='${STAGING_INCDIR}' \
44 " 46 "
45 47
46SUMMARY_audispd-plugins = "Plugins for the audit event dispatcher" 48SUMMARY_audispd-plugins = "Plugins for the audit event dispatcher"