Supported Plugins#

clang_compile_commands.h#

class ClangCompileCommands#

Public Functions

inline explicit ClangCompileCommands(std::vector<const BaseTarget*> &&targets)#
ClangCompileCommands(const ClangCompileCommands &compile_commands) = delete#
void AddTarget(const BaseTarget *target)#

Add non-null targets.

void Generate()#

Generate clang compile commands file in Project::GetBuildDir folder.

Example#

1using namespace buildcc;
2
3Target foolib;
4Target hello_world;
5
6// Foolib and Hello world targets are both added to a single "compile_commands.json" file
7plugin::ClangCompileCommands({&foolib, &hello_world}).Generate();