]> git.pld-linux.org Git - packages/pdnsd.git/blobdiff - pdnsd.spec
- cleaning
[packages/pdnsd.git] / pdnsd.spec
index 3a6bd8fd3a101c97b9d69caa5f6e122beb09e87a..3094e57058f5fd9a90af7e0bf1fea30073170ce3 100644 (file)
@@ -1,52 +1,86 @@
-Summary: A caching dns proxy for small networks or dialin accounts
-Name: pdnsd
-Version: 1.0.3
-Release: 1
-Copyright: GPL
-Group: Daemons
-Source: pdnsd-1.0.3.tar.bz2
-vendor: Thomas Moestl
-distribution: RedHat 6.2 Linux
-packager: Daniel Smolik <smolik@corpus.cz>
-URL: http://home.t-online.de/home/Moestl/
-BuildRoot: /tmp/psnd-root
+Summary:       A caching dns proxy for small networks or dialin accounts
+Summary(pl):   DNS proxy serwer dla ma³ej sieci lub jednostki z po³±czeniem dialup
+Name:          pdnsd
+Version:       1.1.7a
+Release:       5
+License:       GPL
+Group:         Networking/Daemons
+Source0:       http://home.t-online.de/home/Moestl/%{name}-%{version}.tar.bz2
+Source1:       %{name}.init
+Patch0:                %{name}-threads_signals.patch
+URL:           http://home.t-online.de/home/Moestl/
+BuildRequires: autoconf
+BuildRequires: automake
+BuildRequires: flex
+PreReq:                /sbin/chkconfig
+PreReq:                rc-scripts
+Provides:      caching-nameserver
+BuildRoot:     %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
+Obsoletes:     bind
+Obsoletes:     maradns
+Obsoletes:     maradns-zoneserver
+
 %description
-pdnsd is a proxy DNS daemon with permanent (disk-)cache and the ability
-to serve local records. It is designed to detect network outages or hangups
-and to prevent DNS-dependent applications like Netscape Navigator from hanging.
+pdnsd is a proxy DNS daemon with permanent (disk-)cache and the
+ability to serve local records. It is designed to detect network
+outages or hangups and to prevent DNS-dependent applications like
+Netscape Navigator from hanging.
+
+%description -l pl
+pdnsd jest serwerem proxy dla us³ugi DNS, zapisujacym bufor ze
+zgromadzonymi informacjami na dysku. Bêdzie on szczególnie u¿yteczny
+dla jednostki pracujacej w trybie off-line (np. poprzez po³±czenie
+dialup).
+
 %prep
-%setup
+%setup -q
+%patch0 -p0
+
 %build
-make
+rm -f missing
+%{__aclocal}
+%{__autoconf}
+%{__autoheader}
+%{__automake}
+%configure \
+       --enable-ipv6
+%{__make}
 
 %install
-install -d -m 755  $RPM_BUILD_ROOT/etc
-install -d -m 755  $RPM_BUILD_ROOT/usr/sbin
-install  -o root -g root -m600 $RPM_BUILD_DIR/pdnsd-%{version}/doc/pdnsd.conf $RPM_BUILD_ROOT/etc/pdnsd.conf
-install  -o root -g root -m755 $RPM_BUILD_DIR/pdnsd-%{version}/pdnsd $RPM_BUILD_ROOT/usr/sbin/pdnsd
-install -d -o root -g root -m600   $RPM_BUILD_ROOT/var/cache/pdnsd
-
-mkdir -p $RPM_BUILD_ROOT/etc/rc.d/init.d
-install -m755 $RPM_BUILD_DIR/pdnsd-%{version}/rc/Redhat/pdnsd $RPM_BUILD_ROOT/etc/rc.d/init.d/pdnsd
-
-%clean                                                                          
-rm -rf $RPM_BUILD_ROOT                                                          
-                                                                                
-%post                                                                           
-/sbin/chkconfig --add pdnsd
-                                                                                
-%preun                                                                          
-if [ $1 = 0 ]; then                                                             
-   /sbin/chkconfig --del pdnsd
-fi                      
+rm -rf $RPM_BUILD_ROOT
+install -d $RPM_BUILD_ROOT/etc/rc.d/init.d
 
+%{__make} install DESTDIR=$RPM_BUILD_ROOT
 
+install %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/pdnsd
+mv -f $RPM_BUILD_ROOT%{_sysconfdir}/pdnsd.conf{.sample,}
 
-%files
-%doc AUTHORS COPYING ChangeLog  INSTALL NEWS README TODO doc/html/index.html doc/html/dl.html doc/html/doc.html doc/html/faq.html
-%doc doc/txt/intro.txt doc/txt/manual.txt doc/txt/faq.txt
-%config /etc/pdnsd.conf
-%dir /var/cache/pdnsd
+%clean
+rm -rf $RPM_BUILD_ROOT
+
+%post
+/sbin/chkconfig --add pdnsd
+if [ -f %{_localstatedir}/lock/subsys/pdnsd ]; then
+       /etc/rc.d/init.d/pdnsd restart >&2
+else
+       echo "Run \"/etc/rc.d/init.d/pdnsd start\" to start pdnsd." >&2
+fi
 
-/usr/sbin/pdnsd
-/etc/rc.d/init.d/pdnsd
+%preun
+if [ "$1" = "0" ]; then
+       if [ -f %{_localstatedir}/lock/subsys/pdnsd ]; then
+               /etc/rc.d/init.d/pdnsd stop
+       fi
+       /sbin/chkconfig --del pdnsd
+fi
+
+%files
+%defattr(644,root,root,755)
+%doc AUTHORS ChangeLog NEWS README TODO doc/txt/*.txt doc/html/*.html
+%attr(754,root,root) /etc/rc.d/init.d/pdnsd
+%attr(755,root,root) %{_sbindir}/pdnsd
+%attr(755,root,root) %{_sbindir}/pdnsd-ctl
+%attr(775,nobody,nobody) %dir %{_var}/cache/pdnsd
+%attr(664,nobody,nobody) %config(noreplace) %verify(not md5 size mtime) %{_var}/cache/pdnsd/pdnsd.cache
+%config(noreplace) %verify(not md5 size mtime) %{_sysconfdir}/pdnsd.conf
+%{_mandir}/man8/*
This page took 0.214107 seconds and 4 git commands to generate.