tests/llvm: Test both cmake and llvm-config methods
@@ -31,18 +31,21 @@ if not dep_tinfo.found()
dep_tinfo = cpp.find_library('tinfo', required: false)
endif
+foreach method : ['config-tool', 'cmake']
foreach static : [true, false]
+ message('Trying method @0@ for @1@ link'.format(method, static ? 'static' : 'dynamic'))
llvm_dep = dependency(
'llvm',
modules : ['bitwriter', 'asmprinter', 'executionengine', 'target',
'mcjit', 'nativecodegen', 'amdgpu'],
required : false,
static : static,
+ method : method,
)
if llvm_dep.found()
name = static ? 'static' : 'dynamic'
executable(
- 'sum-@0@'.format(name),
+ 'sum-@0@-@1@'.format(name, method),
'sum.c',
dependencies : [
llvm_dep, dep_tinfo,
@@ -53,3 +56,4 @@ foreach static : [true, false]
)
endif
endforeach
+endforeach
