multiplier
multiplier copied to clipboard
Add a best-effort indexing mode
The idea here is that when indexing GCC builds, we should have a way to try to succeed even when we can't. For example, we should try to interpret the commands "as if" they were Clang commands.
This could take the form of passing in --resource_dir, etc. to the indexer. Or maybe in the form of applying QA overrides, the way clang does it with ApplyQAOverride in its driver. For example, the following QA override would "do the trick":
CCC_OVERRIDE_OPTIONS="s/-resource-dir/-isystem/ ^/usr/lib/llvm-15/lib/clang/15.0.7 ^-resource-dir"
But this environment variable doesn't affect PASTA.
I have a new hack that kind of works:
LIBRARY_PATH=<resource-dir>
CPATH="-resource-dir <resource-dir>:<include-dir1>:...:<include-dirN>"
CPPFLAGS="-nostdinc -nobuiltininc"