Closed richleigh closed 7 years ago
Indeed, it's on my todo list, thanks for reporting.
Bear compatibility should be fixed by 53ae9eeee5db59893788f395de0ebe79112fbfb4. Thanks for reporting the issue.
Is there way to generate same output scheme like in bear? For instance:
{
"arguments": [
"c++",
"-c",
"TestMain.hpp"
],
"directory": "/home/user/test",
"file": "TestMain.hpp"
}
Newer clang versions do not support scheme with "command" ;/
It's on the TODO list to print the database in various format. But it would be better to create a new issue to track this.
However, I don't think the reason for this is correct. The Clang parser should support both arguments and command:
- command: The compile command executed. ...
- arguments: The compile command executed as list of strings. Either arguments or command is required.
Okej I will create new issue. When I tried to use rtags with older compile_command.json scheme that error is appeared: LIBCLANG TOOLING ERROR: json-compilation-database: Expected array.
When using a tool such as bear (https://github.com/rizsotto/Bear) to build the compilation database for a Makefile based project, the generated compilation database uses the 'arguments' key instead of the 'command' key.
To reproduce:
Result:
Things that use libclang, such as YCM seem fine with both cmake and bear derived compilation databases, so it would be great if compdb supported both.
This was using compdb 0.1.1