]> git.pld-linux.org Git - packages/apache-mod_cfg_ldap.git/blob - apache-mod_cfg_ldap.spec
- HTTP group
[packages/apache-mod_cfg_ldap.git] / apache-mod_cfg_ldap.spec
1 %define         mod_name        cfg_ldap
2 %define         apxs            /usr/sbin/apxs
3 Summary:        Module to keep Apache VirtualHost configuration in an LDAP directory
4 Summary(pl.UTF-8):      Moduł do przechowywania konfiguracji serwerów wirtualnych Apache'a w katalogu LDAP
5 Name:           apache-mod_%{mod_name}
6 Version:        1.2
7 Release:        4
8 License:        BSD
9 Group:          Networking/Daemons/HTTP
10 Source0:        http://dl.sourceforge.net/modcfgldap/mod_%{mod_name}-%{version}.tar.gz
11 # Source0-md5:  055924d6488608f684b22e7b04cea2ea
12 Patch0:         %{name}-openldap-2.3.patch
13 URL:            http://modcfgldap.sourceforge.net/
14 BuildRequires:  %{apxs}
15 BuildRequires:  apache-devel >= 2.0
16 BuildRequires:  db-devel >= 4.2.52
17 BuildRequires:  openldap-devel >= 2.4.6
18 BuildRequires:  rpmbuild(macros) >= 1.304
19 Requires:       apache(modules-api) = %apache_modules_api
20 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
21
22 %define         _pkglibdir      %(%{apxs} -q LIBEXECDIR 2>/dev/null)
23 %define         _sysconfdir     %(%{apxs} -q SYSCONFDIR 2>/dev/null)
24 %define         schemadir       /usr/share/openldap/schema
25
26 %description
27 mod_cfg_ldap allows you to keep your virtual host configuration in a
28 LDAP directory and update it in nearly realtime.
29
30 %description -l pl.UTF-8
31 mod_cfg_ldap pozwala na przechowywanie konfiguracji hostów wirtualnych
32 w katalogu LDAP i uaktualnianie jej prawie w czasie rzeczywistym.
33
34 %package -n openldap-schema-mod_cfg_ldap
35 Summary:        mod_cfg_ldap LDAP schema
36 Summary(pl.UTF-8):      Schemat LDAP dla mod_cfg_ldap
37 Group:          Networking/Daemons/HTTP
38 Requires:       openldap-servers
39
40 %description -n openldap-schema-mod_cfg_ldap
41 This package contains LDAP schema for use with mod_cfg_ldap.
42
43 %description -n openldap-schema-mod_cfg_ldap -l pl.UTF-8
44 Ten pakiet zawiera schemat LDAP do używania z mod_cfg_ldap.
45
46 %prep
47 %setup -q -n mod_%{mod_name}-%{version}
48 %patch0 -p1
49
50 %build
51 %{__make} all \
52         APXS=%{apxs}
53
54 %install
55 rm -rf $RPM_BUILD_ROOT
56 install -d $RPM_BUILD_ROOT{%{_pkglibdir},%{_sysconfdir}/httpd.conf}
57
58 install .libs/mod_%{mod_name}.so $RPM_BUILD_ROOT%{_pkglibdir}
59 install cfg_ldap.conf $RPM_BUILD_ROOT%{_sysconfdir}/httpd.conf/85_mod_cfg_ldap.conf
60 install -D mod_cfg_ldap.schema $RPM_BUILD_ROOT%{schemadir}/mod_cfg_ldap.schema
61
62 %clean
63 rm -rf $RPM_BUILD_ROOT
64
65 %post
66 %service -q httpd restart
67
68 %postun
69 if [ "$1" = "0" ]; then
70         %service -q httpd restart
71 fi
72
73 %post -n openldap-schema-mod_cfg_ldap
74 %openldap_schema_register %{schemadir}/mod_cfg_ldap.schema
75 %service -q ldap restart
76
77 %postun -n openldap-schema-mod_cfg_ldap
78 if [ "$1" = "0" ]; then
79         %openldap_schema_unregister %{schemadir}/mod_cfg_ldap.schema
80         %service -q ldap restart
81 fi
82
83 %files
84 %defattr(644,root,root,755)
85 %doc AUTHORS ChangeLog INSTALL README TODO
86 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/httpd.conf/*_mod_%{mod_name}.conf
87 %attr(755,root,root) %{_pkglibdir}/*.so
88
89 %files -n openldap-schema-mod_cfg_ldap
90 %defattr(644,root,root,755)
91 %{schemadir}/*.schema
This page took 0.206862 seconds and 4 git commands to generate.