]>
Commit | Line | Data |
---|---|---|
1 | # TODO | |
2 | # - apache config | |
3 | # - package split by backend | |
4 | %define mod_name pointer | |
5 | %define apxs %{_sbindir}/apxs1 | |
6 | Summary: Apache module for making domain redirects | |
7 | Name: apache1-mod_%{mod_name} | |
8 | Version: 0.8 | |
9 | Release: 0.1 | |
10 | License: Apache | |
11 | Group: Networking/Daemons | |
12 | Source0: http://stderr.net/mod_pointer/dist/mod_pointer-%{version}.tar.gz | |
13 | # Source0-md5: 2f6529c49f1d10ecd06d3f6bc8503a5f | |
14 | URL: http://stderr.net/mod_pointer/ | |
15 | BuildRequires: apache1-devel >= 1.3.33-2 | |
16 | BuildRequires: gdbm-devel | |
17 | BuildRequires: mysql-devel | |
18 | BuildRequires: postgresql-devel | |
19 | BuildRequires: rpmbuild(macros) >= 1.268 | |
20 | Requires: apache1 >= 1.3.33-2 | |
21 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
22 | ||
23 | %define _pkglibdir %(%{apxs} -q LIBEXECDIR 2>/dev/null) | |
24 | %define _sysconfdir %(%{apxs} -q SYSCONFDIR 2>/dev/null) | |
25 | ||
26 | %description | |
27 | mod_pointer is an Apache module for making domain redirects easy - the | |
28 | known service of many hosting providers that lets a domain point to | |
29 | your webpage on another server. | |
30 | ||
31 | The configuration part of the mappings are handled in either a MySQL | |
32 | or Postgresql database or a NDBM or SDBM db file, so it's easy to | |
33 | build a webbased interface for letting users change it on their own. | |
34 | ||
35 | %prep | |
36 | %setup -q -n mod_%{mod_name}-%{version} | |
37 | ||
38 | %build | |
39 | %{__make} all \ | |
40 | WITH_APXS=%{apxs} | |
41 | ||
42 | %install | |
43 | rm -rf $RPM_BUILD_ROOT | |
44 | install -d $RPM_BUILD_ROOT{%{_pkglibdir},%{_sysconfdir}/conf.d} | |
45 | ||
46 | %{__make} install \ | |
47 | APXS="%{apxs} -S DESTDIR=$RPM_BUILD_ROOT" | |
48 | ||
49 | %clean | |
50 | rm -rf $RPM_BUILD_ROOT | |
51 | ||
52 | %post | |
53 | %service -q apache restart | |
54 | ||
55 | %postun | |
56 | if [ "$1" = "0" ]; then | |
57 | %service -q apache restart | |
58 | fi | |
59 | ||
60 | %files | |
61 | %defattr(644,root,root,755) | |
62 | %doc README CHANGES | |
63 | #%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/conf.d/*_mod_%{mod_name}.conf | |
64 | %attr(755,root,root) %{_pkglibdir}/* |