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-recursor4.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 \
41 validate.hh validate-recursor.hh sortlist.hh rec-lua-conf.hh sholder.hh"
43 CFILES
="syncres.cc iputils.cc misc.cc unix_utility.cc qtype.cc \
44 logger.cc arguments.cc lwres.cc pdns_recursor.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-recursor4.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 \
53 ednssubnet.cc validate.cc validate-recursor.cc mbedtlssigners.cc rec-lua-conf.cc \
56 curl https
://publicsuffix.org
/list
/public_suffix_list.dat
> effective_tld_names.dat
59 DIRNAME
=pdns-recursor-
$VERSION
62 cp $INCLUDES $CFILES $DIRNAME
63 cp Makefile-recursor
$DIRNAME/Makefile.
in
64 cp README-recursor
$DIRNAME/README
65 cp ..
/COPYING ..
/NOTICE
$DIRNAME/
66 cp config-recursor.h
$DIRNAME/config.h
67 cat >>$DIRNAME/config.h
<<EOF
68 #define VERSION "$VERSION"
69 #define DIST_HOST "$DIST_HOST"
71 #define HAVE_MBEDTLS2 1
73 mkdir
-p $DIRNAME/ext
/rapidjson
/include
/rapidjson
/internal
74 cp -a ..
/ext
/rapidjson
/include
/rapidjson
/*.h
$DIRNAME/ext
/rapidjson
/include
/rapidjson
/
75 cp -a ..
/ext
/rapidjson
/include
/rapidjson
/internal
/*.h
$DIRNAME/ext
/rapidjson
/include
/rapidjson
/internal
76 mkdir
-p $DIRNAME/ext
/mbedtls
/include
/mbedtls
77 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
78 cp -a ..
/ext
/mbedtls
/include
/mbedtls
/{entropy.h
,ctr_drbg.h
,rsa.h
,ecp.h
,bignum.h
,oid.h
,asn1.h
,pk.h
,ecdsa.h
,cipher.h
,x509.h
} $DIRNAME/ext
/mbedtls
/include
/mbedtls
79 cp -a ..
/ext
/mbedtls
/include
/mbedtls
/{bn_mul.h
,config.h
,entropy_poll.h
,timing.h
} $DIRNAME/ext
/mbedtls
/include
/mbedtls
81 mkdir
-p $DIRNAME/ext
/mbedtls
/library
82 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
83 cp -a ..
/ext
/mbedtls
/library
/{rsa.c
,bignum.c
,oid.c
,asn1parse.c
,ctr_drbg.c
,entropy.c
,entropy_poll.c
,timing.c
} $DIRNAME/ext
/mbedtls
/library
85 cp -a ..
/ext
/yahttp
/ $DIRNAME/ext
/yahttp
87 mkdir
-p $DIRNAME/ext
/luawrapper
/include
88 cp ..
/ext
/luawrapper
/include
/LuaContext.hpp
$DIRNAME/ext
/luawrapper
/include
89 echo '#include "../../../config.h"' > $DIRNAME/ext
/yahttp
/yahttp
/yahttp-config.h
91 cp tools
/rrd
/{create
,update
,makegraphs
,index.html
} $DIRNAME/rrd
92 cp dnslabeltext.rl
$DIRNAME
93 cp pdns-recursor.init.d
$DIRNAME
94 cp ..
/docs
/pdns_recursor
.1 ..
/docs
/rec_control
.1 $DIRNAME
95 cp configure-recursor
$DIRNAME/configure
96 cp powerdns-example-script.lua
$DIRNAME
97 mkdir
-p $DIRNAME/contrib
98 cp ..
/contrib
/systemd-pdns-recursor.service
$DIRNAME/contrib
99 cp ..
/build-scripts
/build-recursor-semistatic
$DIRNAME/build-scripts
100 cp pdns-recursor.spec
$DIRNAME
102 mkdir
-p $DIRNAME/sysdeps
103 rm -f sysdeps-recursor
/*~
104 cp sysdeps-recursor
/* $DIRNAME/sysdeps
105 touch $DIRNAME/dnslabeltext.cc
# avoid spurious recompiles
106 tar cf
$DIRNAME.
tar $DIRNAME
107 bzip2 -f $DIRNAME.
tar # .. solaris