From 90de53f970a87fd4b6ade5e5f280cc58587b58ef Mon Sep 17 00:00:00 2001 From: Andreas Schneider Date: Tue, 13 Jan 2015 15:13:40 +0100 Subject: rwrap: Fix ns_name_compress detection. On some platforms it is a macro and not a function. So we need to check if the macro exists. Signed-off-by: Andreas Schneider Reviewed-by: Alexander Bokovoy --- lib/resolv_wrapper/wscript | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lib/resolv_wrapper/wscript b/lib/resolv_wrapper/wscript index 797e90ad1d..7d9e21ab17 100644 --- a/lib/resolv_wrapper/wscript +++ b/lib/resolv_wrapper/wscript @@ -74,7 +74,9 @@ def configure(conf): conf.CHECK_FUNCS_IN('res_search __res_search', 'resolv', checklibc=True) conf.CHECK_FUNCS_IN('res_nsearch __res_nsearch', 'resolv', checklibc=True) - conf.CHECK_FUNCS_IN('ns_name_compress', 'resolv', checklibc=True) + conf.CHECK_DECLS('ns_name_compress', headers='sys/types.h arpa/nameser.h') + if (conf.CONFIG_SET("HAVE_DECL_NS_NAME_COMPRESS")): + conf.DEFINE("HAVE_NS_NAME_COMPRESS", 1) # Create full path to resolv_wrapper srcdir = os.path.realpath(conf.srcdir) -- cgit