]> git.pld-linux.org Git - packages/apache-mod_bw.git/blame - apache-mod_bw.spec
- up to 0.92, builds
[packages/apache-mod_bw.git] / apache-mod_bw.spec
CommitLineData
a5de1fd2 1# TODO:
5d474532 2# - cron?
ac0fe2df 3%define mod_name bw
1dd6fe21 4%define apxs /usr/sbin/apxs
e44745e2 5Summary: Apache module: bandwidth limits
d5c887ee 6Summary(pl.UTF-8): Moduł do Apache: limity pasma
1dd6fe21 7Name: apache-mod_%{mod_name}
0e16d960
ER
8Version: 0.92
9Release: 1
e44745e2 10License: Apache
abe986cb 11Group: Networking/Daemons/HTTP
0e16d960
ER
12Source0: http://ivn.cl/files/source/mod_bw-%{version}.tgz
13# Source0-md5: 90f5e632dad5de8d49dcdb61453dcf97
0511ec6d 14Source1: %{name}.conf
1dd6fe21 15URL: http://www.ivn.cl/apache/
d8882fd8 16BuildRequires: %{apxs}
b9a8f100 17BuildRequires: apache-devel >= 2.0.0
b2f4d847 18BuildRequires: rpmbuild(macros) >= 1.268
6fc9aff3
ER
19BuildRequires: sed >= 4.0
20Requires: apache(modules-api) = %apache_modules_api
348c5ac8 21Requires: crondaemon
e44745e2
JB
22Requires: procps
23BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
24
6fc9aff3
ER
25%define _pkglibdir %(%{apxs} -q LIBEXECDIR 2>/dev/null)
26%define _sysconfdir %(%{apxs} -q SYSCONFDIR 2>/dev/null)
e44745e2
JB
27
28%description
29"Mod_bandwidth" is a module for the Apache webserver that enable the
30setting of server-wide or per connection bandwidth limits, based on
31the directory, size of files and remote IP/domain.
32
c944853d
JR
33%description -l pl.UTF-8
34Moduł pozwalający na ograniczanie pasma serwera Apache bazując na
35katalogu, wielkości plików lub zdalnym IP/domenie.
e44745e2
JB
36
37%prep
0e16d960 38%setup -qc
ed6ddc97
ER
39
40%build
0e16d960 41%{apxs} -c mod_bw.c
e44745e2
JB
42
43%install
44rm -rf $RPM_BUILD_ROOT
ed6ddc97 45install -d $RPM_BUILD_ROOT{%{_pkglibdir},%{_sysconfdir}/httpd.conf} \
e44745e2 46 $RPM_BUILD_ROOT%{_var}/run/%{name}/{link,master} \
ed6ddc97 47 $RPM_BUILD_ROOT{/etc/cron.d,%{_sbindir}}
e44745e2 48
0e16d960
ER
49install -p .libs/mod_bw.so $RPM_BUILD_ROOT%{_pkglibdir}/mod_%{mod_name}.so
50cp -p %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/httpd.conf/97_mod_%{mod_name}.conf
e44745e2
JB
51
52%clean
53rm -rf $RPM_BUILD_ROOT
54
55%post
b2f4d847 56%service -q httpd restart
e44745e2 57
8d98470e 58%postun
e44745e2 59if [ "$1" = "0" ]; then
b2f4d847 60 %service -q httpd restart
e44745e2
JB
61fi
62
63%files
64%defattr(644,root,root,755)
0e16d960 65%doc mod_bw.txt LICENSE ChangeLog
ed6ddc97 66%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/httpd.conf/*_mod_%{mod_name}.conf
c67d93f1 67%attr(755,root,root) %{_pkglibdir}/*.so
0511ec6d
MWP
68#%config(noreplace) %verify(not size mtime md5) %attr(640,root,root) /etc/cron.d/%{name}
69#%attr(755,root,root) %{_sbindir}/*
e44745e2
JB
70%attr(750,http,root) %dir %{_var}/run/%{name}
71%attr(750,http,root) %dir %{_var}/run/%{name}/link
72%attr(750,http,root) %dir %{_var}/run/%{name}/master
This page took 0.222209 seconds and 4 git commands to generate.