]> git.pld-linux.org Git - packages/pdns.git/blob - pdns.spec
- converted to UTF-8
[packages/pdns.git] / pdns.spec
1 Summary:        PowerDNS is a Versatile Database Driven Nameserver
2 Summary(pl.UTF-8):   PowerDNS to wielofunkcyjny serwer nazw korzystający z relacyjnych baz danych
3 Name:           pdns
4 Version:        2.9.20
5 Release:        3
6 License:        GPL
7 Group:          Networking/Daemons
8 Source0:        http://downloads.powerdns.com/releases/%{name}-%{version}.tar.gz
9 # Source0-md5:  33b20ef1b767f93297101f2aa09e99ed
10 Source1:        http://downloads.powerdns.com/documentation/%{name}.pdf
11 # Source1-md5:  3ce3a16df5d91ceab75dea8307b35f2c
12 Source2:        http://downloads.powerdns.com/documentation/%{name}.txt
13 Source3:        %{name}.init
14 Source4:        %{name}.conf
15 Source5:        %{name}.sysconfig
16 Patch0:         %{name}-configure.patch
17 Patch1:         %{name}-int16.patch
18 Patch2:         %{name}-openldap-2.3.patch
19 URL:            http://www.powerdns.com/
20 BuildRequires:  bison
21 BuildRequires:  boost-devel
22 BuildRequires:  boost-ref-devel
23 BuildRequires:  flex
24 BuildRequires:  libpq++-devel
25 BuildRequires:  libstdc++-devel
26 BuildRequires:  mysql-devel
27 BuildRequires:  openldap-devel >= 2.3.0
28 BuildRequires:  rpmbuild(macros) >= 1.268
29 BuildRequires:  zlib-devel
30 Requires(post): sed >= 4.0
31 Requires(post,preun):   /sbin/chkconfig
32 Requires(postun):       /usr/sbin/groupdel
33 Requires(postun):       /usr/sbin/userdel
34 Requires(pre):  /bin/id
35 Requires(pre):  /usr/bin/getgid
36 Requires(pre):  /usr/sbin/groupadd
37 Requires(pre):  /usr/sbin/useradd
38 Requires:       rc-scripts
39 Provides:       group(djbdns)
40 Provides:       nameserver
41 Provides:       user(pdns)
42 Obsoletes:      powerdns
43 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
44
45 %description
46 PowerDNS is a versatile nameserver which supports a large number of
47 different backends ranging from simple zonefiles to relational
48 databases and load balancing/failover algorithms.
49
50 %description -l pl.UTF-8
51 PowerDNS to wielofunkcyjny serwer nazw posiadający dużą liczbę wtyczek
52 od prostych stref (a'la BIND) począwszy, a na relacyjnych bazach
53 danych skończywszy oraz zawierający algorytmy zrównoważenia obciążenia
54 i przełączania w wypadku awarii.
55
56 %package backend-pipe
57 Summary:        PowerDNS support for custom pipe backend
58 Summary(pl.UTF-8):   Wsparcie PowerDNS dla własnego mechanizmu przechowywania stref
59 Group:          Development/Libraries
60 Requires:       %{name} = %{version}-%{release}
61
62 %description backend-pipe
63 This package allows creation of own backend using simple STDIN/STDOUT
64 API. Example backend script in Perl is provided in package
65 documentation.
66
67 %description backend-pipe -l pl.UTF-8
68 Ten pakiet pozwala na utworzenie własnego mechanizmu przechowywania
69 stref za pomocą prostego interfejsu STDIN/STDOUT. Przykładowy skrypt w
70 Perlu został dołączony do dokumentacji pakietu.
71
72 %package backend-gpgsql
73 Summary:        PowerDNS support for PostgreSQL
74 Summary(pl.UTF-8):   Wsparcie PowerDNS dla baz PostgresQL
75 Group:          Development/Libraries
76 Requires:       %{name} = %{version}-%{release}
77
78 %description backend-gpgsql
79 This package allows zone storage in PostgreSQL relational db tables.
80
81 %description backend-gpgsql -l pl.UTF-8
82 Ten pakiet pozwala na przechowywanie danych o strefach w tabelach
83 relacyjnej bazy danych PostgreSQL.
84
85 %package backend-gmysql
86 Summary:        PowerDNS support for MySQL
87 Summary(pl.UTF-8):   Wsparcie PowerDNS dla baz MySQL
88 Group:          Development/Libraries
89 Requires:       %{name} = %{version}-%{release}
90
91 %description backend-gmysql
92 This package allows zone storage in MySQL relational db tables.
93
94 %description backend-gmysql -l pl.UTF-8
95 Ten pakiet pozwala na przechowywanie danych o strefach w tabelach
96 relacyjnej bazy danych MySQL.
97
98 %package backend-ldap
99 Summary:        PowerDNS support for LDAP
100 Summary(pl.UTF-8):   Wsparcie PowerDNS dla baz LDAP
101 Group:          Development/Libraries
102 Requires:       %{name} = %{version}-%{release}
103
104 %description backend-ldap
105 This package allows zone storage in LDAP directory.
106
107 %description backend-ldap -l pl.UTF-8
108 Ten pakiet pozwala na przechowywanie danych o strefach w katalogu
109 LDAP.
110
111 %prep
112 %setup -q
113 %patch0 -p1
114 %patch1 -p1
115 %patch2 -p1
116 cp %{SOURCE1} .
117 cp %{SOURCE2} .
118
119 %build
120 CPPFLAGS="-DHAVE_NAMESPACE_STD -DHAVE_CXX_STRING_HEADER -DDLLIMPORT=\"\""
121 %configure \
122         --libdir=%{_libdir}/%{name} \
123         --sysconfdir=%{_sysconfdir}/%{name} \
124         --with-socketdir=/var/run \
125         --with-dynmodules="gmysql gpgsql pipe ldap" \
126         --with-modules="" \
127         --enable-mysql \
128         --enable-pgsql \
129         --with-pgsql-lib=%{_libdir} \
130         --with-pgsql-includes=%{_includedir} \
131         --with-mysql-lib=%{_libdir} \
132         --with-mysql-includes=%{_includedir} \
133         --enable-ldap \
134         --disable-static
135
136 %{__make}
137
138 %install
139 rm -rf $RPM_BUILD_ROOT
140 install -d $RPM_BUILD_ROOT{%{_initrddir},%{_sysconfdir}/%{name},/etc/sysconfig}
141
142 %{__make} install \
143         DESTDIR=$RPM_BUILD_ROOT
144
145 install %{SOURCE3} $RPM_BUILD_ROOT%{_initrddir}/%{name}
146 install %{SOURCE4} $RPM_BUILD_ROOT%{_sysconfdir}/%{name}/%{name}.conf
147 install %{SOURCE5} $RPM_BUILD_ROOT/etc/sysconfig/pdns
148
149 # useless - modules are dlopened by *.so
150 rm -f $RPM_BUILD_ROOT%{_libdir}/%{name}/*.la
151
152 %clean
153 rm -rf $RPM_BUILD_ROOT
154
155 %pre
156 %groupadd -g 32 djbdns
157 %useradd -u 30 -d /var/lib/pdns -s /bin/false -c "pdns User" -g djbdns pdns
158
159 %post
160 # dirty hack so the config file is processed correctly, and server does not respawn
161 sed -i -e 's/^ *//' /etc/pdns/pdns.conf
162
163 /sbin/chkconfig --add pdns
164 %service pdns restart
165
166 %preun
167 if [ "$1" = "0" ]; then
168         %service pdns stop
169         /sbin/chkconfig --del pdns
170 fi
171
172 %postun
173 if [ "$1" = "0" ]; then
174         %userremove pdns
175         %groupremove djbdns
176 fi
177
178 %files
179 %defattr(644,root,root,755)
180 %doc ChangeLog HACKING INSTALL README TODO pdns.pdf pdns.txt
181 %attr(754,root,root) %{_initrddir}/%{name}
182 %dir %{_sysconfdir}/%{name}
183 %attr(600,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}/%{name}.conf
184 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/pdns
185 %attr(755,root,root) %{_sbindir}/*
186 %attr(755,root,root) %{_bindir}/*
187 %{_mandir}/man8/*
188
189 %files backend-gmysql
190 %defattr(644,root,root,755)
191 %attr(755,root,root) %{_libdir}/%{name}/*mysql*.so*
192
193 %files backend-gpgsql
194 %defattr(644,root,root,755)
195 %attr(755,root,root) %{_libdir}/%{name}/*pgsql*.so*
196
197 %files backend-pipe
198 %defattr(644,root,root,755)
199 %attr(755,root,root) %{_libdir}/%{name}/*pipe*.so*
200
201 %files backend-ldap
202 %defattr(644,root,root,755)
203 %attr(755,root,root) %{_libdir}/%{name}/*ldap*.so*
This page took 0.078395 seconds and 3 git commands to generate.