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

Method OutputLibraryDirectories

Source/cmLocalVisualStudio7Generator.cxx:1340–1377  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1338}
1339
1340void cmLocalVisualStudio7Generator::OutputLibraryDirectories(
1341 std::ostream& fout, std::vector<std::string> const& stdlink,
1342 std::vector<std::string> const& dirs)
1343{
1344 char const* comma = "";
1345
1346 for (std::string dir : dirs) {
1347 // Remove any trailing slash and skip empty paths.
1348 if (dir.back() == '/') {
1349 dir = dir.substr(0, dir.size() - 1);
1350 }
1351 if (dir.empty()) {
1352 continue;
1353 }
1354
1355 // Switch to a relative path specification if it is shorter.
1356 if (cmSystemTools::FileIsFullPath(dir)) {
1357 std::string rel = this->MaybeRelativeToCurBinDir(dir);
1358 if (rel.size() < dir.size()) {
1359 dir = rel;
1360 }
1361 }
1362
1363 // First search a configuration-specific subdirectory and then the
1364 // original directory.
1365 fout << comma
1366 << this->ConvertToXMLOutputPath(
1367 cmStrCat(dir, "/$(ConfigurationName)"))
1368 << ',' << this->ConvertToXMLOutputPath(dir);
1369 comma = ",";
1370 }
1371
1372 // No special processing on toolchain-defined standard link directory paths
1373 for (auto const& dir : stdlink) {
1374 fout << comma << this->ConvertToXMLOutputPath(dir);
1375 comma = ",";
1376 }
1377}
1378
1379void cmLocalVisualStudio7Generator::WriteVCProjFile(std::ostream& fout,
1380 std::string const& libName,

Callers 1

OutputBuildToolMethod · 0.95

Calls 7

cmStrCatFunction · 0.70
backMethod · 0.45
substrMethod · 0.45
sizeMethod · 0.45
emptyMethod · 0.45

Tested by

no test coverage detected