mirror of
git://git.yoctoproject.org/meta-selinux
synced 2026-01-01 13:58:04 +00:00
selinux-python: add package 2.7 (20170804)
Move packages to python/*: - policycoreutils/semanage -> python/semanage - policycoreutils/audit2allow -> python/audit2allow - policycoreutils/sepolgen-ifgen -> python/audit2allow/sepolgen-ifgen - policycoreutils/sepolicy -> python/sepolicy - policycoreutils/scripts/chcat -> python/chcat - sepolgen -> python/sepolgen * Move and rebase patches: - policycoreutils-fix-TypeError-for-seobject.py.patch - policycoreutils-fix-sepolicy-install-path.patch - policycoreutils-process-ValueError-for-sepolicy-seobject.patch * Cleanup policycoreutils.inc and policycoreutils_2.7.bb Signed-off-by: Wenzong Fan <wenzong.fan@windriver.com> Update policycoreutils_git.bb Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
This commit is contained in:
parent
a5b5f5b328
commit
1d3df562b7
|
|
@ -23,19 +23,6 @@ inherit selinux pythonnative
|
|||
|
||||
DEPENDS += "${@target_selinux(d, 'libpam audit')}"
|
||||
|
||||
RDEPENDS_${BPN}-audit2allow = "\
|
||||
python-textutils \
|
||||
libselinux-python \
|
||||
sepolgen \
|
||||
"
|
||||
RDEPENDS_${BPN}-chcat = "\
|
||||
python-codecs \
|
||||
python-shell \
|
||||
python-stringold \
|
||||
python-unixadmin \
|
||||
${BPN}-python \
|
||||
libselinux-python \
|
||||
"
|
||||
RDEPENDS_${BPN}-fixfiles += "\
|
||||
${BPN}-setfiles \
|
||||
"
|
||||
|
|
@ -51,27 +38,8 @@ RDEPENDS_${BPN}-newrole += "\
|
|||
libcap-ng \
|
||||
libselinux \
|
||||
"
|
||||
RDEPENDS_${BPN}-python += "\
|
||||
python-codecs \
|
||||
python-io \
|
||||
python-ipy \
|
||||
python-re \
|
||||
python-stringold \
|
||||
python-syslog \
|
||||
python-unixadmin \
|
||||
libselinux-python \
|
||||
libsemanage-python \
|
||||
"
|
||||
RDEPENDS_${BPN}-runinit += "libselinux"
|
||||
RDEPENDS_${BPN}-secon += "libselinux"
|
||||
RDEPENDS_${BPN}-semanage = "\
|
||||
python-core \
|
||||
python-ipy \
|
||||
python-compression \
|
||||
python-xml \
|
||||
${BPN}-python \
|
||||
libselinux-python \
|
||||
"
|
||||
RDEPENDS_${BPN}-semodule += "\
|
||||
libsepol \
|
||||
libselinux \
|
||||
|
|
@ -82,16 +50,6 @@ DEPENDS_${BPN}-semodule-deps += "libsepol"
|
|||
RDEPENDS_${BPN}-semodule-expand += "libsepol libselinux"
|
||||
RDEPENDS_${BPN}-semodule-link += "libsepol libselinux"
|
||||
RDEPENDS_${BPN}-semodule-package += "libsepol libselinux"
|
||||
RDEPENDS_${BPN}-sepolicy += "\
|
||||
python-argparse \
|
||||
python-codecs \
|
||||
python-core \
|
||||
python-syslog \
|
||||
${BPN}-python \
|
||||
"
|
||||
# static link to libsepol
|
||||
DEPENDS_${BPN}-sepolgen-ifgen += "libsepol"
|
||||
RDEPENDS_${BPN}-sepolgen-ifgen += "python libselinux-python"
|
||||
RDEPENDS_${BPN}-sestatus += "libselinux"
|
||||
RDEPENDS_${BPN}-setfiles += "\
|
||||
libselinux \
|
||||
|
|
@ -102,43 +60,30 @@ RDEPENDS_${BPN}-setsebool += "\
|
|||
libselinux \
|
||||
libsemanage \
|
||||
"
|
||||
RDEPENDS_${BPN} += "setools setools-libs ${BPN}-python"
|
||||
RDEPENDS_${BPN} += "setools setools-libs selinux-python"
|
||||
|
||||
WARN_QA := "${@oe_filter_out('unsafe-references-in-scripts', '${WARN_QA}', d)}"
|
||||
ERROR_QA := "${@oe_filter_out('unsafe-references-in-scripts', '${ERROR_QA}', d)}"
|
||||
|
||||
|
||||
PACKAGES =+ "\
|
||||
${PN}-audit2allow \
|
||||
${PN}-chcat \
|
||||
${PN}-fixfiles \
|
||||
${PN}-genhomedircon \
|
||||
${PN}-hll \
|
||||
${PN}-loadpolicy \
|
||||
${PN}-newrole \
|
||||
${PN}-python \
|
||||
${PN}-runinit \
|
||||
${PN}-secon \
|
||||
${PN}-semanage \
|
||||
${PN}-semodule \
|
||||
${PN}-semodule-deps \
|
||||
${PN}-semodule-expand \
|
||||
${PN}-semodule-link \
|
||||
${PN}-semodule-package \
|
||||
${PN}-sepolgen-ifgen \
|
||||
${PN}-sepolicy \
|
||||
${PN}-sestatus \
|
||||
${PN}-setfiles \
|
||||
${PN}-setsebool \
|
||||
system-config-selinux \
|
||||
"
|
||||
FILES_${PN}-audit2allow = "\
|
||||
${bindir}/audit2allow \
|
||||
${bindir}/audit2why \
|
||||
"
|
||||
FILES_${PN}-chcat = "\
|
||||
${bindir}/chcat \
|
||||
"
|
||||
FILES_${PN}-fixfiles += "${base_sbindir}/fixfiles"
|
||||
FILES_${PN}-genhomedircon += "${sbindir}/genhomedircon"
|
||||
FILES_${PN}-loadpolicy += "\
|
||||
|
|
@ -149,22 +94,13 @@ FILES_${PN}-newrole += "\
|
|||
${bindir}/newrole \
|
||||
${@bb.utils.contains('DISTRO_FEATURES', 'pam', '${sysconfdir}/pam.d/newrole', '', d)} \
|
||||
"
|
||||
FILES_${PN}-python = "\
|
||||
${libdir}/python${PYTHON_BASEVERSION}/site-packages/seobject.py* \
|
||||
${libdir}/python${PYTHON_BASEVERSION}/site-packages/sepolicy*.egg-info \
|
||||
${libdir}/python${PYTHON_BASEVERSION}/site-packages/sepolicy/* \
|
||||
"
|
||||
FILES_${PN}-runinit += "\
|
||||
${sbindir}/run_init \
|
||||
${sbindir}/open_init_pty \
|
||||
${@bb.utils.contains('DISTRO_FEATURES', 'pam', '${sysconfdir}/pam.d/run_init', '', d)} \
|
||||
"
|
||||
FILES_${PN}-dbg += "${libdir}/python${PYTHON_BASEVERSION}/site-packages/sepolicy/.debug/* ${prefix}/libexec/selinux/hll/.debug"
|
||||
FILES_${PN}-dbg += "${prefix}/libexec/selinux/hll/.debug"
|
||||
FILES_${PN}-secon += "${bindir}/secon"
|
||||
FILES_${PN}-semanage = "\
|
||||
${sbindir}/semanage \
|
||||
${datadir}/bash-completion/completions/semanage \
|
||||
"
|
||||
FILES_${PN}-semodule += "${sbindir}/semodule"
|
||||
FILES_${PN}-semodule-deps += "${bindir}/semodule_deps"
|
||||
FILES_${PN}-semodule-expand += "${bindir}/semodule_expand"
|
||||
|
|
@ -174,17 +110,6 @@ FILES_${PN}-semodule-package += "\
|
|||
${bindir}/semodule_unpackage \
|
||||
"
|
||||
FILES_${PN}-hll += "${prefix}/libexec/selinux/hll/*"
|
||||
|
||||
FILES_${PN}-sepolicy += "\
|
||||
${bindir}/sepolicy \
|
||||
${datadir}/bash-completion/completions/sepolicy \
|
||||
${datadir}/dbus-1/system-services/org.selinux.service \
|
||||
${datadir}/polkit-1/actions/org.selinux.policy \
|
||||
"
|
||||
FILES_${PN}-sepolgen-ifgen += "\
|
||||
${bindir}/sepolgen-ifgen \
|
||||
${bindir}/sepolgen-ifgen-attr-helper \
|
||||
"
|
||||
FILES_${PN}-sestatus += "\
|
||||
${sbindir}/sestatus \
|
||||
${sysconfdir}/sestatus.conf \
|
||||
|
|
@ -199,7 +124,6 @@ FILES_${PN}-setsebool += "\
|
|||
"
|
||||
|
||||
FILES_system-config-selinux = " \
|
||||
${bindir}/sepolgen \
|
||||
${datadir}/system-config-selinux/* \
|
||||
${datadir}/icons/hicolor/ \
|
||||
${datadir}/polkit-1/actions/org.selinux.config.policy \
|
||||
|
|
|
|||
|
|
@ -7,8 +7,5 @@ SRC_URI[md5sum] = "65311b66ae01f7b7ad7c2ea7401b68ed"
|
|||
SRC_URI[sha256sum] = "0a1b8a4a323b854981c6755ff025fe98a0f1cff307f109abb260f0490f13e4f4"
|
||||
|
||||
SRC_URI += "\
|
||||
file://policycoreutils-fix-sepolicy-install-path.patch \
|
||||
file://policycoreutils-loadpolicy-symlink.patch \
|
||||
file://policycoreutils-process-ValueError-for-sepolicy-seobject.patch \
|
||||
file://policycoreutils-fix-TypeError-for-seobject.py.patch \
|
||||
"
|
||||
|
|
|
|||
|
|
@ -6,8 +6,5 @@ include ${BPN}.inc
|
|||
LIC_FILES_CHKSUM = "file://COPYING;md5=393a5ca445f6965873eca0259a17f833"
|
||||
|
||||
SRC_URI += "\
|
||||
file://policycoreutils-fix-sepolicy-install-path.patch \
|
||||
file://policycoreutils-loadpolicy-symlink.patch \
|
||||
file://policycoreutils-process-ValueError-for-sepolicy-seobject.patch \
|
||||
file://policycoreutils-fix-TypeError-for-seobject.py.patch \
|
||||
"
|
||||
|
|
|
|||
106
recipes-security/selinux/selinux-python.inc
Normal file
106
recipes-security/selinux/selinux-python.inc
Normal file
|
|
@ -0,0 +1,106 @@
|
|||
SUMMARY = "Python modules and various SELinux utilities."
|
||||
DESCRIPTION = "\
|
||||
This package contains Python modules sepolgen, sepolicy; And the \
|
||||
SELinux utilities audit2allow, chcat, semanage ..."
|
||||
|
||||
SECTION = "base"
|
||||
LICENSE = "GPLv2+"
|
||||
|
||||
SRC_URI += "file://fix-sepolicy-install-path.patch \
|
||||
file://fix-TypeError-for-seobject.py.patch \
|
||||
file://process-ValueError-for-sepolicy-seobject.patch \
|
||||
"
|
||||
|
||||
inherit python-dir
|
||||
|
||||
DEPENDS += "python-native libsepol"
|
||||
RDEPENDS_${BPN}-audit2allow += "\
|
||||
python-textutils \
|
||||
libselinux-python \
|
||||
${BPN}-sepolgen \
|
||||
"
|
||||
RDEPENDS_${BPN}-chcat += "\
|
||||
python-codecs \
|
||||
python-shell \
|
||||
python-stringold \
|
||||
python-unixadmin \
|
||||
libselinux-python \
|
||||
${BPN} \
|
||||
"
|
||||
RDEPENDS_${BPN} += "\
|
||||
python-codecs \
|
||||
python-io \
|
||||
python-ipy \
|
||||
python-re \
|
||||
python-stringold \
|
||||
python-syslog \
|
||||
python-unixadmin \
|
||||
libselinux-python \
|
||||
libsemanage-python \
|
||||
"
|
||||
RDEPENDS_${BPN}-semanage += "\
|
||||
python-core \
|
||||
python-ipy \
|
||||
python-compression \
|
||||
python-xml \
|
||||
libselinux-python \
|
||||
${BPN} \
|
||||
"
|
||||
RDEPENDS_${BPN}-sepolicy += "\
|
||||
python-argparse \
|
||||
python-codecs \
|
||||
python-core \
|
||||
python-syslog \
|
||||
${BPN} \
|
||||
"
|
||||
RDEPENDS_${BPN}-sepolgen-ifgen += "\
|
||||
python \
|
||||
libselinux-python \
|
||||
"
|
||||
|
||||
PACKAGES =+ "\
|
||||
${PN}-audit2allow \
|
||||
${PN}-sepolgen-ifgen \
|
||||
${PN}-chcat \
|
||||
${PN}-semanage \
|
||||
${PN}-sepolgen \
|
||||
${PN}-sepolicy \
|
||||
"
|
||||
FILES_${PN}-audit2allow = "\
|
||||
${bindir}/audit2allow \
|
||||
${bindir}/audit2why \
|
||||
"
|
||||
FILES_${PN}-chcat = "\
|
||||
${bindir}/chcat \
|
||||
"
|
||||
FILES_${PN}-semanage = "\
|
||||
${sbindir}/semanage \
|
||||
${datadir}/bash-completion/completions/semanage \
|
||||
"
|
||||
# The ${bindir}/sepolgen is a symlink to ${bindir}/sepolicy
|
||||
FILES_${PN}-sepolicy += "\
|
||||
${bindir}/sepolgen \
|
||||
${bindir}/sepolicy \
|
||||
${datadir}/bash-completion/completions/sepolicy \
|
||||
"
|
||||
FILES_${PN}-sepolgen-ifgen += "\
|
||||
${bindir}/sepolgen-ifgen \
|
||||
${bindir}/sepolgen-ifgen-attr-helper \
|
||||
"
|
||||
FILES_${PN}-sepolgen += "\
|
||||
${libdir}/python${PYTHON_BASEVERSION}/site-packages/sepolgen* \
|
||||
${localstatedir}/lib/sepolgen/perm_map \
|
||||
"
|
||||
# Map to policycoreutils-python in 2.6
|
||||
FILES_${PN} += "\
|
||||
${libdir}/python${PYTHON_BASEVERSION}/site-packages/seobject.py* \
|
||||
${libdir}/python${PYTHON_BASEVERSION}/site-packages/sepolicy*.egg-info \
|
||||
${libdir}/python${PYTHON_BASEVERSION}/site-packages/sepolicy/* \
|
||||
"
|
||||
|
||||
EXTRA_OEMAKE += "LIBSEPOLA=${STAGING_LIBDIR}/libsepol.a"
|
||||
do_install() {
|
||||
oe_runmake DESTDIR=${D} \
|
||||
PYTHONLIBDIR='${libdir}/python${PYTHON_BASEVERSION}/site-packages' \
|
||||
install
|
||||
}
|
||||
7
recipes-security/selinux/selinux-python_2.7.bb
Normal file
7
recipes-security/selinux/selinux-python_2.7.bb
Normal file
|
|
@ -0,0 +1,7 @@
|
|||
include selinux_20170804.inc
|
||||
include ${BPN}.inc
|
||||
|
||||
LIC_FILES_CHKSUM = "file://COPYING;md5=393a5ca445f6965873eca0259a17f833"
|
||||
|
||||
SRC_URI[md5sum] = "b118229d34a6aec34471c3c2c9cac172"
|
||||
SRC_URI[sha256sum] = "4217cb965ecda96c91e15ffcc2e7ddd13ecc2bf5631100f3cd072a7616f140ed"
|
||||
Loading…
Reference in New Issue
Block a user