* [meta-selinux] Install policy headers and include them in the refpolicy dev package.
@ 2013-09-18 1:17 Philip Tricca
2013-09-19 1:10 ` Philip Tricca
0 siblings, 1 reply; 3+ messages in thread
From: Philip Tricca @ 2013-09-18 1:17 UTC (permalink / raw)
To: yocto@yoctoproject.org
This patch is pretty straight forward: All we do is call the
'install-headers' make target at the end of do_install. We then add
the interface 'include' directory to the dev package. This allows
projects that ship their own SELinux policy (not in the refpolicy)
to build against the refpolicy headers / interface files by using
the Makefile supplied by refpolicy.
Signed-off-by: Philip Tricca <flihp@twobit.us>
---
recipes-security/refpolicy/refpolicy_common.inc | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/recipes-security/refpolicy/refpolicy_common.inc b/recipes-security/refpolicy/refpolicy_common.inc
index 2c8891a..0f9f83b 100644
--- a/recipes-security/refpolicy/refpolicy_common.inc
+++ b/recipes-security/refpolicy/refpolicy_common.inc
@@ -12,7 +12,8 @@ SRC_URI += "file://customizable_types \
S = "${WORKDIR}/refpolicy"
FILES_${PN} = "${sysconfdir}/selinux/${POLICY_NAME}/ \
- ${datadir}/selinux/${POLICY_NAME}/"
+ ${datadir}/selinux/${POLICY_NAME}/*.pp"
+FILES_${PN}-dev =+ "${datadir}/selinux/${POLICY_NAME}/include/"
DEPENDS += "checkpolicy-native policycoreutils-native m4-native"
RDEPENDS_${PN} += "policycoreutils selinux-config"
@@ -75,4 +76,7 @@ EOF
cat ${WORKDIR}/customizable_types >> \
${D}${sysconfdir}/selinux/${POLICY_NAME}/contexts/customizable_types
+
+ # install policy headers
+ oe_runmake install-headers DESTDIR=${D}
}
--
1.7.10.4
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [meta-selinux] Install policy headers and include them in the refpolicy dev package.
2013-09-18 1:17 [meta-selinux] Install policy headers and include them in the refpolicy dev package Philip Tricca
@ 2013-09-19 1:10 ` Philip Tricca
2013-09-19 2:13 ` Philip Tricca
0 siblings, 1 reply; 3+ messages in thread
From: Philip Tricca @ 2013-09-19 1:10 UTC (permalink / raw)
To: yocto
On 09/17/2013 09:17 PM, Philip Tricca wrote:
> This patch is pretty straight forward: All we do is call the
> 'install-headers' make target at the end of do_install. We then add
> the interface 'include' directory to the dev package. This allows
> projects that ship their own SELinux policy (not in the refpolicy)
> to build against the refpolicy headers / interface files by using
> the Makefile supplied by refpolicy.
Apologies, I let my MUA mangle that last patch something awful. Fixed below:
Signed-off-by: Philip Tricca <flihp@twobit.us>
---
recipes-security/refpolicy/refpolicy_common.inc | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/recipes-security/refpolicy/refpolicy_common.inc b/recipes-security/refpolicy/refpolicy_common.inc
index 2c8891a..07c05aa 100644
--- a/recipes-security/refpolicy/refpolicy_common.inc
+++ b/recipes-security/refpolicy/refpolicy_common.inc
@@ -12,7 +12,8 @@ SRC_URI += "file://customizable_types \
S = "${WORKDIR}/refpolicy"
FILES_${PN} = "${sysconfdir}/selinux/${POLICY_NAME}/ \
- ${datadir}/selinux/${POLICY_NAME}/"
+ ${datadir}/selinux/${POLICY_NAME}/*.pp"
+FILES_${PN}-dev =+ "${datadir}/selinux/${POLICY_NAME}/include/""
DEPENDS += "checkpolicy-native policycoreutils-native m4-native"
RDEPENDS_${PN} += "policycoreutils selinux-config"
@@ -75,4 +76,7 @@ EOF
cat ${WORKDIR}/customizable_types >> \
${D}${sysconfdir}/selinux/${POLICY_NAME}/contexts/customizable_types
+
+ # install policy headers
+ oe_runmake install-headers DESTDIR=${D}
}
--
1.7.10.
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [meta-selinux] Install policy headers and include them in the refpolicy dev package.
2013-09-19 1:10 ` Philip Tricca
@ 2013-09-19 2:13 ` Philip Tricca
0 siblings, 0 replies; 3+ messages in thread
From: Philip Tricca @ 2013-09-19 2:13 UTC (permalink / raw)
To: yocto
On 09/18/2013 09:10 PM, Philip Tricca wrote:
> On 09/17/2013 09:17 PM, Philip Tricca wrote:
>> This patch is pretty straight forward: All we do is call the
>> 'install-headers' make target at the end of do_install. We then add
>> the interface 'include' directory to the dev package. This allows
>> projects that ship their own SELinux policy (not in the refpolicy)
>> to build against the refpolicy headers / interface files by using
>> the Makefile supplied by refpolicy.
>
> Apologies, I let my MUA mangle that last patch something awful. Fixed below:
>
> Signed-off-by: Philip Tricca <flihp@twobit.us>
> ---
> recipes-security/refpolicy/refpolicy_common.inc | 6 +++++-
> 1 file changed, 5 insertions(+), 1 deletion(-)
>
> diff --git a/recipes-security/refpolicy/refpolicy_common.inc b/recipes-security/refpolicy/refpolicy_common.inc
> index 2c8891a..07c05aa 100644
> --- a/recipes-security/refpolicy/refpolicy_common.inc
> +++ b/recipes-security/refpolicy/refpolicy_common.inc
> @@ -12,7 +12,8 @@ SRC_URI += "file://customizable_types \
> S = "${WORKDIR}/refpolicy"
>
> FILES_${PN} = "${sysconfdir}/selinux/${POLICY_NAME}/ \
> - ${datadir}/selinux/${POLICY_NAME}/"
> + ${datadir}/selinux/${POLICY_NAME}/*.pp"
> +FILES_${PN}-dev =+ "${datadir}/selinux/${POLICY_NAME}/include/""
That last quote in the FILES_${PN}-dev line needs to go. Can resubmit if requested.
>
> DEPENDS += "checkpolicy-native policycoreutils-native m4-native"
> RDEPENDS_${PN} += "policycoreutils selinux-config"
> @@ -75,4 +76,7 @@ EOF
>
> cat ${WORKDIR}/customizable_types >> \
> ${D}${sysconfdir}/selinux/${POLICY_NAME}/contexts/customizable_types
> +
> + # install policy headers
> + oe_runmake install-headers DESTDIR=${D}
> }
>
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2013-09-19 2:13 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-09-18 1:17 [meta-selinux] Install policy headers and include them in the refpolicy dev package Philip Tricca
2013-09-19 1:10 ` Philip Tricca
2013-09-19 2:13 ` Philip Tricca
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.