From b8e1cd53ce8117a7a77bf6bb6456d41db1e74d47 Mon Sep 17 00:00:00 2001 From: Remi Thebault Date: Sun, 9 Jan 2022 15:49:52 +0100 Subject: [PATCH] Prepare waf update to 2.0.23 and enable 'clang_compilation_database' This enables the generation of build/compile_commands.json which is a compilation database recognized by some IDE/editors to provide compiler quality linting. To name a few: - Visual Studio Code - VIM (with ALE plugin) --- doc/updating_waf.txt | 6 +++--- wscript | 1 + 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/doc/updating_waf.txt b/doc/updating_waf.txt index d6767851fb..0bc03cf14b 100644 --- a/doc/updating_waf.txt +++ b/doc/updating_waf.txt @@ -11,10 +11,10 @@ ARDOURSRC=`pwd` cd /tmp -curl https://waf.io/waf-2.0.19.tar.bz2 | tar xj -cd waf-2.0.19 +curl https://waf.io/waf-2.0.23.tar.bz2 | tar xj +cd waf-2.0.23 patch -p1 < $ARDOURSRC/tools/patches/waf-str.patch -./waf-light -v --make-waf --tools=misc,doxygen,$ARDOURSRC/tools/autowaf.py,$ARDOURSRC/tools/misc.py --prelude='' +./waf-light -v --make-waf --tools=misc,doxygen,clang_compilation_database,$ARDOURSRC/tools/autowaf.py,$ARDOURSRC/tools/misc.py --prelude='' cp ./waf $ARDOURSRC/waf diff --git a/wscript b/wscript index 7a546e885a..b2bab28016 100644 --- a/wscript +++ b/wscript @@ -933,6 +933,7 @@ def sub_config_and_use(conf, name, has_objects = True): def configure(conf): conf.load('compiler_c') conf.load('compiler_cxx') + conf.load('clang_compilation_database') if Options.options.dist_target == 'mingw': conf.load('winres')