From 4ca0557476009b7eda8706b5d2772d70278291de Mon Sep 17 00:00:00 2001 From: Yi Zhao Date: Tue, 14 Apr 2020 15:41:48 +0800 Subject: libsemanage: upgrade to 3.0 (20191204) * Refresh libsemanage-allow-to-disable-audit-support.patch * Fix typos in patches. Signed-off-by: Yi Zhao Signed-off-by: Joe MacDonald --- recipes-security/selinux/libsemanage.inc | 2 +- .../libsemanage-allow-to-disable-audit-support.patch | 14 +++++++------- .../libsemanage-define-FD_CLOEXEC-as-necessary.patch | 2 +- .../libsemanage-drop-Wno-unused-but-set-variable.patch | 2 +- recipes-security/selinux/libsemanage_2.9.bb | 15 --------------- recipes-security/selinux/libsemanage_3.0.bb | 15 +++++++++++++++ 6 files changed, 25 insertions(+), 25 deletions(-) delete mode 100644 recipes-security/selinux/libsemanage_2.9.bb create mode 100644 recipes-security/selinux/libsemanage_3.0.bb diff --git a/recipes-security/selinux/libsemanage.inc b/recipes-security/selinux/libsemanage.inc index 81a3eda..0139511 100644 --- a/recipes-security/selinux/libsemanage.inc +++ b/recipes-security/selinux/libsemanage.inc @@ -6,7 +6,7 @@ on binary policies such as customizing policy boolean settings." SECTION = "base" LICENSE = "LGPLv2.1+" -inherit lib_package python3-dir +inherit lib_package python3native DEPENDS += "libsepol libselinux bzip2 python3 bison-native flex-native swig-native" DEPENDS_append_class-target = " audit" diff --git a/recipes-security/selinux/libsemanage/libsemanage-allow-to-disable-audit-support.patch b/recipes-security/selinux/libsemanage/libsemanage-allow-to-disable-audit-support.patch index 6ea9c29..c588b61 100644 --- a/recipes-security/selinux/libsemanage/libsemanage-allow-to-disable-audit-support.patch +++ b/recipes-security/selinux/libsemanage/libsemanage-allow-to-disable-audit-support.patch @@ -1,4 +1,4 @@ -From 50f8f9f090425d23ecab2bedc949bc65bc4d58dc Mon Sep 17 00:00:00 2001 +From 1633f72579e3b79d055759256b71e4169627889b Mon Sep 17 00:00:00 2001 From: Wenzong Fan Date: Mon, 20 Jan 2014 03:53:48 -0500 Subject: [PATCH] libsemanage: allow to disable audit support @@ -13,7 +13,7 @@ Signed-off-by: Wenzong Fan 3 files changed, 31 insertions(+), 2 deletions(-) diff --git a/src/Makefile b/src/Makefile -index 8240c3a..1485d23 100644 +index 3bd1e20..483e818 100644 --- a/src/Makefile +++ b/src/Makefile @@ -26,6 +26,14 @@ ifeq ($(DEBUG),1) @@ -41,7 +41,7 @@ index 8240c3a..1485d23 100644 $(LIBPC): $(LIBPC).in ../VERSION diff --git a/src/seusers_local.c b/src/seusers_local.c -index a79e2d3..ce76dee 100644 +index 3e2761c..8bc6b83 100644 --- a/src/seusers_local.c +++ b/src/seusers_local.c @@ -8,7 +8,11 @@ typedef struct semanage_seuser record_t; @@ -98,10 +98,10 @@ index a79e2d3..ce76dee 100644 semanage_seuser_free(seuser); return rc; diff --git a/tests/Makefile b/tests/Makefile -index 324766a..5732ec7 100644 +index 69f49a3..f914492 100644 --- a/tests/Makefile +++ b/tests/Makefile -@@ -3,10 +3,18 @@ SOURCES = $(sort $(wildcard *.c)) +@@ -4,10 +4,18 @@ CILS = $(sort $(wildcard *.cil)) ########################################################################### @@ -119,8 +119,8 @@ index 324766a..5732ec7 100644 -override LDLIBS += -lcunit -lbz2 -laudit -lselinux -lsepol +override LDLIBS += -lcunit -lbz2 $(LIBAUDIT) -lselinux -lsepol - OBJECTS = $(SOURCES:.c=.o) - + OBJECTS = $(SOURCES:.c=.o) + POLICIES = $(CILS:.cil=.policy) -- 2.7.4 diff --git a/recipes-security/selinux/libsemanage/libsemanage-define-FD_CLOEXEC-as-necessary.patch b/recipes-security/selinux/libsemanage/libsemanage-define-FD_CLOEXEC-as-necessary.patch index 0c77c7a..45bcbe6 100644 --- a/recipes-security/selinux/libsemanage/libsemanage-define-FD_CLOEXEC-as-necessary.patch +++ b/recipes-security/selinux/libsemanage/libsemanage-define-FD_CLOEXEC-as-necessary.patch @@ -7,7 +7,7 @@ In truly old systems, even FD_CLOEXEC may not be defined. Produce a warning and duplicate the #define for FD_CLOEXEC found in asm-generic/fcntl.h on more modern platforms. -Uptream-Status: Inappropriate +Upstream-Status: Inappropriate Signed-off-by: Joe MacDonald --- diff --git a/recipes-security/selinux/libsemanage/libsemanage-drop-Wno-unused-but-set-variable.patch b/recipes-security/selinux/libsemanage/libsemanage-drop-Wno-unused-but-set-variable.patch index de71e27..c9b052c 100644 --- a/recipes-security/selinux/libsemanage/libsemanage-drop-Wno-unused-but-set-variable.patch +++ b/recipes-security/selinux/libsemanage/libsemanage-drop-Wno-unused-but-set-variable.patch @@ -3,7 +3,7 @@ From: Randy MacLeod Date: Tue, 30 Apr 2013 23:15:57 -0400 Subject: [PATCH] libselinux: drop flag: -Wno-unused-but-set-variable -Upstream-Status: Inappropriate (older compilers only). +Upstream-Status: Inappropriate [older compilers only] Signed-off-by: Randy MacLeod --- diff --git a/recipes-security/selinux/libsemanage_2.9.bb b/recipes-security/selinux/libsemanage_2.9.bb deleted file mode 100644 index 83320a1..0000000 --- a/recipes-security/selinux/libsemanage_2.9.bb +++ /dev/null @@ -1,15 +0,0 @@ -require selinux_20190315.inc -require ${BPN}.inc - -LIC_FILES_CHKSUM = "file://COPYING;md5=a6f89e2100d9b6cdffcea4f398e37343" - -SRC_URI[md5sum] = "25f086ff66175a0ca0e7b34dbe8586b7" -SRC_URI[sha256sum] = "2576349d344492e73b468059767268dec1dabd8c35f3c7222c3ec2448737bc1c" - -SRC_URI += "\ - file://libsemanage-Fix-execve-segfaults-on-Ubuntu.patch \ - file://libsemanage-drop-Wno-unused-but-set-variable.patch \ - file://libsemanage-define-FD_CLOEXEC-as-necessary.patch \ - file://libsemanage-allow-to-disable-audit-support.patch \ - file://libsemanage-disable-expand-check-on-policy-load.patch \ - " diff --git a/recipes-security/selinux/libsemanage_3.0.bb b/recipes-security/selinux/libsemanage_3.0.bb new file mode 100644 index 0000000..450675b --- /dev/null +++ b/recipes-security/selinux/libsemanage_3.0.bb @@ -0,0 +1,15 @@ +require selinux_20191204.inc +require ${BPN}.inc + +LIC_FILES_CHKSUM = "file://COPYING;md5=a6f89e2100d9b6cdffcea4f398e37343" + +SRC_URI[md5sum] = "17a2fc780af0a36f2cf27ab7c4e85946" +SRC_URI[sha256sum] = "a497b0720d54eac427f1f3f618eed417e50ed8f4e47ed0f7a1d391bd416e84cf" + +SRC_URI += "\ + file://libsemanage-Fix-execve-segfaults-on-Ubuntu.patch \ + file://libsemanage-drop-Wno-unused-but-set-variable.patch \ + file://libsemanage-define-FD_CLOEXEC-as-necessary.patch \ + file://libsemanage-allow-to-disable-audit-support.patch \ + file://libsemanage-disable-expand-check-on-policy-load.patch \ + " -- cgit v1.2.3-54-g00ecf