Change-Id: I1b695a6c54c4ffcada262f4577ec94179bd82668
Reviewed-on: http://photon-jenkins.eng.vmware.com:8082/2727
Tested-by: gerrit-photon <photon-checkins@vmware.com>
Reviewed-by: Alexey Makhalov <amakhalov@vmware.com>
... | ... |
@@ -1,7 +1,7 @@ |
1 | 1 |
Summary: SELinux library and simple utilities |
2 | 2 |
Name: libselinux |
3 | 3 |
Version: 2.6 |
4 |
-Release: 1%{?dist} |
|
4 |
+Release: 2%{?dist} |
|
5 | 5 |
License: Public Domain |
6 | 6 |
Group: System Environment/Libraries |
7 | 7 |
Source0: https://raw.githubusercontent.com/wiki/SELinuxProject/selinux/files/releases/20160107/%{name}-%{version}.tar.gz |
... | ... |
@@ -49,20 +49,31 @@ Provides: pkgconfig(libselinux) |
49 | 49 |
The libselinux-devel package contains the libraries and header files |
50 | 50 |
needed for developing SELinux applications. |
51 | 51 |
|
52 |
+%package python |
|
53 |
+Summary: SELinux python bindings for libselinux |
|
54 |
+Group: Development/Libraries |
|
55 |
+Requires: libselinux = %{version}-%{release} |
|
56 |
+Requires: python2 |
|
57 |
+Requires: python2-libs |
|
58 |
+ |
|
59 |
+%description python |
|
60 |
+The libselinux-python package contains the python bindings for developing |
|
61 |
+SELinux applications. |
|
62 |
+ |
|
52 | 63 |
%prep |
53 | 64 |
%setup -qn %{name}-%{version} |
54 | 65 |
|
55 | 66 |
%build |
56 |
- |
|
57 |
-make %{?_smp_mflags} |
|
67 |
+make clean |
|
68 |
+make %{?_smp_mflags} swigify |
|
69 |
+make LIBDIR="%{_libdir}" %{?_smp_mflags} pywrap |
|
58 | 70 |
|
59 | 71 |
%install |
60 |
-make DESTDIR=%{buildroot} install |
|
72 |
+make DESTDIR="%{buildroot}" LIBDIR="%{buildroot}%{_libdir}" SHLIBDIR="%{buildroot}/%{_lib}" BINDIR="%{buildroot}%{_bindir}" SBINDIR="%{buildroot}%{_sbindir}" install install-pywrap |
|
61 | 73 |
|
62 | 74 |
mkdir -p %{buildroot}/%{_prefix}/lib/tmpfiles.d |
63 | 75 |
mkdir -p %{buildroot}/var/run/setrans |
64 | 76 |
echo "d /var/run/setrans 0755 root root" > %{buildroot}/%{_prefix}/lib/tmpfiles.d/libselinux.conf |
65 |
-mv %{buildroot}/lib/libselinux.so.* %{buildroot}%{_libdir}/ |
|
66 | 77 |
|
67 | 78 |
%clean |
68 | 79 |
rm -rf %{buildroot} |
... | ... |
@@ -94,14 +105,21 @@ rm -rf %{buildroot} |
94 | 94 |
%{_libdir}/libselinux.a |
95 | 95 |
%{_mandir}/man3/* |
96 | 96 |
|
97 |
+%files python |
|
98 |
+%defattr(-,root,root,-) |
|
99 |
+%dir %{python_sitearch}/selinux |
|
100 |
+%{python_sitearch}/selinux/* |
|
101 |
+ |
|
97 | 102 |
%changelog |
103 |
+* Wed May 22 2017 Harish Udaiya Kumar <hudaiyakumar@vmware.com> 2.6-2 |
|
104 |
+- Include python subpackage. |
|
98 | 105 |
* Wed May 03 2017 Harish Udaiya Kumar <hudaiyakumar@vmware.com> 2.6-1 |
99 | 106 |
- Upgraded to version 2.6 |
100 |
-* Tue May 02 2017 Anish Swaminathan <anishs@vmware.com> 2.5-3 |
|
101 |
-- Remove pcre requires and add requires on pcre-libs |
|
107 |
+* Tue May 02 2017 Anish Swaminathan <anishs@vmware.com> 2.5-3 |
|
108 |
+- Remove pcre requires and add requires on pcre-libs |
|
102 | 109 |
* Tue May 24 2016 Priyesh Padmavilasom <ppadmavilasom@vmware.com> 2.5-2 |
103 | 110 |
- GA - Bump release of all rpms |
104 |
-* Fri Jan 22 2016 Xiaolin Li <xiaolinl@vmware.com> 2.5-1 |
|
105 |
-- Updated to version 2.5 |
|
111 |
+* Fri Jan 22 2016 Xiaolin Li <xiaolinl@vmware.com> 2.5-1 |
|
112 |
+- Updated to version 2.5 |
|
106 | 113 |
* Wed Feb 25 2015 Divya Thaluru <dthaluru@vmware.com> 2.4-1 |
107 | 114 |
- Initial build. First version |