Add package_spec::display_name()
MODIFY
include/package_spec.h
include/package_spec.h
@@ -15,6 +15,8 @@ namespace vcpkg
const triplet& target_triplet() const;
+ std::string display_name() const;
+
std::string dir() const;
std::string toString() const;

MODIFY
src/BinaryParagraph.cpp
src/BinaryParagraph.cpp
@@ -71,7 +71,7 @@ namespace vcpkg
std::string BinaryParagraph::displayname() const
{
- return Strings::format("%s:%s", this->spec.name(), this->spec.target_triplet());
+ return this->spec.display_name();
}
std::string BinaryParagraph::dir() const

MODIFY
src/package_spec.cpp
src/package_spec.cpp
@@ -50,6 +50,11 @@ namespace vcpkg
return this->m_target_triplet;
}
+ std::string package_spec::display_name() const
+ {
+ return Strings::format("%s:%s", this->name(), this->target_triplet());
+ }
+
std::string package_spec::dir() const
{
return Strings::format("%s_%s", this->m_name, this->m_target_triplet);
@@ -57,7 +62,7 @@ namespace vcpkg
std::string package_spec::toString() const
{
- return Strings::format("%s:%s", this->name(), this->target_triplet());
+ return this->display_name();
}
std::string to_printf_arg(const package_spec& spec)

Add package_spec::display_name()