1--- buildtools/wafsamba/samba_autoconf.py.orig 2019-08-20 15:35:08 UTC 2+++ buildtools/wafsamba/samba_autoconf.py 3@@ -573,7 +573,7 @@ def library_flags(self, libs): 4 5 6 @conf 7-def CHECK_LIB(conf, libs, mandatory=False, empty_decl=True, set_target=True, shlib=False): 8+def CHECK_LIB(conf, libs, mandatory=False, empty_decl=True, set_target=True, shlib=False, msg=None): 9 '''check if a set of libraries exist as system libraries 10 11 returns the sublist of libs that do exist as a syslib or [] 12@@ -593,11 +593,14 @@ int foo() 13 ret.append(lib) 14 continue 15 16+ if msg is None: 17+ msg = 'Checking for library %s' % lib 18+ 19 (ccflags, ldflags, cpppath) = library_flags(conf, lib) 20 if shlib: 21- res = conf.check(features='c cshlib', fragment=fragment, lib=lib, uselib_store=lib, cflags=ccflags, ldflags=ldflags, uselib=lib.upper(), mandatory=False) 22+ res = conf.check(features='c cshlib', fragment=fragment, lib=lib, uselib_store=lib, cflags=ccflags, ldflags=ldflags, uselib=lib.upper(), mandatory=False, msg=msg) 23 else: 24- res = conf.check(lib=lib, uselib_store=lib, cflags=ccflags, ldflags=ldflags, uselib=lib.upper(), mandatory=False) 25+ res = conf.check(lib=lib, uselib_store=lib, cflags=ccflags, ldflags=ldflags, uselib=lib.upper(), mandatory=False, msg=msg) 26 27 if not res: 28 if mandatory: 29@@ -949,5 +952,5 @@ def SAMBA_CHECK_UNDEFINED_SYMBOL_FLAGS(c 30 conf.env.undefined_ldflags = conf.ADD_LDFLAGS('-Wl,-no-undefined', testflags=True) 31 32 if (conf.env.undefined_ignore_ldflags == [] and 33- conf.CHECK_LDFLAGS(['-undefined', 'dynamic_lookup'])): 34+ conf.CHECK_LDFLAGS(['-undefined', 'dynamic_lookup'] + conf.env.WERROR_CFLAGS)): 35 conf.env.undefined_ignore_ldflags = ['-undefined', 'dynamic_lookup'] 36