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

Method GetGUID

Source/cmGlobalVisualStudioGenerator.cxx:871–892  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

869}
870
871std::string cmGlobalVisualStudioGenerator::GetGUID(
872 std::string const& name) const
873{
874 std::string const& guidStoreName = cmStrCat(name, "_GUID_CMAKE");
875 if (cmValue storedGUID =
876 this->CMakeInstance->GetCacheDefinition(guidStoreName)) {
877 return *storedGUID;
878 }
879 // Compute a GUID that is deterministic but unique to the build tree.
880 std::string input =
881 cmStrCat(this->CMakeInstance->GetState()->GetBinaryDirectory(), '|', name);
882
883 cmUuid uuidGenerator;
884
885 std::vector<unsigned char> uuidNamespace;
886 uuidGenerator.StringToBinary("ee30c4be-5192-4fb0-b335-722a2dffe760",
887 uuidNamespace);
888
889 std::string guid = uuidGenerator.FromMd5(uuidNamespace, input);
890
891 return cmSystemTools::UpperCase(guid);
892}
893
894cm::VS::Solution::Folder* cmGlobalVisualStudioGenerator::CreateSolutionFolder(
895 cm::VS::Solution& solution, cm::string_view rawName) const

Callers 8

CreateSolutionFolderMethod · 0.95
CreateSolutionMethod · 0.95
WriteProjectStartMethod · 0.45
WriteGroupsMethod · 0.45

Calls 5

GetCacheDefinitionMethod · 0.80
StringToBinaryMethod · 0.80
FromMd5Method · 0.80
cmStrCatFunction · 0.70
GetStateMethod · 0.45

Tested by 1