diff options
| author | Alexander Karatarakis <alkarata@microsoft.com> | 2016-11-08 19:33:50 -0800 |
|---|---|---|
| committer | Alexander Karatarakis <alkarata@microsoft.com> | 2016-11-08 19:33:59 -0800 |
| commit | a9d732f206936c82d07f8d4b5ef0aaa461bb2073 (patch) | |
| tree | ea10c8341209cc0cceb4e8162eb094940c0fcf74 /toolsrc/src/post_build_lint.cpp | |
| parent | 097626c317bdf3efa16073c19aac4d0c226bb1ee (diff) | |
| download | vcpkg-a9d732f206936c82d07f8d4b5ef0aaa461bb2073.tar.gz vcpkg-a9d732f206936c82d07f8d4b5ef0aaa461bb2073.zip | |
Reorder post-build checks related to lib files
Diffstat (limited to 'toolsrc/src/post_build_lint.cpp')
| -rw-r--r-- | toolsrc/src/post_build_lint.cpp | 21 |
1 files changed, 11 insertions, 10 deletions
diff --git a/toolsrc/src/post_build_lint.cpp b/toolsrc/src/post_build_lint.cpp index 4b784952a..634e85c05 100644 --- a/toolsrc/src/post_build_lint.cpp +++ b/toolsrc/src/post_build_lint.cpp @@ -510,6 +510,17 @@ namespace vcpkg error_count += check_for_copyright_file(spec, paths); error_count += check_for_exes(spec, paths); + const std::vector<fs::path> debug_libs = recursive_find_files_with_extension_in_dir(paths.packages / spec.dir() / "debug" / "lib", ".lib"); + const std::vector<fs::path> release_libs = recursive_find_files_with_extension_in_dir(paths.packages / spec.dir() / "lib", ".lib"); + + error_count += check_matching_debug_and_release_binaries(debug_libs, release_libs); + + std::vector<fs::path> libs; + libs.insert(libs.cend(), debug_libs.cbegin(), debug_libs.cend()); + libs.insert(libs.cend(), release_libs.cbegin(), release_libs.cend()); + + error_count += check_lib_architecture(spec.target_triplet().architecture(), libs); + switch (linkage_type_value_of(build_info.library_linkage)) { case LinkageType::DYNAMIC: @@ -550,16 +561,6 @@ namespace vcpkg error_count += check_no_subdirectories(paths.packages / spec.dir() / "lib"); error_count += check_no_subdirectories(paths.packages / spec.dir() / "debug" / "lib"); #endif - const std::vector<fs::path> debug_libs = recursive_find_files_with_extension_in_dir(paths.packages / spec.dir() / "debug" / "lib", ".lib"); - const std::vector<fs::path> release_libs = recursive_find_files_with_extension_in_dir(paths.packages / spec.dir() / "lib", ".lib"); - - error_count += check_matching_debug_and_release_binaries(debug_libs, release_libs); - - std::vector<fs::path> libs; - libs.insert(libs.cend(), debug_libs.cbegin(), debug_libs.cend()); - libs.insert(libs.cend(), release_libs.cbegin(), release_libs.cend()); - - error_count += check_lib_architecture(spec.target_triplet().architecture(), libs); error_count += check_no_empty_folders(paths.packages / spec.dir()); |
