1
0
mirror of https://github.com/samba-team/samba.git synced 2025-03-27 22:50:26 +03:00

Transition to waf 1.8: wrapped conf.check_cfg

Reviewed-By: Jelmer Vernooij <jelmer@samba.org>

(forward ported to current master by abartlet)

Reviewed-by: Andrew Bartlett <abartlet@samba.org>
This commit is contained in:
Thomas Nagy 2015-03-07 15:31:19 +01:00 committed by Andrew Bartlett
parent 5771276be9
commit 3c0e3af395
7 changed files with 15 additions and 11 deletions

View File

@ -846,3 +846,7 @@ def SAMBA_CHECK_UNDEFINED_SYMBOL_FLAGS(conf):
if not sys.platform.startswith("openbsd") and conf.env.undefined_ignore_ldflags == []:
if conf.CHECK_LDFLAGS(['-undefined', 'dynamic_lookup']):
conf.env.undefined_ignore_ldflags = ['-undefined', 'dynamic_lookup']
@conf
def CHECK_CFG(self, *k, **kw):
return self.check_cfg(*k, **kw)

View File

@ -383,7 +383,7 @@ def configure(conf):
conf.CHECK_INLINE()
# check for pkgconfig
conf.check_cfg(atleast_pkgconfig_version='0.0.0')
conf.CHECK_CFG(atleast_pkgconfig_version='0.0.0')
conf.DEFINE('_GNU_SOURCE', 1, add_to_cflags=True)
conf.DEFINE('_XOPEN_SOURCE_EXTENDED', 1, add_to_cflags=True)

View File

@ -654,7 +654,7 @@ msg.msg_accrightslen = sizeof(fd);
# we would normally use --libs here, but cups-config incorrectly adds
# gssapi_krb5 and other libraries to its --libs output. That breaks the use
# of an in-tree heimdal kerberos
conf.check_cfg(path=conf.env.CUPS_CONFIG, args="--cflags --ldflags",
conf.CHECK_CFG(path=conf.env.CUPS_CONFIG, args="--cflags --ldflags",
package="", uselib_store="CUPS")
conf.CHECK_HEADERS('cups/cups.h cups/language.h', lib='cups')
conf.CHECK_FUNCS_IN('httpConnect httpConnectEncrypt', 'cups')
@ -1523,7 +1523,7 @@ main() {
conf.DEFINE('HAVE_CEPH', '1')
if Options.options.with_glusterfs:
conf.check_cfg(package='glusterfs-api', args='"glusterfs-api >= 4" --cflags --libs',
conf.CHECK_CFG(package='glusterfs-api', args='"glusterfs-api >= 4" --cflags --libs',
msg='Checking for glusterfs-api >= 4', uselib_store="GFAPI")
conf.CHECK_HEADERS('api/glfs.h', lib='gfapi')
conf.CHECK_LIB('gfapi', shlib=True)
@ -1540,7 +1540,7 @@ main() {
if Options.options.enable_vxfs:
conf.DEFINE('HAVE_VXFS', '1')
if conf.check_cfg(package='dbus-1', args='--cflags --libs',
if conf.CHECK_CFG(package='dbus-1', args='--cflags --libs',
msg='Checking for dbus', uselib_store="DBUS-1"):
if (conf.CHECK_HEADERS('dbus/dbus.h', lib='dbus-1')
and conf.CHECK_LIB('dbus-1', shlib=True)):

View File

@ -7,7 +7,7 @@ if not conf.env.NCURSES_CONFIG:
conf.find_program('ncurses6-config', var='NCURSES_CONFIG')
if conf.env.NCURSES_CONFIG:
conf.check_cfg(path=conf.env.NCURSES_CONFIG, args="--cflags --libs",
conf.CHECK_CFG(path=conf.env.NCURSES_CONFIG, args="--cflags --libs",
package="", uselib_store="NCURSES")
conf.CHECK_HEADERS('ncurses.h menu.h panel.h form.h', lib='ncurses')

View File

@ -21,12 +21,12 @@ def configure(conf):
conf.fatal("--disable-gnutls given: Building the AD DC requires GnuTLS (eg libgnutls-dev, gnutls-devel) for ldaps:// support and for the BackupKey protocol")
return
if conf.check_cfg(package='gnutls',
if conf.CHECK_CFG(package='gnutls',
args='"gnutls >= 3.0.0" --cflags --libs',
msg='Checking for gnutls >= 3.0.0s', mandatory=False):
conf.DEFINE('HAVE_GNUTLS3', 1)
else:
conf.check_cfg(package='gnutls',
conf.CHECK_CFG(package='gnutls',
args='"gnutls >= 1.4.0 gnutls != 2.2.4 gnutls != 2.8.0 gnutls != 2.8.1" --cflags --libs',
msg='Checking for gnutls >= 1.4.0 and broken versions', mandatory=False)

View File

@ -216,7 +216,7 @@ def configure(conf):
conf.env['ENABLE_RELRO'] = True
if Options.options.enable_systemd != False:
conf.check_cfg(package='libsystemd-daemon', args='--cflags --libs',
conf.CHECK_CFG(package='libsystemd-daemon', args='--cflags --libs',
msg='Checking for libsystemd-daemon', uselib_store="SYSTEMD-DAEMON")
conf.CHECK_HEADERS('systemd/sd-daemon.h', lib='systemd-daemon')
conf.CHECK_LIB('systemd-daemon', shlib=True)

View File

@ -21,11 +21,11 @@ else:
conf.find_program('krb5-config', path_list=path_krb5_config, var='KRB5_CONFIG')
if conf.env.KRB5_CONFIG:
conf.check_cfg(path=conf.env.KRB5_CONFIG, args="--cflags --libs",
conf.CHECK_CFG(path=conf.env.KRB5_CONFIG, args="--cflags --libs",
package="", uselib_store="KRB5")
krb5_define_syslib(conf, "krb5", conf.env['LIB_KRB5'])
conf.check_cfg(path=conf.env.KRB5_CONFIG, args="--cflags --libs",
conf.CHECK_CFG(path=conf.env.KRB5_CONFIG, args="--cflags --libs",
package="gssapi", uselib_store="GSSAPI")
krb5_define_syslib(conf, "gssapi", conf.env['LIB_GSSAPI'])
if 'k5crypto' in conf.env['LIB_GSSAPI']:
@ -54,7 +54,7 @@ if conf.env.KRB5_CONFIG:
else:
Logs.info('%s is detected, MIT krb5 build can proceed' % (kversion))
conf.check_cfg(args="--cflags --libs", package="com_err", uselib_store="com_err")
conf.CHECK_CFG(args="--cflags --libs", package="com_err", uselib_store="com_err")
conf.CHECK_FUNCS_IN('_et_list', 'com_err')
conf.CHECK_HEADERS('com_err.h', lib='com_err')