mirror of
https://github.com/Kitware/CMake.git
synced 2026-04-26 16:18:43 -05:00
Merge topic 'Wcomma'
5ff7fb592e Fixed all but one clang -Wcomma warning
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2828
This commit is contained in:
@@ -191,12 +191,14 @@ cmGlobalGenerator* cmGlobalXCodeGenerator::Factory::CreateGlobalGenerator(
|
||||
std::string versionFile;
|
||||
{
|
||||
std::string out;
|
||||
std::string::size_type pos = 0;
|
||||
if (cmSystemTools::RunSingleCommand("xcode-select --print-path", &out,
|
||||
nullptr, nullptr, nullptr,
|
||||
cmSystemTools::OUTPUT_NONE) &&
|
||||
(pos = out.find(".app/"), pos != std::string::npos)) {
|
||||
versionFile = out.substr(0, pos + 5) + "Contents/version.plist";
|
||||
bool commandResult = cmSystemTools::RunSingleCommand(
|
||||
"xcode-select --print-path", &out, nullptr, nullptr, nullptr,
|
||||
cmSystemTools::OUTPUT_NONE);
|
||||
if (commandResult) {
|
||||
std::string::size_type pos = out.find(".app/");
|
||||
if (pos != std::string::npos) {
|
||||
versionFile = out.substr(0, pos + 5) + "Contents/version.plist";
|
||||
}
|
||||
}
|
||||
}
|
||||
if (!versionFile.empty() && cmSystemTools::FileExists(versionFile.c_str())) {
|
||||
|
||||
Reference in New Issue
Block a user