MCPcopy Create free account
hub / github.com/Kitware/CMake / BuildDatabasePath

Method BuildDatabasePath

Source/cmGeneratorTarget.cxx:6406–6429  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

6404}
6405
6406std::string cmGeneratorTarget::BuildDatabasePath(
6407 std::string const& lang, std::string const& config) const
6408{
6409 // Check to see if the target wants it.
6410 if (!this->GetPropertyAsBool("EXPORT_BUILD_DATABASE")) {
6411 return {};
6412 }
6413 if (!cmExperimental::HasSupportEnabled(
6414 *this->Makefile, cmExperimental::Feature::ExportBuildDatabase)) {
6415 return {};
6416 }
6417 // Check to see if the generator supports it.
6418 if (!this->GetGlobalGenerator()->SupportsBuildDatabase()) {
6419 return {};
6420 }
6421
6422 if (this->GetGlobalGenerator()->IsMultiConfig()) {
6423 return cmStrCat(this->GetSupportDirectory(), '/', config, '/', lang,
6424 "_build_database.json");
6425 }
6426
6427 return cmStrCat(this->GetSupportDirectory(), '/', lang,
6428 "_build_database.json");
6429}
6430
6431void cmGeneratorTarget::BuildFileSetInfoCache(std::string const& config) const
6432{

Callers 3

cmGeneratorTargetMethod · 0.95

Calls 6

GetPropertyAsBoolMethod · 0.95
GetGlobalGeneratorMethod · 0.95
GetSupportDirectoryMethod · 0.95
cmStrCatFunction · 0.70
SupportsBuildDatabaseMethod · 0.45
IsMultiConfigMethod · 0.45

Tested by

no test coverage detected