meta-selinux/recipes-security/setools/setools_4.5.1.bb
Joe MacDonald 1d4fd0208a selinux: upgrade to core 3.7 and setools to 4.5.1
These two patches:

https://lists.yoctoproject.org/g/yocto-patches/message/392
https://lists.yoctoproject.org/g/yocto-patches/message/393

were missed earlier this year but we definitely want these updates.
Recreating them manually since I'm unable to find the original patches
anywhere.

Signed-off-by: Joe MacDonald <joe.macdonald@siemens.com>
2024-12-10 12:36:25 -05:00

39 lines
1.3 KiB
BlitzBasic

SUMMARY = "Policy analysis tools for SELinux"
DESCRIPTION = "\
SETools is a collection of graphical tools, command-line tools, and \
libraries designed to facilitate SELinux policy analysis."
SECTION = "base"
LICENSE = "GPL-2.0-only & LGPL-2.1-only"
SRC_URI = "git://github.com/SELinuxProject/${BPN}.git;branch=4.5;protocol=https \
file://setools4-fixes-for-cross-compiling.patch \
"
SRCREV = "659ec47aba0126e3a198362ed1659bf600c067eb"
LIC_FILES_CHKSUM = "file://${S}/COPYING;md5=69a7b68f0a4a570d7c0c43465333ecbc \
file://${S}/COPYING.GPL;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
file://${S}/COPYING.LGPL;md5=4fbd65380cdd255951079008b364516c"
S = "${WORKDIR}/git"
DEPENDS = "python3-cython-native libsepol libselinux"
RDEPENDS:${PN} = "python3-networkx python3-setuptools \
python3-logging libselinux-python"
RPROVIDES:${PN} = "${PN}-console"
inherit setuptools3
do_install:prepend() {
sed -i -e 's:${RECIPE_SYSROOT}::g' ${S}/setools/policyrep.c
}
do_install:append() {
# Need PyQt5 support, disable gui tools
rm -f ${D}${bindir}/apol
rm -rf ${D}${libdir}/${PYTHON_DIR}/site-packages/setoolsgui
rm -rf ${D}${libdir}/${PYTHON_DIR}/site-packages/setools/__pycache__
rm -rf ${D}${libdir}/${PYTHON_DIR}/site-packages/setools/*/__pycache__
}