All of lore.kernel.org
 help / color / mirror / Atom feed
* [meta-selinux][PATCH 1/1] policycoreutils: fix genhomedircon construction
@ 2013-08-01 16:24 Joe Slater
  0 siblings, 0 replies; 3+ messages in thread
From: Joe Slater @ 2013-08-01 16:24 UTC (permalink / raw)
  To: openembedded-devel

CQID: 418197

Reference /usr/sbin instead of the directory into which
the script is installed on the host.

Signed-off-by: Joe Slater <jslater@windriver.com>
---
 .../selinux/policycoreutils/scripts_makefile.patch |   26 ++++++++++++++++++++
 recipes-security/selinux/policycoreutils_2.1.13.bb |    3 +-
 2 files changed, 28 insertions(+), 1 deletions(-)
 create mode 100644 recipes-security/selinux/policycoreutils/scripts_makefile.patch

diff --git a/recipes-security/selinux/policycoreutils/scripts_makefile.patch b/recipes-security/selinux/policycoreutils/scripts_makefile.patch
new file mode 100644
index 0000000..8972474
--- /dev/null
+++ b/recipes-security/selinux/policycoreutils/scripts_makefile.patch
@@ -0,0 +1,26 @@
+policycoreutils: fix genhomedircon generation
+
+The script is put on the target and needs to reference
+the directory in which semodule is installed.
+
+Upstream Status: pending
+
+Signed-off-by: Joe Slater <jslater@windriver.com>
+
+--- a/scripts/Makefile
++++ b/scripts/Makefile
+@@ -8,11 +8,12 @@ LOCALEDIR ?= $(PREFIX)/share/locale
+ 
+ all: fixfiles genhomedircon chcat
+ 
++# we want the script to use the user sbin directory on the target
++#
+ genhomedircon:
+ 	@echo "#!/bin/sh" > genhomedircon
+ 	@echo >> genhomedircon
+-	@if [ ! -e semodule_path ]; then echo -n "$(USRSBINDIR)/" >> genhomedircon; fi
+-	@if [ -e semodule_path ]; then echo -n "`cat semodule_path`/" >> genhomedircon; fi
++	@echo -n "$(sbindir)/" >> genhomedircon
+ 	@echo "semodule -Bn" >> genhomedircon
+ 
+ install: all
diff --git a/recipes-security/selinux/policycoreutils_2.1.13.bb b/recipes-security/selinux/policycoreutils_2.1.13.bb
index 6696357..687347c 100644
--- a/recipes-security/selinux/policycoreutils_2.1.13.bb
+++ b/recipes-security/selinux/policycoreutils_2.1.13.bb
@@ -1,4 +1,4 @@
-PR = "r2"
+PR = "r3"
 
 include selinux_20120924.inc
 include ${BPN}.inc
@@ -11,4 +11,5 @@ SRC_URI[sha256sum] = "34040f06f3111d9ee957576e4095841d35b9ca9141ee8d80aab036cbef
 SRC_URI += "\
 	file://policycoreutils-revert-restorecon-update-type.patch \
 	file://policycoreutils-revert-run_init-open_init_pty.patch \
+	file://scripts_makefile.patch \
 	"
-- 
1.7.3.4



^ permalink raw reply related	[flat|nested] 3+ messages in thread

* [meta-selinux][PATCH 1/1] policycoreutils: fix genhomedircon construction
@ 2013-08-01 17:25 Joe Slater
  2013-08-02  1:26 ` Mark Hatle
  0 siblings, 1 reply; 3+ messages in thread
From: Joe Slater @ 2013-08-01 17:25 UTC (permalink / raw)
  To: yocto; +Cc: joe.slater

CQID: 418197

Reference /usr/sbin instead of the directory into which
the script is installed on the host.

Signed-off-by: Joe Slater <jslater@windriver.com>
---
 .../selinux/policycoreutils/scripts_makefile.patch |   26 ++++++++++++++++++++
 recipes-security/selinux/policycoreutils_2.1.13.bb |    3 +-
 2 files changed, 28 insertions(+), 1 deletions(-)
 create mode 100644 recipes-security/selinux/policycoreutils/scripts_makefile.patch

diff --git a/recipes-security/selinux/policycoreutils/scripts_makefile.patch b/recipes-security/selinux/policycoreutils/scripts_makefile.patch
new file mode 100644
index 0000000..8972474
--- /dev/null
+++ b/recipes-security/selinux/policycoreutils/scripts_makefile.patch
@@ -0,0 +1,26 @@
+policycoreutils: fix genhomedircon generation
+
+The script is put on the target and needs to reference
+the directory in which semodule is installed.
+
+Upstream Status: pending
+
+Signed-off-by: Joe Slater <jslater@windriver.com>
+
+--- a/scripts/Makefile
++++ b/scripts/Makefile
+@@ -8,11 +8,12 @@ LOCALEDIR ?= $(PREFIX)/share/locale
+ 
+ all: fixfiles genhomedircon chcat
+ 
++# we want the script to use the user sbin directory on the target
++#
+ genhomedircon:
+ 	@echo "#!/bin/sh" > genhomedircon
+ 	@echo >> genhomedircon
+-	@if [ ! -e semodule_path ]; then echo -n "$(USRSBINDIR)/" >> genhomedircon; fi
+-	@if [ -e semodule_path ]; then echo -n "`cat semodule_path`/" >> genhomedircon; fi
++	@echo -n "$(sbindir)/" >> genhomedircon
+ 	@echo "semodule -Bn" >> genhomedircon
+ 
+ install: all
diff --git a/recipes-security/selinux/policycoreutils_2.1.13.bb b/recipes-security/selinux/policycoreutils_2.1.13.bb
index 6696357..687347c 100644
--- a/recipes-security/selinux/policycoreutils_2.1.13.bb
+++ b/recipes-security/selinux/policycoreutils_2.1.13.bb
@@ -1,4 +1,4 @@
-PR = "r2"
+PR = "r3"
 
 include selinux_20120924.inc
 include ${BPN}.inc
@@ -11,4 +11,5 @@ SRC_URI[sha256sum] = "34040f06f3111d9ee957576e4095841d35b9ca9141ee8d80aab036cbef
 SRC_URI += "\
 	file://policycoreutils-revert-restorecon-update-type.patch \
 	file://policycoreutils-revert-run_init-open_init_pty.patch \
+	file://scripts_makefile.patch \
 	"
-- 
1.7.3.4



^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [meta-selinux][PATCH 1/1] policycoreutils: fix genhomedircon construction
  2013-08-01 17:25 [meta-selinux][PATCH 1/1] policycoreutils: fix genhomedircon construction Joe Slater
@ 2013-08-02  1:26 ` Mark Hatle
  0 siblings, 0 replies; 3+ messages in thread
From: Mark Hatle @ 2013-08-02  1:26 UTC (permalink / raw)
  To: Joe Slater; +Cc: yocto, joe.slater

On 8/1/13 12:25 PM, Joe Slater wrote:
> CQID: 418197
>
> Reference /usr/sbin instead of the directory into which
> the script is installed on the host.

This patch and the related audit patch have been applied to both master and 
dylan branches.  Thanks!

--Mark

> Signed-off-by: Joe Slater <jslater@windriver.com>
> ---
>   .../selinux/policycoreutils/scripts_makefile.patch |   26 ++++++++++++++++++++
>   recipes-security/selinux/policycoreutils_2.1.13.bb |    3 +-
>   2 files changed, 28 insertions(+), 1 deletions(-)
>   create mode 100644 recipes-security/selinux/policycoreutils/scripts_makefile.patch
>
> diff --git a/recipes-security/selinux/policycoreutils/scripts_makefile.patch b/recipes-security/selinux/policycoreutils/scripts_makefile.patch
> new file mode 100644
> index 0000000..8972474
> --- /dev/null
> +++ b/recipes-security/selinux/policycoreutils/scripts_makefile.patch
> @@ -0,0 +1,26 @@
> +policycoreutils: fix genhomedircon generation
> +
> +The script is put on the target and needs to reference
> +the directory in which semodule is installed.
> +
> +Upstream Status: pending
> +
> +Signed-off-by: Joe Slater <jslater@windriver.com>
> +
> +--- a/scripts/Makefile
> ++++ b/scripts/Makefile
> +@@ -8,11 +8,12 @@ LOCALEDIR ?= $(PREFIX)/share/locale
> +
> + all: fixfiles genhomedircon chcat
> +
> ++# we want the script to use the user sbin directory on the target
> ++#
> + genhomedircon:
> + 	@echo "#!/bin/sh" > genhomedircon
> + 	@echo >> genhomedircon
> +-	@if [ ! -e semodule_path ]; then echo -n "$(USRSBINDIR)/" >> genhomedircon; fi
> +-	@if [ -e semodule_path ]; then echo -n "`cat semodule_path`/" >> genhomedircon; fi
> ++	@echo -n "$(sbindir)/" >> genhomedircon
> + 	@echo "semodule -Bn" >> genhomedircon
> +
> + install: all
> diff --git a/recipes-security/selinux/policycoreutils_2.1.13.bb b/recipes-security/selinux/policycoreutils_2.1.13.bb
> index 6696357..687347c 100644
> --- a/recipes-security/selinux/policycoreutils_2.1.13.bb
> +++ b/recipes-security/selinux/policycoreutils_2.1.13.bb
> @@ -1,4 +1,4 @@
> -PR = "r2"
> +PR = "r3"
>
>   include selinux_20120924.inc
>   include ${BPN}.inc
> @@ -11,4 +11,5 @@ SRC_URI[sha256sum] = "34040f06f3111d9ee957576e4095841d35b9ca9141ee8d80aab036cbef
>   SRC_URI += "\
>   	file://policycoreutils-revert-restorecon-update-type.patch \
>   	file://policycoreutils-revert-run_init-open_init_pty.patch \
> +	file://scripts_makefile.patch \
>   	"
>



^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2013-08-02  1:26 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-08-01 17:25 [meta-selinux][PATCH 1/1] policycoreutils: fix genhomedircon construction Joe Slater
2013-08-02  1:26 ` Mark Hatle
  -- strict thread matches above, loose matches on Subject: below --
2013-08-01 16:24 Joe Slater

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.