install -s rec_control $(DESTDIR)/$(BINDIR)
-mkdirhier $(DESTDIR)/$(CONFIGDIR)
./pdns_recursor --config > $(DESTDIR)/$(CONFIGDIR)/recursor.conf
-
+ -mkdirhier $(DESTDIR)/usr/share/man/man1
+ cp pdns_recursor.1 rec_control.1 $(DESTDIR)/usr/share/man/man1
+ $(OS_SPECIFIC_INSTALL)
clean:
-rm -f *.o *~ pdns_recursor rec_control optional/*.o
base64.cc zoneparser-tng.cc rec_channel.cc rec_channel_rec.cc rec_control.cc \
selectmplexer.cc epollmplexer.cc kqueuemplexer.cc portsmplexer.cc"
+cd docs
+make pdns_recursor.1 rec_control.1
+cd ..
+
DIRNAME=pdns-recursor-$VERSION
rm -rf $DIRNAME
mkdir $DIRNAME
mkdir $DIRNAME/rrd
cp tools/rrd/{create,update,makegraphs,index.html} $DIRNAME/rrd
cp ext/nedmalloc/malloc.c $DIRNAME
+cp pdns-recursor.init.d $DIRNAME
+cp docs/pdns_recursor.1 docs/rec_control.1 $DIRNAME
mkdir -p $DIRNAME/sysdeps
cp sysdeps-recursor/* $DIRNAME/sysdeps
./expand < $< > $@
clean:
- rm -rf *.dvi *.pdf *.tex *.toc *.aux *.txt *.ps *.bak *.tmp *~ *.log html.tar.gz html pdns
+ rm -rf *.xml *.dvi *.pdf *.tex *.toc *.aux *.ps *.bak *.tmp *~ *.log html.tar.gz html pdns
html/index.html: pdns-expanded.sgml
db2html -V %use-id-as-filename% -o html $<
docbook2pdf $<
mv pdns-expanded.pdf pdns.pdf
+%.xml: %.txt
+ asciidoc -b docbook -d manpage $<
+
+%: %.xml
+ xmlto man $<
+
+%.html: %.txt
+ asciidoc -b xhtml11 -d manpage $<
+
publish:
rsync --copy-links --delete -avrze ssh ./html pdns.txt pdns.pdf \
exit.powerdns.com:/opt/websites/downloads.powerdns.com/www/documentation/
--- /dev/null
+#!/bin/sh
+# chkconfig: - 80 75
+# description: pdns_recursor is a versatile high performance recursing nameserver
+
+prefix=/usr/
+BINARYPATH=/usr/bin/
+SBINARYPATH=/usr/sbin/
+SOCKETPATH=/var/run
+
+pdns_server=$SBINARYPATH/pdns_recursor
+
+[ -f "$pdns_server" ] || exit 0
+
+doPC()
+{
+ ret=$($BINARYPATH/rec_control $EXTRAOPTS $1 $2 2> /dev/null)
+}
+
+
+doPC ping
+NOTRUNNING=$?
+
+case "$1" in
+ status)
+ if test "$NOTRUNNING" = "0"
+ then
+ echo "running"
+ else
+ echo "not running"
+ fi
+ ;;
+
+ stop)
+ echo -n "Stopping PowerDNS recursing nameserver: "
+ if test "$NOTRUNNING" = "0"
+ then
+ doPC quit
+ echo $ret
+ else
+ echo "not running"
+ fi
+ ;;
+
+
+ force-stop)
+ echo -n "Stopping PowerDNS recursing nameserver: "
+ killall -v -9 pdns_server
+ echo "killed"
+ ;;
+
+ start)
+ echo -n "Starting PowerDNS recursing nameserver: "
+ if test "$NOTRUNNING" = "0"
+ then
+ echo "already running"
+ else
+ $pdns_server --daemon
+ if test "$?" = "0"
+ then
+ echo "started"
+ fi
+ fi
+ ;;
+
+ force-reload | restart)
+ echo -n "Restarting PowerDNS authoritative nameserver: "
+ echo -n stopping and waiting..
+ doPC quit
+ sleep 3
+ echo done
+ $0 start
+ ;;
+
+ monitor)
+ if test "$NOTRUNNING" = "0"
+ then
+ echo "already running"
+ else
+ $pdns_server --daemon=no --quiet=no --control-console --loglevel=9
+ fi
+ ;;
+
+ *)
+ echo pdns [start\|stop\|force-reload\|restart\|status\|monitor]
+
+ ;;
+esac
+
+
Buildroot: /tmp/pdns/
Name: pdns-recursor
-Version: 3.0_pre3
+Version: 3.0_pre4
Release: 1
Summary: extremely powerful and versatile recursing nameserver
Copyright: see /usr/doc/pdns/copyright
%defattr(-,root,root)
"/usr/sbin/pdns_recursor"
"/usr/bin/rec_control"
+"/etc/init.d/pdns-recursor"
+"/usr/share/man/man1/pdns_recursor.1.gz"
+"/usr/share/man/man1/rec_control.1.gz"
%dir "/etc/powerdns/"
%config(noreplace) "/etc/powerdns/recursor.conf"
rccS.send(command);
string receive=rccS.recv();
cout<<receive;
+ exit(0);
}
catch(AhuException& ae)
{
cerr<<"Fatal: "<<ae.reason<<"\n";
+ exit(1);
}
OPTIONALS:=optional/epollmplexer.o
+OS_SPECIFIC_INSTALL=mkdirhier $(DESTDIR)/etc/init.d ; cp pdns-recursor.init.d $(DESTDIR)/etc/init.d/pdns-recursor
optional/epollmplexer.o: epollmplexer.cc
$(CXX) $(CXXFLAGS) -c $< -o $@ ; true