Enable extra rules sub-package for EPEL

This commit is contained in:
Athmane Madjoudj 2012-09-13 10:31:59 +01:00
parent 42953b1d68
commit 62e63a3d55

View File

@ -1,7 +1,7 @@
Summary: ModSecurity Rules
Name: mod_security_crs
Version: 2.2.5
Release: 4%{?dist}
Release: 5%{?dist}
License: ASL 2.0
URL: http://www.modsecurity.org/
Group: System Environment/Daemons
@ -13,7 +13,6 @@ BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
%description
This package provides the base rules for mod_security.
%if 0%{?fedora}
%package extras
Summary: Supplementary mod_security rules
Group: System Environment/Daemons
@ -21,7 +20,6 @@ Requires: %name = %version-%release
%description extras
This package provides supplementary rules for mod_security.
%endif
%prep
%setup -q -n modsecurity-crs_%{version}
@ -36,19 +34,15 @@ install -d %{buildroot}%{_sysconfdir}/httpd/modsecurity.d/activated_rules
install -d %{buildroot}%{_prefix}/lib/modsecurity.d/base_rules
%if 0%{?fedora}
install -d %{buildroot}%{_prefix}/lib/modsecurity.d/optional_rules
install -d %{buildroot}%{_prefix}/lib/modsecurity.d/experimental_rules
install -d %{buildroot}%{_prefix}/lib/modsecurity.d/slr_rules
%endif
install -m0644 modsecurity_crs_10_setup.conf.example %{buildroot}%{_sysconfdir}/httpd/modsecurity.d/modsecurity_crs_10_config.conf
install -m0644 base_rules/* %{buildroot}%{_prefix}/lib/modsecurity.d/base_rules/
%if 0%{?fedora}
install -m0644 optional_rules/* %{buildroot}%{_prefix}/lib/modsecurity.d/optional_rules/
install -m0644 experimental_rules/* %{buildroot}%{_prefix}/lib/modsecurity.d/experimental_rules/
install -m0644 slr_rules/* %{buildroot}%{_prefix}/lib/modsecurity.d/slr_rules
%endif
# activate base_rules
for f in `ls %{buildroot}/%{_prefix}/lib/modsecurity.d/base_rules/` ; do
@ -65,14 +59,15 @@ rm -rf %{buildroot}
%config(noreplace) %{_sysconfdir}/httpd/modsecurity.d/modsecurity_crs_10_config.conf
%{_prefix}/lib/modsecurity.d/base_rules
%if 0%{?fedora}
%files extras
%{_prefix}/lib/modsecurity.d/optional_rules
%{_prefix}/lib/modsecurity.d/experimental_rules
%{_prefix}/lib/modsecurity.d/slr_rules
%endif
%changelog
* Thu Sep 13 2012 Athmane Madjoudj <athmane@fedoraproject.org> 2.2.5-5
- Enable extra rules sub-package for EPEL.
* Tue Aug 28 2012 Athmane Madjoudj <athmane@fedoraproject.org> 2.2.5-4
- Fix spec for el5