summaryrefslogtreecommitdiffstats
path: root/wscript
diff options
context:
space:
mode:
Diffstat (limited to 'wscript')
-rw-r--r--wscript8
1 files changed, 8 insertions, 0 deletions
diff --git a/wscript b/wscript
index cb12a3e37d..8f3961cf97 100644
--- a/wscript
+++ b/wscript
@@ -84,6 +84,11 @@ build_options = [
'name': '--test',
'desc': 'test suite (using cmocka)',
'func': check_pkg_config('cmocka >= 0.4.1'),
+ }, {
+ 'name': '--clang-database',
+ 'desc': 'generate a clang compilation database',
+ 'func': check_true,
+ 'default': 'disable',
}
]
@@ -891,6 +896,9 @@ def configure(ctx):
if not ctx.dependency_satisfied('build-date'):
ctx.env.CFLAGS += ['-DNO_BUILD_TIMESTAMPS']
+ if ctx.dependency_satisfied('clang-database'):
+ ctx.load('clang_compilation_database')
+
ctx.store_dependencies_lists()
def build(ctx):