Summary: NSD is a complete implementation of an authoritative DNS name server Name: nsd Version: 2.3.3 Release: 6%{?dist} License: BSD-like Url: http://open.nlnetlabs.nl/nsd/ Source: http://open.nlnetlabs.nl/downloads/nsd/%{name}-%{version}.tar.gz Source1: nsd.init Patch0: nsd-2.3.3-checking.patch Group: System Environment/Daemons BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: flex, openssl-devel %description NSD is a complete implementation of an authoritative DNS name server. For further information about what NSD is and what NSD is not please consult the REQUIREMENTS document which is a part of this distribution (thanks to Olaf). %prep %setup -q %patch0 -p1 -b .checking.patch %configure --enable-bind8-stats --enable-plugins \ --enable-mmap --with-pidfile=%{_localstatedir}/run/%{name}/%{name}.pid --with-ssl \ --with-user=nsd %build %{__make} %{?_smp_mflags} %install # Not using their 'make install' since it uses install-sh which does not # get the correct install path within the RPM_BUILD_ROOT #%{__make} install rm -rf %{buildroot} install -d 0755 %{buildroot}/%{_sysconfdir}/nsd install -d 0755 %{buildroot}/%{_sbindir} install -d 0755 %{buildroot}/%{_mandir}/man8 install -d 0755 %{buildroot}/%{_initrddir} install -d 0700 %{buildroot}/%{_localstatedir}/run/%{name} install -m 0644 nsdc.conf.sample %{buildroot}/%{_sysconfdir}/nsd/nsdc.conf install -m 0644 nsd.zones.sample %{buildroot}/%{_sysconfdir}/nsd/nsd.zones install -m 0755 %{SOURCE1} %{buildroot}/%{_initrddir}/nsd install -m 0755 nsd zonec nsd-notify nsd-xfer %{buildroot}/%{_sbindir} install -m 0755 nsdc.sh %{buildroot}/%{_sbindir}/nsdc install -m 0644 *.8 %{buildroot}/%{_mandir}/man8 %clean rm -rf ${RPM_BUILD_ROOT} %files %defattr(-,root,root) %doc README LICENSE NSD-DATABASE DIFFERENCES dbaccess.c TODO RELNOTES REQUIREMENTS %dir %{_sysconfdir}/nsd/ %attr(0644,root,root) %config(noreplace) %{_sysconfdir}/nsd/nsdc.conf %attr(0644,root,root) %config(noreplace) %{_sysconfdir}/nsd/nsd.zones %attr(0755,root,root) %{_initrddir}/%{name} %attr(0700,%{name},%{name}) %dir %{_localstatedir}/run/%{name} %{_sbindir}/* %{_mandir}/*/* %pre if getent passwd nsd >/dev/null 2>&1 ; then : ; else /usr/sbin/useradd -d /etc/nsd -r -s /sbin/nologin nsd >/dev/null 2>&1 || exit 1 ; fi if [ $1 = 2 -a -f /%{_localstatedir}/run/%{name}/%{name}.pid ]; then /sbin/service %{name} stop fi # "Everyone is doing it, so why can't we?" exit 0 %post # do not activate daemon upon request. Fedora Extra policy %preun if [ -f /%{_localstatedir}/run/%{name}/%{name}.pid ] then /sbin/service %{name} stop > /dev/null 2>&1 fi if [ $1 -eq 0 ] then /sbin/chkconfig --del %{name} > /dev/null 2>&1 fi # "Everyone is doing it, so why can't we?" exit 0 %postun if [ "$1" -ge "1" ]; then /sbin/service %{name} condrestart 2>&1 >/dev/null fi %changelog * Thu Dec 15 2005 Paul Wouters - 2.3.3-6 - Moved pid file to /var/run/nsd/nsd.pid. - Use %{_localstatedir} instead of "/var" * Tue Dec 13 2005 Paul Wouters - 2.3.3-5 - Added BuildRequires for openssl-devel, removed Requires for openssl. * Mon Dec 12 2005 Paul Wouters - 2.3.3-4 - upgraded to nsd-2.3.3 * Wed Dec 7 2005 Tom "spot" Callaway - 2.3.2-2 - minor cleanups * Mon Dec 5 2005 Paul Wouters - 2.3.2-1 - Upgraded to 2.3.2. Changed post scripts to comply to Fedora Extras policies (eg do not start daemon on fresh install) * Tue Oct 4 2005 Paul Wouters - 2.3.1-1 - Initial version