aboutsummaryrefslogtreecommitdiffhomepage
path: root/waftools/checks
diff options
context:
space:
mode:
authorGravatar Stefano Pigozzi <stefano.pigozzi@gmail.com>2013-11-23 15:45:38 +0100
committerGravatar Stefano Pigozzi <stefano.pigozzi@gmail.com>2013-11-23 16:17:52 +0100
commitf315c9330235921862e4e234029e79eb77d3354d (patch)
tree5ad7f5d1caed6a07c335c7e04a8c57be5aa2feb0 /waftools/checks
parent26f8887422c5313114f298fb48a103c9bee36705 (diff)
build: fix lua check to actually test for libquvi
Diffstat (limited to 'waftools/checks')
-rw-r--r--waftools/checks/custom.py13
1 files changed, 8 insertions, 5 deletions
diff --git a/waftools/checks/custom.py b/waftools/checks/custom.py
index d2da024037..6d6268ead7 100644
--- a/waftools/checks/custom.py
+++ b/waftools/checks/custom.py
@@ -24,19 +24,22 @@ def check_iconv(ctx, dependency_identifier):
return check_libs(libs, checkfn)(ctx, dependency_identifier)
def check_lua(ctx, dependency_identifier):
- if 'libquvi4' in ctx.env.satisfied_deps:
+ if ctx.dependency_satisfied('libquvi4'):
+ quvi_lib_storage = [ 'libquvi4' ]
additional_lua_test_header = '#include <quvi/quvi.h>'
additional_lua_test_code = load_fragment('lua_libquvi4.c')
- elif 'libquvi9' in ctx.env.satisfied_deps:
+ elif ctx.dependency_satisfied('libquvi9'):
+ quvi_lib_storage = [ 'libquvi9' ]
additional_lua_test_header = '#include <quvi.h>'
additional_lua_test_code = load_fragment('lua_libquvi9.c')
else:
+ quvi_lib_storage = []
additional_lua_test_header = ''
additional_lua_test_code = ''
fragment = load_fragment('lua.c').format(
- additional_lua_test_header='',
- additional_lua_test_code='')
+ additional_lua_test_header=additional_lua_test_header,
+ additional_lua_test_code=additional_lua_test_code)
lua_versions = [
( '51', 'lua >= 5.1.0 lua < 5.2.0'),
@@ -54,7 +57,7 @@ def check_lua(ctx, dependency_identifier):
for lua_version, pkgconfig_query in lua_versions:
if compose_checks(
check_pkg_config(pkgconfig_query, uselib_store=lua_version),
- check_cc(fragment=fragment, use=lua_version))\
+ check_cc(fragment=fragment, use=[lua_version] + quvi_lib_storage))\
(ctx, dependency_identifier):
# XXX: this is a bit of a hack, ask waf developers if I can copy
# the uselib_store to 'lua'