diff options
author | Boris Kolpackov <boris@codesynthesis.com> | 2024-10-29 08:33:03 +0200 |
---|---|---|
committer | Boris Kolpackov <boris@codesynthesis.com> | 2024-10-29 08:33:03 +0200 |
commit | f8ef04cb484821ed37dd2a7f139d0ac5cc65338c (patch) | |
tree | fa10effc825d5add86a5fe66096ffa4559dd93f2 /libbuild2 | |
parent | 6dc01f74431a40dac698417d2947f0d8ddbd8c8c (diff) |
Add note on relative paths in compiledb
Diffstat (limited to 'libbuild2')
-rw-r--r-- | libbuild2/cc/compiledb.hxx | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/libbuild2/cc/compiledb.hxx b/libbuild2/cc/compiledb.hxx index edfd1ee..8288cf5 100644 --- a/libbuild2/cc/compiledb.hxx +++ b/libbuild2/cc/compiledb.hxx @@ -54,8 +54,18 @@ namespace build2 // `/F?<path>`. Oh, well. Note also that either relo or relm (but not // both) could be empty if unused. // - // Note also that we assume the source file is always absolute and is - // the last argument. + // Note that we assume the source file is always absolute and is the + // last argument. + // + // Why do we want absolute paths? That's a good question. Our initial + // plan was to compare command lines in order to detect when we need to + // update the database. And if those changed with every change of CWD, + // that would be of little use. But then we realized we could do better + // by using depdb to detect changes. So now we actually don't have a + // need to get rid of the relative paths in the command line. But seeing + // that we already have it, let's keep it for now in case it makes a + // different to some broken/legacy consumers. Note also that C++ module + // name-to-BMI mapping is not untranslated (see append_module_options()). // static void execute (const scope& bs, |