forked from pool/selinux-policy
d1d3770b71
OBS-URL: https://build.opensuse.org/package/show/security:SELinux/selinux-policy?expand=0&rev=9
106 lines
2.6 KiB
RPMSpec
106 lines
2.6 KiB
RPMSpec
#
|
|
# spec file for package selinux-policy
|
|
#
|
|
# Copyright (c) 2008 SUSE LINUX Products GmbH, Nuernberg, Germany.
|
|
# This file and all modifications and additions to the pristine
|
|
# package are under the same license as the package itself.
|
|
#
|
|
# Please submit bugfixes or comments via http://bugs.opensuse.org/
|
|
#
|
|
|
|
# norootforbuild
|
|
|
|
|
|
Name: selinux-policy
|
|
Version: 20081014
|
|
Release: 1
|
|
Url: http://oss.tresys.com/projects/refpolicy/
|
|
License: GPL v2
|
|
Group: System/Base
|
|
Summary: SELinux policies
|
|
Source: refpolicy-%{version}.tar.bz2
|
|
Patch0: %{name}-build_conf.patch
|
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
|
BuildRequires: checkpolicy policycoreutils libsepol-devel python python-xml m4
|
|
BuildArch: noarch
|
|
|
|
%description
|
|
|
|
SELinux policies
|
|
|
|
%package refpolicy-standard
|
|
Group: System/Base
|
|
Summary: SELinux policy - Tresys Standard Refpolicy
|
|
Provides: selinux-policy
|
|
|
|
%description refpolicy-standard
|
|
|
|
SELinux policy - based on reference policy from Tresys - standard
|
|
|
|
%package refpolicy-mcs
|
|
Group: System/Base
|
|
Summary: SELinux policy - Tresys MCS Refpolicy
|
|
Provides: selinux-policy
|
|
|
|
%description refpolicy-mcs
|
|
|
|
SELinux policy - based on reference policy from Tresys - mcs
|
|
|
|
%package refpolicy-mls
|
|
Group: System/Base
|
|
Summary: SELinux policy - Tresys MLS Refpolicy
|
|
Provides: selinux-policy
|
|
|
|
%description refpolicy-mls
|
|
|
|
SELinux policy - based on reference policy from Tresys - mls
|
|
|
|
%prep
|
|
%setup -q -c -n selinux-policy -T
|
|
tar xfj %{SOURCE0} && mv refpolicy refpolicy-standard
|
|
tar xfj %{SOURCE0} && mv refpolicy refpolicy-mcs
|
|
tar xfj %{SOURCE0} && mv refpolicy refpolicy-mls
|
|
%patch0
|
|
|
|
%build
|
|
for i in standard mcs mls; do
|
|
cd refpolicy-$i
|
|
make conf
|
|
make policy
|
|
cd ..
|
|
done
|
|
|
|
%install
|
|
for i in standard mcs mls; do
|
|
cd refpolicy-$i
|
|
make DESTDIR=$RPM_BUILD_ROOT install
|
|
sed -i "s:^# edit $RPM_BUILD_ROOT:# edit :" $RPM_BUILD_ROOT%{_sysconfdir}/selinux/refpolicy-$i/contexts/files/file_contexts.homedirs
|
|
cd ..
|
|
done
|
|
|
|
%clean
|
|
rm -rf $RPM_BUILD_ROOT
|
|
|
|
%files refpolicy-standard
|
|
%defattr(-,root,root)
|
|
%doc COPYING Changelog README
|
|
%dir %{_sysconfdir}/selinux
|
|
%dir %{_sysconfdir}/selinux/refpolicy-standard
|
|
%{_sysconfdir}/selinux/refpolicy-standard/*
|
|
|
|
%files refpolicy-mcs
|
|
%defattr(-,root,root)
|
|
%doc COPYING Changelog README
|
|
%dir %{_sysconfdir}/selinux
|
|
%dir %{_sysconfdir}/selinux/refpolicy-mcs
|
|
%{_sysconfdir}/selinux/refpolicy-mcs/*
|
|
|
|
%files refpolicy-mls
|
|
%defattr(-,root,root)
|
|
%doc COPYING Changelog README
|
|
%dir %{_sysconfdir}/selinux
|
|
%dir %{_sysconfdir}/selinux/refpolicy-mls
|
|
%{_sysconfdir}/selinux/refpolicy-mls/*
|
|
|
|
%changelog
|