diff options
| author | Robert Schumacher <roschuma@microsoft.com> | 2019-04-09 16:04:37 -0700 |
|---|---|---|
| committer | Robert Schumacher <roschuma@microsoft.com> | 2019-04-09 16:04:41 -0700 |
| commit | 705f9f4919f04f1e59238873ba7a036be64dbde3 (patch) | |
| tree | a4fe2b68c70cc5ce88a897c99d810aded9bf6616 | |
| parent | 1db72cd0eaef8c97f2d5f99ea337878f9cc67eec (diff) | |
| download | vcpkg-705f9f4919f04f1e59238873ba7a036be64dbde3.tar.gz vcpkg-705f9f4919f04f1e59238873ba7a036be64dbde3.zip | |
Complete revert of accidental merge b1b7ec5c0be3a3b0
| -rw-r--r-- | toolsrc/src/vcpkg/build.cpp | 26 | ||||
| -rw-r--r-- | toolsrc/src/vcpkg/install.cpp | 13 |
2 files changed, 14 insertions, 25 deletions
diff --git a/toolsrc/src/vcpkg/build.cpp b/toolsrc/src/vcpkg/build.cpp index b8720bcc4..43f1a6288 100644 --- a/toolsrc/src/vcpkg/build.cpp +++ b/toolsrc/src/vcpkg/build.cpp @@ -479,13 +479,13 @@ namespace vcpkg::Build const int max_port_file_count = 100;
// the order of recursive_directory_iterator is undefined so save the names to sort
- std::vector<fs::path> hashed_files;
+ std::vector<fs::path> port_files;
for (auto &port_file : fs::stdfs::recursive_directory_iterator(config.port_dir))
{
if (fs::is_regular_file(status(port_file)))
{
- hashed_files.push_back(port_file);
- if (hashed_files.size() > max_port_file_count)
+ port_files.push_back(port_file);
+ if (port_files.size() > max_port_file_count)
{
abi_tag_entries.emplace_back(AbiEntry{ "no_hash_max_portfile", "" });
break;
@@ -493,20 +493,12 @@ namespace vcpkg::Build }
}
- if (hashed_files.size() <= max_port_file_count)
+ if (port_files.size() <= max_port_file_count)
{
- for (auto &script_file : fs::stdfs::recursive_directory_iterator(paths.scripts))
- {
- if (fs::is_regular_file(status(script_file)))
- {
- hashed_files.push_back(script_file);
- }
- }
-
- std::sort(hashed_files.begin(), hashed_files.end());
+ std::sort(port_files.begin(), port_files.end());
int counter = 0;
- for (auto & hashed_file : hashed_files)
+ for (auto & port_file : port_files)
{
// When vcpkg takes a dependency on C++17 it can use fs::relative,
// which will give a stable ordering and better names in the key entry.
@@ -516,13 +508,13 @@ namespace vcpkg::Build {
System::print2("[DEBUG] mapping ", key, " from ", port_file.u8string(), "\n");
}
- abi_tag_entries.emplace_back(AbiEntry{ key, vcpkg::Hash::get_file_hash(fs, hashed_file, "SHA1") });
+ abi_tag_entries.emplace_back(AbiEntry{ key, vcpkg::Hash::get_file_hash(fs, port_file, "SHA1") });
}
}
abi_tag_entries.emplace_back(AbiEntry{
- "vcpkg",
- vcpkg::Hash::get_file_hash(fs, paths.scripts / "buildsystems" / "vcpkg.cmake", "SHA1")});
+ "vcpkg_fixup_cmake_targets",
+ vcpkg::Hash::get_file_hash(fs, paths.scripts / "cmake" / "vcpkg_fixup_cmake_targets.cmake", "SHA1")});
abi_tag_entries.emplace_back(AbiEntry{"triplet", pre_build_info.triplet_abi_tag});
diff --git a/toolsrc/src/vcpkg/install.cpp b/toolsrc/src/vcpkg/install.cpp index af59b8de6..6d4eabc89 100644 --- a/toolsrc/src/vcpkg/install.cpp +++ b/toolsrc/src/vcpkg/install.cpp @@ -209,14 +209,11 @@ namespace vcpkg::Install if (!intersection.empty()) { const fs::path triplet_install_path = paths.installed / triplet.canonical_name(); - - System::println(System::Color::error, - "The following files are already installed in %s and are in conflict with %s", - triplet_install_path.generic_string(), - bcf.core_paragraph.spec); - System::print("\n "); - System::println(Strings::join("\n ", intersection)); - System::println(); + System::printf(System::Color::error, + "The following files are already installed in %s and are in conflict with %s\n", + triplet_install_path.generic_string(), + bcf.core_paragraph.spec); + System::print2("\n ", Strings::join("\n ", intersection), "\n\n"); return InstallResult::FILE_CONFLICTS; } |
