Sophie

Sophie

distrib > Mageia > 5 > i586 > by-pkgid > ca88fe9d133de8e194b771f5f83013ab > files > 3

libselinux-2.3-4.mga5.src.rpm

%define major 1
%define libnameold %mklibname selinux 1
%define libname    %mklibname selinux %{major}
%define libnamedevel %mklibname selinux -d
%define libnamestaticdevel %mklibname selinux -d -s
%define libsepolver 2.2

Name:           libselinux
Version:        2.3
Release:        %mkrel 4
Summary:        SELinux library and simple utilities
License:        Public Domain
Group:          System/Libraries
URL:            http://oss.tresys.com/git/selinux.git
Source0:        http://oss.tresys.com/git/selinux.git/%{name}-%{version}.tar.gz
Source1:        selinuxconlist.8
Source2:        selinuxdefcon.8
Patch0:         libselinux-rhat.patch
BuildRequires:  sepol-static-devel >= %{libsepolver}
BuildRequires:  python-devel
BuildRequires:  pcre-devel
BuildRequires:  swig
BuildRequires:  ruby-devel 
BuildRequires:	lzma-devel
BuildRequires:  ruby

%description
Security-enhanced Linux is a patch of the Linux® kernel and a
number of utilities with enhanced security functionality designed
to add mandatory access controls to Linux. The Security-enhanced
Linux kernel contains new architectural components originally
developed to improve the security of the Flask operating system.
These architectural components provide general support for the
enforcement of many kinds of mandatory access control policies,
including those based on the concepts of Type Enforcement®,
Role-based Access Control, and Multi-level Security.

libselinux provides an API for SELinux applications to get and set
process and file security contexts and to obtain security policy
decisions. Required for any applications that use the SELinux API.

%package -n %{libname}
Summary:        SELinux library and simple utilities
Group:          System/Libraries
Requires(pre):  filesystem >= 2.1.9
Provides:       libselinux = %{version}-%{release}
Provides:       selinux = %{version}-%{release}

%description -n %{libname}
libselinux provides an API for SELinux applications to get and set
process and file security contexts and to obtain security policy
decisions. Required for any applications that use the SELinux API.

%package -n %{libnamedevel}
Summary:        Development libraries and header files for %{name}
Group:          Development/C
Requires(pre):  filesystem >= 2.1.9
Requires:       %{libname} = %{version}-%{release}
Provides:       selinux-devel = %{version}-%{release}
Obsoletes:      %{libnameold}-devel < %{version}-%{release}

%description -n %{libnamedevel}
The selinux-devel package contains the libraries and header
files needed for developing SELinux applications.

%package -n %{libnamestaticdevel}
Summary:        Static development libraries for %{name}
Group:          Development/C
Provides:       selinux-static-devel = %{version}-%{release}
Requires:       %{libnamedevel} = %{version}-%{release}

%description -n %{libnamestaticdevel}
The selinux-static-devel package contains the static libraries
needed for developing SELinux applications.

%package utils
Summary:        Utilities for %{name}
Group:          System/Kernel and hardware
Requires(pre):  filesystem >= 2.1.9

%description utils
This package contains numerous applications utilizing %{name}.

%package -n python-selinux
Summary:        Python bindings for %{name}
Group:          Development/Python
BuildRequires:  python

%description -n python-selinux
This package contains python bindings for %{name}.

%prep
%setup -q
%patch0 -p2 -b .rhat

%build
# Taken from Fedora
# To support building the Python wrapper against multiple Python runtimes
# Define a function, for how to perform a "build" of the python wrapper against
# a specific runtime:
BuildPythonWrapper() {
  BinaryName=$1

  # Perform the build from the upstream Makefile:
  %make \
    PYTHON=$BinaryName \
    LIBDIR="%{_libdir}" CFLAGS="-g %{optflags}" \
    pywrap
}

make clean
%make LIBDIR="%{_libdir}" CFLAGS="-g %{optflags}"  swigify
%make LIBDIR="%{_libdir}" CFLAGS="-g %{optflags}"  all

BuildPythonWrapper %{__python}


%install
install -d %{buildroot}%{_bindir}
install -d %{buildroot}%{_includedir}
install -d %{buildroot}%{_libdir}
install -d %{buildroot}%{_mandir}/man3
install -m 644 %{SOURCE1} %{buildroot}%{_mandir}/man3/
install -m 644 %{SOURCE2} %{buildroot}%{_mandir}/man3/

# (cg) needed to link during make install :s
cp %{_libdir}/libsepol.a %{buildroot}%{_libdir}

%make \
    DESTDIR=%{buildroot} \
    LIBDIR="%{buildroot}%{_libdir}" \
    SHLIBDIR="%{buildroot}%{_libdir}" \
    install install-pywrap

pushd %{buildroot}%{_libdir}
ln -sf libselinux.so.%{major} libselinux.so
popd

# (cg) No longer needed now
rm -f %{buildroot}%{_libdir}/libsepol.a

%files -n %{libname}
%{_libdir}/libselinux.so.%{major}

%files utils
%doc ChangeLog LICENSE
%{_sbindir}/*
%{_mandir}/man?/*

%files -n %{libnamedevel}
%{_includedir}/selinux/*.h
%{_libdir}/*.so
%{_libdir}/pkgconfig/libselinux.pc
%{_libdir}/golang/src/pkg/github.com/selinux/selinux.go

%files -n %{libnamestaticdevel}
%{_libdir}/*.a

%files -n python-selinux
%{py_platsitedir}/*


%changelog
* Wed Oct 15 2014 umeabot <umeabot> 2.3-4.mga5
+ Revision: 745403
- Second Mageia 5 Mass Rebuild

* Sat Sep 27 2014 tv <tv> 2.3-3.mga5
+ Revision: 726862
- rebuild for missing pythoneggs deps

* Tue Sep 16 2014 umeabot <umeabot> 2.3-2.mga5
+ Revision: 681773
- Mageia 5 Mass Rebuild

* Sun Jun 15 2014 spuhler <spuhler> 2.3-1.mga5
+ Revision: 636656
- upgrade to ver 2.3

* Sat May 31 2014 pterjan <pterjan> 2.2.2-2.mga5
+ Revision: 628308
- Rebuild for new Python

* Thu Feb 06 2014 spuhler <spuhler> 2.2.2-1.mga5
+ Revision: 584805
- added BuildRequires: lzma-devel
- upgrade to ver. 2.2.2
- rediffed patch

* Sat Oct 19 2013 umeabot <umeabot> 2.1.13-2.mga4
+ Revision: 535968
- Mageia 4 Mass Rebuild

* Tue Feb 26 2013 spuhler <spuhler> 2.1.13-1.mga4
+ Revision: 400401
- upgrade to 2.1.13
 * audit2why: make sure path is nul terminated
 *utils: new file context regex compiler
 *label_file: use precompiled filecontext when possible
 *do not leak mmapfd
 *sefcontontext_compile: Add error handling to help debug problems in libsemanage.
 *man: make selinux.8 mention service man pages
 *audit2why: Fix segfault if finish() called twice
 *audit2why: do not leak on multiple init() calls
 *mode_to_security_class: interface to translate a mode_t in to a security class
 *audit2why: Cleanup audit2why analysys function
 *man: Fix program synopsis and function prototypes in man pages
 *man: Fix man pages formatting
 *man: Fix typo in man page
 *man: Add references and man page links to _raw function variants
 *Use ENOTSUP instead of EOPNOTSUPP for getfilecon functions
 *man: context_new(3): fix the return value description
 *selinux_status_open: handle error from sysconf
 *selinux_status_open: do not leak statusfd on exec
 *Fix errors found by coverity
 *Change boooleans.subs to booleans.subs_dist.
 *optimize set*con functions
 *pkg-config do not specifc ruby version
 *unmap file contexts on selabel_close()
 *do not leak file contexts with mmap'd backend
 *sefcontext_compile: do not leak fd on error
 *matchmediacon: do not leak fd
 *src/label_android_property: do not leak fd on error
- updated patch from rhat for 2.1.13

* Sat Jan 12 2013 umeabot <umeabot> 2.1.12-3.mga3
+ Revision: 358137
- Mass Rebuild - https://wiki.mageia.org/en/Feature:Mageia3MassRebuild

* Sun Dec 02 2012 spuhler <spuhler> 2.1.12-2.mga3
+ Revision: 324836
- reversed to filesystem >=2.1.9 for the time being

* Sun Dec 02 2012 spuhler <spuhler> 2.1.12-1.mga3
+ Revision: 324734
- added BuilRequires: pcre-devel
- upgrade to 2.1.12
  arranged spec file to make it build
- added selinixdefcon file
- added selinuxconlist file

* Mon Sep 17 2012 fwang <fwang> 2.1.11-2.mga3
+ Revision: 294805
- update file list
- force regenerate symlink

* Sat Jul 21 2012 colin <colin> 2.1.11-1.mga3
+ Revision: 273164
- Add BuildRequire for swig
- New version: 2.1.11
- Update for usrmove

  + tv <tv>
    - new release
    - new release

* Fri Feb 11 2011 dmorgan <dmorgan> 2.0.78-3.mga1
+ Revision: 50036
- Remove mdv macros
- imported package libselinux


* Fri Nov 12 2010 Funda Wang <fwang@mandriva.org> 2.0.78-3mdv2011.0
+ Revision: 596436
- fix build

* Sun Sep 13 2009 Thierry Vignaud <tv@mandriva.org> 2.0.78-2mdv2010.0
+ Revision: 438737
- rebuild

* Fri Mar 06 2009 Jérôme Soyer <saispo@mandriva.org> 2.0.78-1mdv2009.1
+ Revision: 349887
- New upstream release

* Thu Jan 15 2009 Jérôme Soyer <saispo@mandriva.org> 2.0.77-1mdv2009.1
+ Revision: 329813
- New upstream release

* Sun Jan 04 2009 Funda Wang <fwang@mandriva.org> 2.0.76-2mdv2009.1
+ Revision: 324113
- rebuild

* Sun Jan 04 2009 Jérôme Soyer <saispo@mandriva.org> 2.0.76-1mdv2009.1
+ Revision: 324069
- New upstream release

* Sun Jan 04 2009 Jérôme Soyer <saispo@mandriva.org> 2.0.65-1mdv2009.1
+ Revision: 324051
- New upstream release

* Fri Aug 08 2008 Thierry Vignaud <tv@mandriva.org> 2.0.61-2mdv2009.0
+ Revision: 267992
- rebuild early 2009.0 package (before pixel changes)

  + Pixel <pixel@mandriva.com>
    - do not call ldconfig in %%post/%%postun, it is now handled by filetriggers

* Mon Apr 21 2008 David Walluck <walluck@mandriva.org> 2.0.61-1mdv2009.0
+ Revision: 196090
- fix build
- 2.0.61

* Wed Jan 02 2008 David Walluck <walluck@mandriva.org> 2.0.35-1mdv2008.1
+ Revision: 140263
- 2.0.35
- tabs to spaces
- enable parallel make

  + Thierry Vignaud <tv@mandriva.org>
    - kill re-definition of %%buildroot on Pixel's request

* Tue Sep 04 2007 David Walluck <walluck@mandriva.org> 2.0.8-5mdv2008.0
+ Revision: 79171
- fix Provides
- fix major on Obsolete devel package

* Mon Sep 03 2007 David Walluck <walluck@mandriva.org> 2.0.8-3mdv2008.0
+ Revision: 78475
- move %%py_requires -d to python-selinux subpackage

* Mon Sep 03 2007 David Walluck <walluck@mandriva.org> 2.0.8-2mdv2008.0
+ Revision: 78469
- Obsoletes: %%{libname}-devel < %%{version}-%%{release}
- fix static-devel Provides

* Sun Sep 02 2007 David Walluck <walluck@mandriva.org> 2.0.8-1mdv2008.0
+ Revision: 78367
- 2.0.8
- use python macros
- new lib policy
- do not use parallel make

* Sat Aug 11 2007 David Walluck <walluck@mandriva.org> 1.28-2mdv2008.0
+ Revision: 61847
- Provides: selinux-devel

  + Thierry Vignaud <tv@mandriva.org>
    - Import libselinux



* Thu Dec 22 2005 Oden Eriksson <oeriksson@mandriva.com> 1.28-1mdk
- 1.28
- fix deps
- added the python-selinux sub package

* Wed Mar 02 2005 Per Øyvind Karlsen <peroyvind@linux-mandrake.com> 1.21.11-1mdk
- 1.21.11

* Thu Feb 17 2005 Per Øyvind Karlsen <peroyvind@linux-mandrake.com> 1.21.9-1mdk
- 1.21.9
- sync with fedora patch

* Tue Feb 01 2005 Per Øyvind Karlsen <peroyvind@linux-mandrake.com> 1.21.4-1mdk
- 1.21.4
- drop useless provides

* Thu Jan 13 2005 Per Øyvind Karlsen <peroyvind@linux-mandrake.com> 1.20.1-1mdk
- 1.20.1

* Mon Jan 03 2005 Per Øyvind Karlsen <peroyvind@linux-mandrake.com> 1.19.4-1mdk
- 1.19.4

* Fri Dec 10 2004 Per Øyvind Karlsen <peroyvind@linux-mandrake.com> 1.19.3-1mdk
- 1.19.3
- drop P0

* Thu Dec 02 2004 Per Øyvind Karlsen <peroyvind@linux-mandrake.com> 1.19.1-1mdk
- 1.19.1
- sync with fedora patch

* Wed Nov 10 2004 Per Øyvind Karlsen <peroyvind@linux-mandrake.com> 1.18-1mdk
- 1.18

* Wed Aug 18 2004 Per Øyvind Karlsen <peroyvind@linux-mandrake.com> 1.15.4-2mdk
- fix provides

* Wed Aug 18 2004 Per Øyvind Karlsen <peroyvind@linux-mandrake.com> 1.15.4-1mdk
- 1.15.4
- sync patch with fedora
- drop useless-explicit-provides

* Sun Jul 25 2004 Per Øyvind Karlsen <peroyvind@linux-mandrake.com> 1.15.1-1mdk
- 1.15.1

* Wed Jul 14 2004 Per Øyvind Karlsen <peroyvind@linux-mandrake.com> 1.14.1-1mdk
- 1.14.1
- drop P1 (merged upstream)

* Tue Jun 29 2004 Per Øyvind Karlsen <peroyvind@linux-mandrake.com> 1.13.4-1mdk
- 1.13.4
- drop P0 (merged upstream)
- add nlclass patch (P1 from fedora)

* Wed Jun 16 2004 Per Øyvind Karlsen <peroyvind@linux-mandrake.com> 1.13.3-1mdk
- 1.13.3
- update P0 from fedora
- add man pages

* Thu Dec 18 2003 Oden Eriksson <oden.eriksson@kvikkjokk.net> 1.4-1mdk
- initial cooker contrib
- ripped parts from fedora, but adapted for mandrake