summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorWenzong Fan <wenzong.fan@windriver.com>2015-08-14 03:46:02 -0400
committerJoe MacDonald <joe_macdonald@mentor.com>2015-08-14 12:31:38 -0400
commit6a772ec037db1772b18f5496ab3a37e06e65422a (patch)
tree1f5c564bc4c96fc529cc1fbd34c1910b97131940
parent37f08555b087c1a367ae6ca8639a287aa304fdf9 (diff)
downloadmeta-selinux-6a772ec037db1772b18f5496ab3a37e06e65422a.tar.gz
libselinux: get pywrap depends on selinux.py
The selinux.py will be installed as selinux/__init__.py, just make sure it has been generated completely while starting "make install-pywrap". This fixes below errors that caused by an empty "selinux/__init__.py" on target: $ /usr/sbin/semanage -h Traceback (most recent call last): File "/usr/sbin/semanage", line 30, in <module> import seobject File "/usr/lib64/python2.7/site-packages/seobject.py", line 27, in <module> import sepolicy File "/usr/lib64/python2.7/site-packages/sepolicy/__init__.py", line 226, in <module> def get_file_equiv_modified(fc_path = selinux.selinux_file_context_path()): AttributeError: 'module' object has no attribute 'selinux_file_context_path' Signed-off-by: Wenzong Fan <wenzong.fan@windriver.com> Signed-off-by: Joe MacDonald <joe_macdonald@mentor.com>
-rw-r--r--recipes-security/selinux/libselinux/libselinux-get-pywrap-depends-on-selinux.py.patch31
-rw-r--r--recipes-security/selinux/libselinux_2.3.bb1
-rw-r--r--recipes-security/selinux/libselinux_git.bb1
3 files changed, 33 insertions, 0 deletions
diff --git a/recipes-security/selinux/libselinux/libselinux-get-pywrap-depends-on-selinux.py.patch b/recipes-security/selinux/libselinux/libselinux-get-pywrap-depends-on-selinux.py.patch
new file mode 100644
index 0000000..7994be4
--- /dev/null
+++ b/recipes-security/selinux/libselinux/libselinux-get-pywrap-depends-on-selinux.py.patch
@@ -0,0 +1,31 @@
1From 187ff834e40519b42caa3fba9f1054491f48ab67 Mon Sep 17 00:00:00 2001
2From: Wenzong Fan <wenzong.fan@windriver.com>
3Date: Tue, 11 Aug 2015 16:21:13 +0800
4Subject: [PATCH] libselinux: get pywrap depends on selinux.py
5
6The selinux.py will be installed as selinux/__init__.py, just make sure
7it has been generated completely while starting "make install-pywrap".
8
9Upstream-Status: Pending
10
11Signed-off-by: Wenzong Fan <wenzong.fan@windriver.com>
12---
13 src/Makefile | 2 +-
14 1 file changed, 1 insertion(+), 1 deletion(-)
15
16diff --git a/src/Makefile b/src/Makefile
17index a4d27f4..624d25b 100644
18--- a/src/Makefile
19+++ b/src/Makefile
20@@ -90,7 +90,7 @@ SWIGRUBY = swig -Wall -ruby -o $(SWIGRUBYCOUT) -outdir ./
21
22 all: $(LIBA) $(LIBSO) $(LIBPC)
23
24-pywrap: all $(SWIGSO) $(AUDIT2WHYSO)
25+pywrap: all $(SWIGFILES) $(AUDIT2WHYSO)
26
27 rubywrap: all $(SWIGRUBYSO)
28
29--
301.9.1
31
diff --git a/recipes-security/selinux/libselinux_2.3.bb b/recipes-security/selinux/libselinux_2.3.bb
index 81e599d..23164f1 100644
--- a/recipes-security/selinux/libselinux_2.3.bb
+++ b/recipes-security/selinux/libselinux_2.3.bb
@@ -11,4 +11,5 @@ SRC_URI += "\
11 file://libselinux-make-O_CLOEXEC-optional.patch \ 11 file://libselinux-make-O_CLOEXEC-optional.patch \
12 file://libselinux-make-SOCK_CLOEXEC-optional.patch \ 12 file://libselinux-make-SOCK_CLOEXEC-optional.patch \
13 file://libselinux-define-FD_CLOEXEC-as-necessary.patch \ 13 file://libselinux-define-FD_CLOEXEC-as-necessary.patch \
14 file://libselinux-get-pywrap-depends-on-selinux.py.patch \
14 " 15 "
diff --git a/recipes-security/selinux/libselinux_git.bb b/recipes-security/selinux/libselinux_git.bb
index 97d4649..4efab86 100644
--- a/recipes-security/selinux/libselinux_git.bb
+++ b/recipes-security/selinux/libselinux_git.bb
@@ -11,4 +11,5 @@ SRC_URI += "\
11 file://libselinux-make-O_CLOEXEC-optional.patch \ 11 file://libselinux-make-O_CLOEXEC-optional.patch \
12 file://libselinux-make-SOCK_CLOEXEC-optional.patch \ 12 file://libselinux-make-SOCK_CLOEXEC-optional.patch \
13 file://libselinux-define-FD_CLOEXEC-as-necessary.patch \ 13 file://libselinux-define-FD_CLOEXEC-as-necessary.patch \
14 file://libselinux-get-pywrap-depends-on-selinux.py.patch \
14 " 15 "