diff options
author | David Robillard <d@drobilla.net> | 2019-04-15 11:30:56 +0200 |
---|---|---|
committer | David Robillard <d@drobilla.net> | 2019-04-15 11:30:56 +0200 |
commit | 121d786100429762f2b70c3ba2e6472ce84a4b2d (patch) | |
tree | ff818699863feba31c78ccd51ecaf9c9ba6b42be /extras | |
parent | 82f156c7961ddba2de8b5380cc646eaa808b6b77 (diff) | |
download | lv2-121d786100429762f2b70c3ba2e6472ce84a4b2d.tar.xz |
Squashed 'waflib/' changes from 27a69a7..b074a1e
b074a1e Support building against local header-only libraries
git-subtree-dir: waflib
git-subtree-split: b074a1ef75005785ef7fadbaaaec7574ca4149ed
Diffstat (limited to 'extras')
-rw-r--r-- | extras/autowaf.py | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/extras/autowaf.py b/extras/autowaf.py index 5feef03..8c6e258 100644 --- a/extras/autowaf.py +++ b/extras/autowaf.py @@ -174,7 +174,8 @@ def define(conf, var_name, value): def check_pkg(conf, name, **args): "Check for a package iff it hasn't been checked for yet" - if args['uselib_store'].lower() in conf.env['AUTOWAF_LOCAL_LIBS']: + if (args['uselib_store'].lower() in conf.env['AUTOWAF_LOCAL_LIBS'] or + args['uselib_store'].lower() in conf.env['AUTOWAF_LOCAL_HEADERS']): return class CheckType: @@ -483,7 +484,7 @@ def version_lib(self): if [x for x in applicable if x in self.features]: self.target = self.target + 'D' -def set_lib_env(conf, name, version): +def set_lib_env(conf, name, version, has_objects=True): "Set up environment for local library as if found via pkg-config." NAME = name.upper() major_ver = version.split('.')[0] @@ -495,7 +496,8 @@ def set_lib_env(conf, name, version): conf.env[pkg_var_name] = lib_name conf.env['INCLUDES_' + NAME] = ['${INCLUDEDIR}/%s-%s' % (name, major_ver)] conf.env['LIBPATH_' + NAME] = lib_path - conf.env['LIB_' + NAME] = [lib_name] + if has_objects: + conf.env['LIB_' + NAME] = [lib_name] conf.run_env.append_unique(lib_path_name, lib_path) conf.define(NAME + '_VERSION', version) |