1 Summary: PowerDNS is a Versatile Database Driven Nameserver
2 Summary(pl): PowerDNS to wielofunkcyjny serwer nazw korzystaj¹cy z relacyjnych baz danych
7 Group: Networking/Daemons
8 Source0: http://downloads.powerdns.com/releases/%{name}-%{version}.tar.gz
9 # Source0-md5: 3465694b9638c29f19a25dd5b0a77559
10 Source1: http://downloads.powerdns.com/documentation/%{name}.pdf
11 # Source1-md5: d7adf31d793735251c416d6ef5075cfa
12 Source2: http://downloads.powerdns.com/documentation/%{name}.txt
15 Source5: %{name}.sysconfig
16 Patch0: %{name}-unistd.patch
17 Patch1: ldap_utils.diff
18 URL: http://www.powerdns.com/
21 BuildRequires: libpq++-static
22 BuildRequires: libstdc++-devel
23 BuildRequires: mysql-devel
24 BuildRequires: zlib-devel
25 BuildRequires: openldap-devel
27 Requires(pre): /bin/id
28 Requires(pre): /usr/sbin/useradd
29 Requires(pre): /usr/sbin/groupadd
30 Requires(post,preun): /sbin/chkconfig
31 Requires(postun): /usr/sbin/userdel
32 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
37 PowerDNS is a versatile nameserver which supports a large number of
38 different backends ranging from simple zonefiles to relational
39 databases and load balancing/failover algorithms.
42 PowerDNS to wielofunkcyjny serwer nazw posiadaj¹cy du¿¹ liczbê wtyczek
43 od prostych stref (a'la BIND) pocz¹wszy, a na relacyjnych bazach
44 danych skoñczywszy oraz zawieraj¹cy algorytmy zrównowa¿enia obci¹¿enia
45 i prze³¹czania w wypadku awarii.
48 Summary: PowerDNS support for custom pipe backend
49 Summary(pl): Wsparcie PowerDNS dla w³asnego mechanizmu przechowywania stref
50 Group: Development/Libraries
52 %description backend-pipe
53 This package allows creation of own backend using simple STDIN/STDOUT
54 API. Example backend script in perl is provided in package
57 %description backend-pipe -l pl
58 Ten pakiet pozwala na utworzenie w³asnego mechanizmu przechowywania
59 stref za pomoc¹ prostego interfejsu STDIN/STDOUT. Przyk³adowy skrypt w
60 perlu zosta³ do³¹czony do dokumentacji pakietu.
62 %package backend-gpgsql
63 Summary: PowerDNS support for PostgreSQL
64 Summary(pl): Wsparcie PowerDNS dla baz PostgresQL
65 Group: Development/Libraries
68 %description backend-gpgsql
69 This package allows zone storage in PostgreSQL relational db tables.
71 %description backend-gpgsql -l pl
72 Ten pakiet pozwala na przechowywanie danych o strefach w tabelach
73 relacyjnej bazy danych PostgreSQL.
75 %package backend-gmysql
76 Summary: PowerDNS support for MySQL
77 Summary(pl): Wsparcie PowerDNS dla baz MySQL
78 Group: Development/Libraries
81 %description backend-gmysql
82 This package allows zone storage in MySQL relational db tables.
84 %description backend-gmysql -l pl
85 Ten pakiet pozwala na przechowywanie danych o strefach w tabelach
86 relacyjnej bazy danych MySQL.
89 Summary: PowerDNS support for LDAP
90 Summary(pl): Wsparcie PowerDNS dla baz LDAP
91 Group: Development/Libraries
94 %description backend-ldap
95 This package allows zone storage in LDAP directory.
97 %description backend-ldap -l pl
98 Ten pakiet pozwala na przechowywanie danych o strefach w katalogu LDAP.
108 CPPFLAGS="-DHAVE_NAMESPACE_STD -DHAVE_CXX_STRING_HEADER -DDLLIMPORT=\"\""
110 --libdir=%{_libdir}/%{name} \
111 --sysconfdir=%{_sysconfdir}/%{name} \
112 --with-socketdir=/var/run \
113 --with-dynmodules="gmysql gpgsql pipe ldap" \
117 --with-pgsql-lib=/usr/lib \
118 --with-pgsql-includes=%{_includedir} \
125 rm -rf $RPM_BUILD_ROOT
126 install -d $RPM_BUILD_ROOT{%{_initrddir},%{_sysconfdir}/%{name},/etc/sysconfig}
129 DESTDIR=$RPM_BUILD_ROOT
131 install %{SOURCE3} $RPM_BUILD_ROOT%{_initrddir}/%{name}
132 install %{SOURCE4} $RPM_BUILD_ROOT%{_sysconfdir}/%{name}/%{name}.conf
133 install %{SOURCE5} $RPM_BUILD_ROOT/etc/sysconfig/pdns
135 # useless - modules are dlopened by *.so
136 rm -f $RPM_BUILD_ROOT%{_libdir}/%{name}/*.la
139 rm -rf $RPM_BUILD_ROOT
142 if [ -n "`getgid djbdns`" ]; then
143 if [ "`getgid djbdns`" != "32" ]; then
144 echo "Error: group djbdns doesn't have gid=32. Correct this before installing pdns." 1>&2
148 /usr/sbin/groupadd -g 32 -r -f djbdns
150 if [ -n "`id -u pdns 2>/dev/null`" ]; then
151 if [ "`id -u pdns`" != "30" ]; then
152 echo "Error: user pdns doesn't have uid=30. Correct this before installing pdns." 1>&2
156 /usr/sbin/useradd -u 30 -r -d /var/lib/pdns -s /bin/false -c "pdns User" -g djbdns pdns 1>&2
160 # dirty hack so the config file is processed correctly, and server does not respawn
161 TMP=`mktemp /tmp/pdns.install-tmp.XXXXXX`
162 sed 's/^ *//g' /etc/pdns/pdns.conf > $TMP
163 cp /etc/pdns/pdns.conf /etc/pdns/pdns.conf.rpmsave
164 mv $TMP /etc/pdns/pdns.conf
166 /sbin/chkconfig --add pdns
167 if [ -f /var/lock/subsys/pdns ]; then
168 /etc/rc.d/init.d/pdns restart >&2
170 echo "Run \"/etc/rc.d/init.d/pdns start\" to start pdns." >&2
174 if [ "$1" = "0" ]; then
175 if [ -f /var/lock/subsys/pdns ]; then
176 /etc/rc.d/init.d/pdns stop
178 /sbin/chkconfig --del pdns
182 if [ "$1" = "0" ]; then
183 /usr/sbin/userdel pdns
187 %defattr(644,root,root,755)
188 %doc ChangeLog HACKING INSTALL README TODO WARNING pdns.pdf pdns.txt
189 %config(noreplace) %attr(0600,root,root) %{_sysconfdir}/%{name}/%{name}.conf
190 %config(noreplace) %attr(0754,root,root) %{_initrddir}/%{name}
191 %attr(640,root,root) %config(noreplace) %verify(not size mtime md5) /etc/sysconfig/pdns
192 %dir %{_sysconfdir}/%{name}
193 %attr(755,root,root) %{_sbindir}/*
194 %attr(755,root,root) %{_bindir}/*
197 %files backend-gmysql
198 %defattr(644,root,root,755)
199 %attr(755,root,root) %{_libdir}/%{name}/*mysql*.so*
201 %files backend-gpgsql
202 %defattr(644,root,root,755)
203 %attr(755,root,root) %{_libdir}/%{name}/*pgsql*.so*
206 %defattr(644,root,root,755)
207 %attr(755,root,root) %{_libdir}/%{name}/*pipe*.so*
210 %defattr(644,root,root,755)
211 %attr(755,root,root) %{_libdir}/%{name}/*ldap*.so*