[vcpkg] Sort abi tags to ensure stability

This commit is contained in:
Robert Schumacher 2018-03-22 10:01:12 -07:00
parent c806505933
commit 1f62b32641
2 changed files with 7 additions and 0 deletions

View File

@ -209,6 +209,11 @@ namespace vcpkg::Build
{
std::string key;
std::string value;
bool operator<(const AbiEntry& other) const
{
return key < other.key || (key == other.key && value < other.value);
}
};
struct AbiTagAndFile

View File

@ -449,6 +449,8 @@ namespace vcpkg::Build
if (config.build_package_options.use_head_version == UseHeadVersion::YES)
abi_tag_entries.emplace_back(AbiEntry{"head", ""});
Util::sort(abi_tag_entries);
std::string full_abi_info =
Strings::join("", abi_tag_entries, [](const AbiEntry& p) { return p.key + " " + p.value + "\n"; });