]> git.ipfire.org Git - thirdparty/asterisk.git/commit
res_resolver_unbound: Allow compilation with libunbound version < 1.5 55/3455/1
authorGeorge Joseph <gjoseph@digium.com>
Wed, 10 Aug 2016 16:47:32 +0000 (10:47 -0600)
committerGeorge Joseph <gjoseph@digium.com>
Wed, 10 Aug 2016 17:09:51 +0000 (12:09 -0500)
commit8d42ff784d0da04fda44ef8395f35671bd5ec0b3
treefb15386a17e6249c876bb8695011dd030cc7efec
parentd78fe8fed0d0a76e11b2884a65b66e82b28a6019
res_resolver_unbound:  Allow compilation with libunbound version < 1.5

libunbound at version 1.4.20 (which CentOS still uses) declared all
of their string function parameters as as 'char *'.  1.4.21 changed
them all to 'const char *'.  Thankfully 1.4.21 also introduced the
UNBOUND_VERSION_MAJOR define so configure now checks for that and
sets HAVE_UNBOUND_CONST_PARAMS.  res_resolver_unbound then checks
that and casts away the 'const' if it's not set.

Tested compile and testsuite on CentOS6 (1.4.20), Ubuntu14 (1.4.22) and
Fedora24 (1.5.4).  There are a few failing tests to be addressed though.

ASTERISK-26283 #close

Change-Id: Ib708b19b706c5d0ba7b7d5473e6df339d9ae4148
configure
configure.ac
include/asterisk/autoconfig.h.in
res/res_resolver_unbound.c