5 if [ "$0" != "./build-scripts/dist-recursor" ]; then
6 echo "Please run me from the root checkout dir"
10 if [ -z "$VERSION" ]; then
11 VERSION
=$
(.
/build-aux
/gen-version
)
12 if [ -z "$VERSION" ]; then
21 ragel dnslabeltext.rl
-o dnslabeltext.cc
24 pandoc
-s -t man manpages
/pdns_recursor
.1.md
-o pdns_recursor
.1
25 pandoc
-s -t man manpages
/rec_control
.1.md
-o rec_control
.1
28 DIST_HOST
="$(id -u -n)@$(hostname -f 2>/dev/null || hostname 2>/dev/null || echo localhost)"
30 INCLUDES
="iputils.hh arguments.hh base64.hh zoneparser-tng.hh \
31 rcpgenerator.hh lock.hh dnswriter.hh dnsrecords.hh dnsparser.hh utility.hh \
32 recursor_cache.hh rec_channel.hh qtype.hh misc.hh dns.hh syncres.hh \
33 sstuff.hh mtasker.hh mtasker.cc lwres.hh logger.hh pdnsexception.hh \
34 mplexer.hh pubsuffix.hh mbedtlscompat.hh \
35 dns_random.hh lua-pdns.hh lua-recursor.hh namespaces.hh \
36 recpacketcache.hh base32.hh cachecleaner.hh json.hh version.hh \
37 ws-recursor.hh ws-api.hh secpoll-recursor.hh \
38 responsestats.hh webserver.hh dnsname.hh dnspacket.hh ednssubnet.hh \
39 filterpo.hh rpzloader.hh ixfr.hh gss_context.hh resolver.hh dnssecinfra.hh \
40 dnsseckeeper.hh statbag.hh ueberbackend.hh sha.hh dnsbackend.hh comment.hh \
43 CFILES
="syncres.cc iputils.cc misc.cc unix_utility.cc qtype.cc \
44 logger.cc arguments.cc lwres.cc pdns_recursor.cc lua-iputils.cc \
45 recursor_cache.cc dnsparser.cc dnswriter.cc dnsrecords.cc rcpgenerator.cc \
46 base64.cc zoneparser-tng.cc rec_channel.cc rec_channel_rec.cc rec_control.cc \
47 selectmplexer.cc epollmplexer.cc kqueuemplexer.cc portsmplexer.cc pdns_hw.cc \
48 sillyrecords.cc pubsuffix.cc lua-pdns.cc lua-recursor.cc randomhelper.cc \
49 devpollmplexer.cc recpacketcache.cc dns.cc reczones.cc base32.cc nsecrecords.cc \
50 dnslabeltext.cc json.cc ws-recursor.cc ws-api.cc version.cc dns_random.cc \
51 responsestats.cc webserver.cc rec-carbon.cc secpoll-recursor.cc dnsname.cc \
52 filterpo.cc rpzloader.cc ixfr.cc dnssecinfra.cc gss_context.cc resolver.cc \
57 DIRNAME
=pdns-recursor-
$VERSION
60 cp $INCLUDES $CFILES $DIRNAME
61 cp Makefile-recursor
$DIRNAME/Makefile.
in
62 cp README-recursor
$DIRNAME/README
63 cp ..
/COPYING ..
/NOTICE
$DIRNAME/
64 cp config-recursor.h
$DIRNAME/config.h
65 cat >>$DIRNAME/config.h
<<EOF
66 #define VERSION "$VERSION"
67 #define DIST_HOST "$DIST_HOST"
69 #define HAVE_MBEDTLS2 1
71 mkdir
-p $DIRNAME/ext
/rapidjson
/include
/rapidjson
/internal
72 cp -a ..
/ext
/rapidjson
/include
/rapidjson
/*.h
$DIRNAME/ext
/rapidjson
/include
/rapidjson
/
73 cp -a ..
/ext
/rapidjson
/include
/rapidjson
/internal
/*.h
$DIRNAME/ext
/rapidjson
/include
/rapidjson
/internal
74 mkdir
-p $DIRNAME/ext
/mbedtls
/include
/mbedtls
75 cp -a ..
/ext
/mbedtls
/include
/mbedtls
/{config.h
,check_config.h
,aes.h
,ripemd160.h
,sha1.h
,md.h
,md5.h
,sha256.h
,sha512.h
,md_internal.h
} ..
/ext
/mbedtls
/include
/mbedtls
/base64.h ..
/ext
/mbedtls
/include
/mbedtls
/platform.h ..
/ext
/mbedtls
/include
/mbedtls
/version.h
$DIRNAME/ext
/mbedtls
/include
/mbedtls
76 mkdir
-p $DIRNAME/ext
/mbedtls
/library
77 cp -a ..
/ext
/mbedtls
/library
/{aes.c
,base64.c
,md.c
,md_wrap.c
,md5.c
,sha1.c
,sha256.c
,sha512.c
,ripemd160.c
} $DIRNAME/ext
/mbedtls
/library
78 cp -a ..
/ext
/yahttp
/ $DIRNAME/ext
/yahttp
79 echo '#include "../../../config.h"' > $DIRNAME/ext
/yahttp
/yahttp
/yahttp-config.h
81 cp tools
/rrd
/{create
,update
,makegraphs
,index.html
} $DIRNAME/rrd
82 cp dnslabeltext.rl
$DIRNAME
83 cp pdns-recursor.init.d
$DIRNAME
84 cp ..
/docs
/pdns_recursor
.1 ..
/docs
/rec_control
.1 $DIRNAME
85 cp configure-recursor
$DIRNAME/configure
86 cp powerdns-example-script.lua
$DIRNAME
87 mkdir
-p $DIRNAME/contrib
88 cp ..
/contrib
/systemd-pdns-recursor.service
$DIRNAME/contrib
89 cp ..
/build-scripts
/build-recursor-semistatic
$DIRNAME/build-scripts
90 cp pdns-recursor.spec
$DIRNAME
92 mkdir
-p $DIRNAME/sysdeps
93 rm -f sysdeps-recursor
/*~
94 cp sysdeps-recursor
/* $DIRNAME/sysdeps
95 touch $DIRNAME/dnslabeltext.cc
# avoid spurious recompiles
96 tar cf
$DIRNAME.
tar $DIRNAME
97 bzip2 -f $DIRNAME.
tar # .. solaris