2011-05-23 16:20:28 +02:00
|
|
|
#
|
|
|
|
# spec file for package python-semanage
|
|
|
|
#
|
2019-03-21 10:41:18 +01:00
|
|
|
# Copyright (c) 2019 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.
|
|
|
|
|
2019-05-06 09:47:20 +02:00
|
|
|
# Please submit bugfixes or comments via https://bugs.opensuse.org/
|
2011-05-23 16:20:28 +02:00
|
|
|
#
|
|
|
|
|
2011-05-24 13:33:19 +02:00
|
|
|
|
2017-09-28 09:52:04 +02:00
|
|
|
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
|
2016-07-13 09:19:36 +02:00
|
|
|
Name: python-semanage
|
2019-03-21 10:41:18 +01:00
|
|
|
Version: 2.9
|
2016-07-13 09:19:36 +02:00
|
|
|
Release: 0
|
2016-07-26 14:14:00 +02:00
|
|
|
Summary: Python bindings for SELinux's policy management library
|
2018-03-09 08:25:24 +01:00
|
|
|
License: LGPL-2.1-only
|
2016-07-13 09:19:36 +02:00
|
|
|
Group: Development/Languages/Python
|
|
|
|
Url: https://github.com/SELinuxProject/selinux
|
2019-03-21 10:41:18 +01:00
|
|
|
Source: https://github.com/SELinuxProject/selinux/releases/download/20190315/libsemanage-%{version}.tar.gz
|
2016-07-13 09:19:36 +02:00
|
|
|
Source1: baselibs.conf
|
2016-07-14 16:27:12 +02:00
|
|
|
Patch0: suse_path.patch
|
2017-09-28 09:52:04 +02:00
|
|
|
BuildRequires: %{python_module devel}
|
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
|
2017-09-28 09:52:04 +02:00
|
|
|
BuildRequires: python-rpm-macros
|
2011-05-23 16:20:28 +02:00
|
|
|
BuildRequires: swig
|
2016-07-26 14:14:00 +02:00
|
|
|
# Ensure same version
|
2011-05-23 16:20:28 +02:00
|
|
|
Requires: libsemanage1 = %{version}
|
2017-09-28 09:52:04 +02:00
|
|
|
%python_subpackages
|
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}
|
2017-09-28 09:52:04 +02:00
|
|
|
%patch0
|
2011-05-23 16:20:28 +02:00
|
|
|
|
|
|
|
%build
|
2019-05-06 09:47:20 +02:00
|
|
|
%define _lto_cflags %{nil}
|
2016-07-13 09:19:36 +02:00
|
|
|
make %{?_smp_mflags} clean
|
2017-09-28 09:52:04 +02:00
|
|
|
%{python_expand # loop over possible pythons
|
|
|
|
make -j1 PYTHON=$python CFLAGS="%{optflags}" swigify
|
|
|
|
make -j1 PYTHON=$python 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}
|
2017-09-28 09:52:04 +02:00
|
|
|
%{python_expand # loop over possible pythons
|
2018-11-08 12:21:37 +01:00
|
|
|
%make_install install-pywrap PYTHON="$python" \
|
Accepting request 638795 from home:pmonrealgonzalez:branches:security:SELinux
- update to version 2.8
* semanage fcontext -l now also lists home directory entries from
file_contexts.homedirs.
* libsemanage no longer deletes the tmp directory if there is an error
while committing the policy transaction, so that any temporary files
can be further inspected for debugging purposes (e.g. to examine a
particular line of the generated CIL module). The tmp directory will
be deleted upon the next transaction, so no manual removal is needed.
* When overriding PREFIX, BINDIR, SBINDIR, SHLIBDIR, LIBEXECDIR, etc.,
DESTDIR has to be removed from the definition. For example on Arch
Linux, SBINDIR="${pkgdir}/usr/bin" was changed to SBINDIR="/usr/bin".
* PYSITEDIR has been renamed PYTHONLIBDIR (and its definition changed).
- Clened with spec-cleaner
- update to version 2.8
* semanage fcontext -l now also lists home directory entries from
file_contexts.homedirs.
* libsemanage no longer deletes the tmp directory if there is an error
while committing the policy transaction, so that any temporary files
can be further inspected for debugging purposes (e.g. to examine a
particular line of the generated CIL module). The tmp directory will
be deleted upon the next transaction, so no manual removal is needed.
* When overriding PREFIX, BINDIR, SBINDIR, SHLIBDIR, LIBEXECDIR, etc.,
DESTDIR has to be removed from the definition. For example on Arch
Linux, SBINDIR="${pkgdir}/usr/bin" was changed to SBINDIR="/usr/bin".
* PYSITEDIR has been renamed PYTHONLIBDIR (and its definition changed).
- Clened with spec-cleaner
OBS-URL: https://build.opensuse.org/request/show/638795
OBS-URL: https://build.opensuse.org/package/show/security:SELinux/libsemanage?expand=0&rev=66
2018-10-01 09:40:16 +02:00
|
|
|
LIBDIR="%{_libdir}" \
|
|
|
|
LIBEXECDIR="%{_libexecdir}" \
|
2018-11-08 12:21:37 +01:00
|
|
|
SHLIBDIR="%{_libdir}"
|
2017-09-28 09:52:04 +02:00
|
|
|
}
|
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
|
|
|
|
2017-09-28 09:52:04 +02:00
|
|
|
%files %{python_files}
|
2011-05-23 16:32:05 +02:00
|
|
|
%{python_sitearch}/*
|
2011-05-23 16:20:28 +02:00
|
|
|
|
|
|
|
%changelog
|