2011-05-23 16:20:28 +02:00
|
|
|
#
|
|
|
|
# spec file for package python-semanage
|
|
|
|
#
|
2016-07-13 09:19:36 +02:00
|
|
|
# Copyright (c) 2016 SUSE LINUX GmbH, Nuernberg, Germany.
|
2011-05-23 16:20:28 +02:00
|
|
|
#
|
|
|
|
# All modifications and additions to the file contributed by third parties
|
|
|
|
# remain the property of their copyright owners, unless otherwise agreed
|
|
|
|
# upon. The license for this file, and modifications and additions to the
|
|
|
|
# file, is the same license as for the pristine package itself (unless the
|
|
|
|
# license for the pristine package is not an Open Source License, in which
|
|
|
|
# case the license is the MIT License). An "Open Source License" is a
|
|
|
|
# license that conforms to the Open Source Definition (Version 1.9)
|
|
|
|
# published by the Open Source Initiative.
|
|
|
|
|
|
|
|
# Please submit bugfixes or comments via http://bugs.opensuse.org/
|
|
|
|
#
|
|
|
|
|
2011-05-24 13:33:19 +02:00
|
|
|
|
2016-07-13 09:19:36 +02:00
|
|
|
Name: python-semanage
|
|
|
|
Version: 2.5
|
|
|
|
Release: 0
|
2016-07-26 14:14:00 +02:00
|
|
|
Summary: Python bindings for SELinux's policy management library
|
2016-07-13 09:19:36 +02:00
|
|
|
License: LGPL-2.1
|
|
|
|
Group: Development/Languages/Python
|
|
|
|
Url: https://github.com/SELinuxProject/selinux
|
|
|
|
Source: https://raw.githubusercontent.com/wiki/SELinuxProject/selinux/files/releases/20160223/libsemanage-%{version}.tar.gz
|
|
|
|
Source1: baselibs.conf
|
2016-07-14 16:27:12 +02:00
|
|
|
Patch0: suse_path.patch
|
2013-11-07 11:20:19 +01:00
|
|
|
BuildRequires: audit-devel
|
2011-05-23 16:20:28 +02:00
|
|
|
BuildRequires: bison
|
|
|
|
BuildRequires: flex
|
2012-10-23 12:01:57 +02:00
|
|
|
BuildRequires: libbz2-devel
|
2012-10-25 09:25:37 +02:00
|
|
|
BuildRequires: libselinux-devel
|
2012-08-01 09:57:49 +02:00
|
|
|
BuildRequires: libsepol-devel
|
2011-05-23 16:20:28 +02:00
|
|
|
BuildRequires: libustr-devel
|
|
|
|
BuildRequires: python-devel
|
|
|
|
BuildRequires: swig
|
2016-07-26 14:14:00 +02:00
|
|
|
# Ensure same version
|
2011-05-23 16:20:28 +02:00
|
|
|
Requires: libsemanage1 = %{version}
|
2016-07-13 09:19:36 +02:00
|
|
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
2011-05-23 16:20:28 +02:00
|
|
|
|
|
|
|
%description
|
2016-07-26 14:14:00 +02:00
|
|
|
This package contains the Python bindings for developing
|
|
|
|
SELinux policy management applications.
|
2011-05-23 16:20:28 +02:00
|
|
|
|
|
|
|
%prep
|
2011-05-23 16:26:25 +02:00
|
|
|
%setup -q -n libsemanage-%{version}
|
2016-07-14 16:27:12 +02:00
|
|
|
%patch0 -p0
|
2011-05-23 16:20:28 +02:00
|
|
|
|
|
|
|
%build
|
2016-07-13 09:19:36 +02:00
|
|
|
make %{?_smp_mflags} clean
|
2011-05-23 16:20:28 +02:00
|
|
|
make -j1 CFLAGS="%{optflags}" swigify
|
2016-07-13 09:19:36 +02:00
|
|
|
make -j1 CFLAGS="%{optflags}" LIBDIR="%{_libdir}" LIBEXECDIR="%{_libexecdir}" SHLIBDIR="%{_lib}" all pywrap
|
2011-05-23 16:20:28 +02:00
|
|
|
|
|
|
|
%install
|
|
|
|
mkdir -p %{buildroot}/%{_lib}
|
|
|
|
mkdir -p %{buildroot}%{_libdir}
|
|
|
|
mkdir -p %{buildroot}%{_includedir}
|
2016-07-13 09:19:36 +02:00
|
|
|
make DESTDIR=%{buildroot} LIBDIR="%{buildroot}%{_libdir}" LIBEXECDIR="%{buildroot}%{_libexecdir}" SHLIBDIR="%{buildroot}/%{_lib}" install install-pywrap
|
2011-05-23 16:32:05 +02:00
|
|
|
|
|
|
|
# remove files contained in other packages
|
|
|
|
rm -rf %{buildroot}%{_sysconfdir}
|
2016-07-13 09:19:36 +02:00
|
|
|
%if "%{_lib}" == "lib64"
|
|
|
|
rm -rf %{buildroot}%{_libexecdir}
|
|
|
|
%else
|
|
|
|
rm -rf %{buildroot}%{_libexecdir}/selinux
|
|
|
|
%endif
|
2011-05-23 16:32:05 +02:00
|
|
|
rm -rf %{buildroot}%{_includedir}
|
|
|
|
rm -f %{buildroot}%{_libdir}/libsemanage.*
|
|
|
|
rm -rf %{buildroot}%{_libdir}/pkgconfig
|
|
|
|
rm -rf %{buildroot}%{_mandir}
|
2011-05-23 16:20:28 +02:00
|
|
|
|
|
|
|
%files
|
|
|
|
%defattr(-,root,root)
|
2011-05-23 16:32:05 +02:00
|
|
|
%{python_sitearch}/*
|
2011-05-23 16:20:28 +02:00
|
|
|
|
|
|
|
%changelog
|