1 %define mod_name sqlinclude
2 %define apxs /usr/sbin/apxs
3 Summary: Apache module: mySQL based "Include"-alike configuration command
4 Summary(pl): Modu³ do apache: bazuj±ca na mySQL komenda konfiguracji ala "Include"
5 Name: apache-mod_%{mod_name}
9 Group: Networking/Daemons
10 Source0: http://dl.sourceforge.net/mod-sqlinclude/mod_sqlinclude-%{version}.tgz
11 URL: http://sourceforge.net/projects/mod-sqlinclude/
12 BuildRequires: apache(EAPI)-devel
13 BuildRequires: mysql-devel
14 Requires(post,preun): %{apxs}
15 Requires: apache(EAPI)
16 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
18 %define _pkglibdir %(%{apxs} -q LIBEXECDIR)
19 %define _sysconfdir /etc/httpd
22 mod_sqlinclude is an Apache Web server module which implements mySQL
23 based "Include"-alike configuration command. This lets you keep your
24 httpd config in database (i.e. VHosts etc).
27 Modu³ do serwera Apache implementuj±cy bazuj±c± na mySQL komendê
28 konfiguracyjn± typu "Include". Dziêki temu mo¿esz trzymaæ swoj±
29 konfiguracjê w bazie SQL.
32 %setup -q -n mod_%{mod_name}-%{version}
38 rm -rf $RPM_BUILD_ROOT
39 install -d $RPM_BUILD_ROOT%{_pkglibdir}
41 install mod_%{mod_name}.so $RPM_BUILD_ROOT%{_pkglibdir}
44 rm -rf $RPM_BUILD_ROOT
47 %{apxs} -e -a -n %{mod_name} %{_pkglibdir}/mod_%{mod_name}.so 1>&2
48 if [ -f /var/lock/subsys/httpd ]; then
49 /etc/rc.d/init.d/httpd restart 1>&2
53 if [ "$1" = "0" ]; then
54 %{apxs} -e -A -n %{mod_name} %{_pkglibdir}/mod_%{mod_name}.so 1>&2
55 if [ -f /var/lock/subsys/httpd ]; then
56 /etc/rc.d/init.d/httpd restart 1>&2
61 %defattr(644,root,root,755)
62 %doc CHANGE* README* *.sql
63 %attr(755,root,root) %{_pkglibdir}/*