"extras" subpackage is not provided on RHEL7
This commit is contained in:
parent
63fe8ad424
commit
4cda10f1cc
@ -1,9 +1,10 @@
|
|||||||
%global git_short 3f85c76
|
%global git_short 3f85c76
|
||||||
|
%global with_extras 0%{?fedora} || 0%{?rhel} <= 6
|
||||||
|
|
||||||
Summary: ModSecurity Rules
|
Summary: ModSecurity Rules
|
||||||
Name: mod_security_crs
|
Name: mod_security_crs
|
||||||
Version: 2.2.6
|
Version: 2.2.6
|
||||||
Release: 3%{?dist}
|
Release: 4%{?dist}
|
||||||
License: ASL 2.0
|
License: ASL 2.0
|
||||||
URL: http://www.modsecurity.org/
|
URL: http://www.modsecurity.org/
|
||||||
Group: System Environment/Daemons
|
Group: System Environment/Daemons
|
||||||
@ -19,6 +20,7 @@ BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
|
|||||||
%description
|
%description
|
||||||
This package provides the base rules for mod_security.
|
This package provides the base rules for mod_security.
|
||||||
|
|
||||||
|
%if %with_extras
|
||||||
%package extras
|
%package extras
|
||||||
Summary: Supplementary mod_security rules
|
Summary: Supplementary mod_security rules
|
||||||
Group: System Environment/Daemons
|
Group: System Environment/Daemons
|
||||||
@ -26,6 +28,7 @@ Requires: %name = %version-%release
|
|||||||
|
|
||||||
%description extras
|
%description extras
|
||||||
This package provides supplementary rules for mod_security.
|
This package provides supplementary rules for mod_security.
|
||||||
|
%endif
|
||||||
|
|
||||||
%prep
|
%prep
|
||||||
%setup -q -n SpiderLabs-owasp-modsecurity-crs-%{git_short}
|
%setup -q -n SpiderLabs-owasp-modsecurity-crs-%{git_short}
|
||||||
@ -40,15 +43,21 @@ install -d %{buildroot}%{_sysconfdir}/httpd/modsecurity.d/activated_rules
|
|||||||
|
|
||||||
install -d %{buildroot}%{_prefix}/lib/modsecurity.d/base_rules
|
install -d %{buildroot}%{_prefix}/lib/modsecurity.d/base_rules
|
||||||
|
|
||||||
|
%if %with_extras
|
||||||
install -d %{buildroot}%{_prefix}/lib/modsecurity.d/optional_rules
|
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/experimental_rules
|
||||||
install -d %{buildroot}%{_prefix}/lib/modsecurity.d/slr_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 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/
|
install -m0644 base_rules/* %{buildroot}%{_prefix}/lib/modsecurity.d/base_rules/
|
||||||
|
|
||||||
|
|
||||||
|
%if %with_extras
|
||||||
install -m0644 optional_rules/* %{buildroot}%{_prefix}/lib/modsecurity.d/optional_rules/
|
install -m0644 optional_rules/* %{buildroot}%{_prefix}/lib/modsecurity.d/optional_rules/
|
||||||
install -m0644 experimental_rules/* %{buildroot}%{_prefix}/lib/modsecurity.d/experimental_rules/
|
install -m0644 experimental_rules/* %{buildroot}%{_prefix}/lib/modsecurity.d/experimental_rules/
|
||||||
install -m0644 slr_rules/* %{buildroot}%{_prefix}/lib/modsecurity.d/slr_rules
|
install -m0644 slr_rules/* %{buildroot}%{_prefix}/lib/modsecurity.d/slr_rules
|
||||||
|
%endif
|
||||||
|
|
||||||
# activate base_rules
|
# activate base_rules
|
||||||
for f in `ls %{buildroot}/%{_prefix}/lib/modsecurity.d/base_rules/` ; do
|
for f in `ls %{buildroot}/%{_prefix}/lib/modsecurity.d/base_rules/` ; do
|
||||||
@ -65,12 +74,18 @@ rm -rf %{buildroot}
|
|||||||
%config(noreplace) %{_sysconfdir}/httpd/modsecurity.d/modsecurity_crs_10_config.conf
|
%config(noreplace) %{_sysconfdir}/httpd/modsecurity.d/modsecurity_crs_10_config.conf
|
||||||
%{_prefix}/lib/modsecurity.d/base_rules
|
%{_prefix}/lib/modsecurity.d/base_rules
|
||||||
|
|
||||||
|
|
||||||
|
%if %with_extras
|
||||||
%files extras
|
%files extras
|
||||||
%{_prefix}/lib/modsecurity.d/optional_rules
|
%{_prefix}/lib/modsecurity.d/optional_rules
|
||||||
%{_prefix}/lib/modsecurity.d/experimental_rules
|
%{_prefix}/lib/modsecurity.d/experimental_rules
|
||||||
%{_prefix}/lib/modsecurity.d/slr_rules
|
%{_prefix}/lib/modsecurity.d/slr_rules
|
||||||
|
%endif
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Mon Nov 19 2012 Peter Vrabec <pvrabec@redhat.com> 2.2.6-4
|
||||||
|
- "extras" subpackage is not provided on RHEL7
|
||||||
|
|
||||||
* Wed Oct 17 2012 Athmane Madjoudj <athmane@fedoraproject.org> 2.2.6-3
|
* Wed Oct 17 2012 Athmane Madjoudj <athmane@fedoraproject.org> 2.2.6-3
|
||||||
- Remove the patch since we're requiring mod_security >= 2.7.0
|
- Remove the patch since we're requiring mod_security >= 2.7.0
|
||||||
- Require mod_security >= 2.7.0
|
- Require mod_security >= 2.7.0
|
||||||
|
Loading…
Reference in New Issue
Block a user