summaryrefslogtreecommitdiffstats
path: root/buildtools
diff options
context:
space:
mode:
authorStefan Metzmacher <metze@samba.org>2014-03-14 09:55:45 +0100
committerAndrew Bartlett <abartlet@samba.org>2014-04-02 09:03:41 +0200
commitcec109ccf9ffe3079a9905bad9b2c52abf253a16 (patch)
tree42df32fbe8eb667aa5ae065463052713dd3f0f27 /buildtools
parent4dea4e310dfa0718fcd0d118fc97880f38714b36 (diff)
downloadsamba-cec109ccf9ffe3079a9905bad9b2c52abf253a16.tar.gz
samba-cec109ccf9ffe3079a9905bad9b2c52abf253a16.tar.xz
samba-cec109ccf9ffe3079a9905bad9b2c52abf253a16.zip
wafsamba: simplify CHECK_BUNDLED_SYSTEM_PKG() by just calling CHECK_BUNDLED_SYSTEM()
If checkfunctions is not specified they are the same. Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Diffstat (limited to 'buildtools')
-rw-r--r--buildtools/wafsamba/samba_bundled.py46
1 files changed, 5 insertions, 41 deletions
diff --git a/buildtools/wafsamba/samba_bundled.py b/buildtools/wafsamba/samba_bundled.py
index 65dd52d191e..1cab6344197 100644
--- a/buildtools/wafsamba/samba_bundled.py
+++ b/buildtools/wafsamba/samba_bundled.py
@@ -102,47 +102,11 @@ def CHECK_BUNDLED_SYSTEM_PKG(conf, libname, minversion='0.0.0',
This only tries using pkg-config
'''
- if conf.LIB_MUST_BE_BUNDLED(libname):
- return False
- found = 'FOUND_SYSTEMLIB_%s' % libname
- if found in conf.env:
- return conf.env[found]
-
- # see if the library should only use a system version if another dependent
- # system version is found. That prevents possible use of mixed library
- # versions
- if onlyif:
- missing = conf.CHECK_PREREQUISITES(onlyif)
- if missing:
- if not conf.LIB_MAY_BE_BUNDLED(libname):
- Logs.error('ERROR: Use of system library %s depends on missing system library/libraries %r' % (libname, missing))
- sys.exit(1)
- conf.env[found] = False
- return False
-
- minversion = minimum_library_version(conf, libname, minversion)
-
- msg = 'Checking for system %s' % libname
- if minversion != '0.0.0':
- msg += ' >= %s' % minversion
-
- if pkg is None:
- pkg = libname
-
- if conf.check_cfg(package=pkg,
- args='"%s >= %s" --cflags --libs' % (pkg, minversion),
- msg=msg, uselib_store=libname.upper()):
- conf.SET_TARGET_TYPE(libname, 'SYSLIB')
- conf.env[found] = True
- if implied_deps:
- conf.SET_SYSLIB_DEPS(libname, implied_deps)
- return True
- conf.env[found] = False
- if not conf.LIB_MAY_BE_BUNDLED(libname):
- Logs.error('ERROR: System library %s of version %s not found, and bundling disabled' % (libname, minversion))
- sys.exit(1)
- return False
-
+ return conf.CHECK_BUNDLED_SYSTEM(libname,
+ minversion=minversion,
+ onlyif=onlyif,
+ implied_deps=implied_deps,
+ pkg=pkg)
@runonce
@conf