mirror of
git://git.yoctoproject.org/meta-selinux
synced 2026-01-01 13:58:04 +00:00
recipes: WORKDIR -> UNPACKDIR transition
* WORKDIR -> UNPACKDIR transition * Switch away from S = WORKDIR Signed-off-by: Changqing Li <changqing.li@windriver.com> Signed-off-by: Joe MacDonald <joe.macdonald@siemens.com>
This commit is contained in:
parent
8784122dde
commit
de19386222
|
|
@ -214,12 +214,12 @@ EOF
|
||||||
}
|
}
|
||||||
|
|
||||||
install_misc_files() {
|
install_misc_files() {
|
||||||
cat ${WORKDIR}/customizable_types >> \
|
cat ${UNPACKDIR}/customizable_types >> \
|
||||||
${D}${sysconfdir}/selinux/${POLICY_NAME}/contexts/customizable_types
|
${D}${sysconfdir}/selinux/${POLICY_NAME}/contexts/customizable_types
|
||||||
|
|
||||||
# Install setrans.conf for mls/mcs policy
|
# Install setrans.conf for mls/mcs policy
|
||||||
if [ -f ${WORKDIR}/setrans-${POLICY_TYPE}.conf ]; then
|
if [ -f ${UNPACKDIR}/setrans-${POLICY_TYPE}.conf ]; then
|
||||||
install -m 0644 ${WORKDIR}/setrans-${POLICY_TYPE}.conf \
|
install -m 0644 ${UNPACKDIR}/setrans-${POLICY_TYPE}.conf \
|
||||||
${D}${sysconfdir}/selinux/${POLICY_NAME}/setrans.conf
|
${D}${sysconfdir}/selinux/${POLICY_NAME}/setrans.conf
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,6 @@
|
||||||
S ?= "${WORKDIR}"
|
S ?= "${WORKDIR}/sources"
|
||||||
|
UNPACKDIR = "${S}"
|
||||||
|
|
||||||
SECTION ?= "base"
|
SECTION ?= "base"
|
||||||
|
|
||||||
# Default is for script name to be the same as the recipe name.
|
# Default is for script name to be the same as the recipe name.
|
||||||
|
|
@ -21,17 +23,17 @@ FILES:${PN} += "/.autorelabel"
|
||||||
|
|
||||||
do_install () {
|
do_install () {
|
||||||
install -d ${D}${sysconfdir}/init.d/
|
install -d ${D}${sysconfdir}/init.d/
|
||||||
install -m 0755 ${WORKDIR}/${SELINUX_SCRIPT_SRC}.sh ${D}${sysconfdir}/init.d/${SELINUX_SCRIPT_DST}
|
install -m 0755 ${S}/${SELINUX_SCRIPT_SRC}.sh ${D}${sysconfdir}/init.d/${SELINUX_SCRIPT_DST}
|
||||||
# Insert the relabelling code which is only needed with sysvinit
|
# Insert the relabelling code which is only needed with sysvinit
|
||||||
sed -i -e '/HERE/r ${WORKDIR}/${SELINUX_SCRIPT_SRC}.sh.sysvinit' \
|
sed -i -e '/HERE/r ${S}/${SELINUX_SCRIPT_SRC}.sh.sysvinit' \
|
||||||
-e '/.*HERE$/d' -e '/.*Contents.*sysvinit/d' \
|
-e '/.*HERE$/d' -e '/.*Contents.*sysvinit/d' \
|
||||||
${D}${sysconfdir}/init.d/${SELINUX_SCRIPT_DST}
|
${D}${sysconfdir}/init.d/${SELINUX_SCRIPT_DST}
|
||||||
|
|
||||||
if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then
|
if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then
|
||||||
install -d ${D}${systemd_unitdir}/system
|
install -d ${D}${systemd_unitdir}/system
|
||||||
install -m 0644 ${WORKDIR}/${SELINUX_SCRIPT_SRC}.service ${D}${systemd_unitdir}/system
|
install -m 0644 ${S}/${SELINUX_SCRIPT_SRC}.service ${D}${systemd_unitdir}/system
|
||||||
install -d ${D}${bindir}
|
install -d ${D}${bindir}
|
||||||
install -m 0755 ${WORKDIR}/${SELINUX_SCRIPT_SRC}.sh ${D}${bindir}
|
install -m 0755 ${S}/${SELINUX_SCRIPT_SRC}.sh ${D}${bindir}
|
||||||
sed -i -e '/.*HERE$/d' ${D}${bindir}/${SELINUX_SCRIPT_SRC}.sh
|
sed -i -e '/.*HERE$/d' ${D}${bindir}/${SELINUX_SCRIPT_SRC}.sh
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -166,9 +166,9 @@ do_install:class-native() {
|
||||||
}
|
}
|
||||||
|
|
||||||
do_install:append:class-target() {
|
do_install:append:class-target() {
|
||||||
if [ -e ${WORKDIR}/pam.d ]; then
|
if [ -e ${UNPACKDIR}/pam.d ]; then
|
||||||
install -d ${D}${sysconfdir}/pam.d/
|
install -d ${D}${sysconfdir}/pam.d/
|
||||||
install -m 0644 ${WORKDIR}/pam.d/* ${D}${sysconfdir}/pam.d/
|
install -m 0644 ${UNPACKDIR}/pam.d/* ${D}${sysconfdir}/pam.d/
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# /var/lib/selinux is involved by seobject.py:
|
# /var/lib/selinux is involved by seobject.py:
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user