From: Peter van Dijk Date: Mon, 18 Mar 2013 11:11:02 +0000 (+0000) Subject: allow in-tree building of native recursor. Patch by Christian Hofstaedtler. Closes... X-Git-Tag: rec-3.5-rc3~12 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=96ff30fab02257d94c452bfde7faf911858eb6a1;p=pdns allow in-tree building of native recursor. Patch by Christian Hofstaedtler. Closes #716 git-svn-id: svn://svn.powerdns.com/pdns/trunk/pdns@3123 d19b8d6e-7fed-0310-83ef-9ca221ded41b --- diff --git a/pdns/Makefile-recursor b/pdns/Makefile-recursor index 6d87cdd40..11437cf3b 100644 --- a/pdns/Makefile-recursor +++ b/pdns/Makefile-recursor @@ -3,7 +3,7 @@ SBINDIR=/usr/sbin/ BINDIR=/usr/bin/ CONFIGDIR="/etc/powerdns/" OPTFLAGS?=-O3 -CXXFLAGS:= $(CXXFLAGS) -Iext/rapidjson/include -Wall $(OPTFLAGS) $(PROFILEFLAGS) $(ARCHFLAGS) -pthread +CXXFLAGS:= $(CXXFLAGS) -I$(PWD) -Iext/rapidjson/include -Wall $(OPTFLAGS) $(PROFILEFLAGS) $(ARCHFLAGS) -pthread CFLAGS:=$(CFLAGS) -Wall $(OPTFLAGS) $(PROFILEFLAGS) $(ARCHFLAGS) -pthread LDFLAGS:=$(LDFLAGS) $(ARCHFLAGS) -pthread @@ -18,7 +18,7 @@ PDNS_RECURSOR_OBJECTS=syncres.o misc.o unix_utility.o qtype.o logger.o \ arguments.o lwres.o pdns_recursor.o recursor_cache.o dnsparser.o \ dnswriter.o dnsrecords.o rcpgenerator.o base64.o zoneparser-tng.o \ rec_channel.o rec_channel_rec.o selectmplexer.o sillyrecords.o \ -dns_random.o aescrypt.o aeskey.o aes_modes.o aestab.o dnslabeltext.o \ +aes/dns_random.o aes/aescrypt.o aes/aeskey.o aes/aes_modes.o aes/aestab.o dnslabeltext.o \ lua-pdns.o lua-recursor.o randomhelper.o recpacketcache.o dns.o \ reczones.o base32.o nsecrecords.o json.o json_ws.o @@ -29,7 +29,7 @@ REC_CONTROL_OBJECTS=rec_channel.o rec_control.o arguments.o misc.o \ all: message pdns_recursor rec_control # OS specific instructions --include sysdeps/$(shell uname).inc +-include sysdeps-recursor/$(shell uname).inc ifeq ($(LUA), 1) LUALIBS=$(LUA_LIBS_CONFIG) @@ -88,9 +88,12 @@ clean: binclean binclean: -rm -f *.o pdns_recursor rec_control optional/*.o - + +dnslabeltext.cc: dnslabeltext.rl + ragel dnslabeltext.rl -o dnslabeltext.cc + dep: - $(CXX) $(CXXFLAGS) -MM -MG *.cc *.c *.hh > $@ + $(CXX) $(CXXFLAGS) -MM -MG *.cc *.hh aes/*.c aes/*.h aes/*.cc > $@ -include dep diff --git a/pdns/dist-recursor b/pdns/dist-recursor index 4cc52996e..b731cb0df 100755 --- a/pdns/dist-recursor +++ b/pdns/dist-recursor @@ -2,8 +2,6 @@ set -e -ragel dnslabeltext.rl -o dnslabeltext.cc - VERSION=3.5-rc2 INCLUDES="iputils.hh arguments.hh base64.hh zoneparser-tng.hh \ @@ -22,7 +20,7 @@ selectmplexer.cc epollmplexer.cc kqueuemplexer.cc portsmplexer.cc pdns_hw.cc \ win32_mtasker.cc win32_rec_channel.cc win32_logger.cc ntservice.cc \ recursorservice.cc sillyrecords.cc lua-pdns.cc lua-recursor.cc randomhelper.cc \ devpollmplexer.cc recpacketcache.cc dns.cc reczones.cc base32.cc nsecrecords.cc \ -dnslabeltext.cc json.cc json_ws.cc json_ws.hh" +json.cc json_ws.cc json_ws.hh" cd docs make pdns_recursor.1 rec_control.1 @@ -31,6 +29,8 @@ cd .. DIRNAME=pdns-recursor-$VERSION rm -rf $DIRNAME mkdir $DIRNAME +cp dnslabeltext.rl $DIRNAME/ +ragel dnslabeltext.rl -o $DIRNAME/dnslabeltext.cc cp $INCLUDES $CFILES $DIRNAME cp Makefile-recursor $DIRNAME/Makefile cp Makefile-recursor.win32 $DIRNAME/Makefile.win32 @@ -42,7 +42,8 @@ cp -a ext/rapidjson/include/rapidjson/*.h $DIRNAME/ext/rapidjson/include/rapidjs cp -a ext/rapidjson/include/rapidjson/internal/*.h $DIRNAME/ext/rapidjson/include/rapidjson/internal mkdir $DIRNAME/rrd cp tools/rrd/{create,update,makegraphs,index.html} $DIRNAME/rrd -cp aes/*.{c,cc,h} $DIRNAME +mkdir $DIRNAME/aes +cp aes/*.{c,cc,h} $DIRNAME/aes cp pdns-recursor.init.d $DIRNAME cp docs/pdns_recursor.1 docs/rec_control.1 $DIRNAME cp configure-recursor $DIRNAME/configure @@ -50,9 +51,9 @@ cp powerdns-example-script.lua $DIRNAME mkdir -p $DIRNAME/contrib cp ../contrib/systemd-pdns-recursor.service $DIRNAME/contrib -mkdir -p $DIRNAME/sysdeps +mkdir -p $DIRNAME/sysdeps-recursor rm -f sysdeps-recursor/*~ -cp sysdeps-recursor/* $DIRNAME/sysdeps +cp sysdeps-recursor/* $DIRNAME/sysdeps-recursor cp "PowerDNS Recursor.vcproj" $DIRNAME/ tar cf $DIRNAME.tar $DIRNAME bzip2 -f $DIRNAME.tar # .. solaris