* Test ci command on malformed port manifests
* Test ci command on individual malformed port manifest
* Pass overlay port errors to OverlayProviderImpl
* Move broken-manifest overlay ports into separate dir
"e2e-ports/overlays" is in common vcpkg test args. It must not contain
ports with broken manifests where the the tool is expected to report the
error.
The tests which need these broken ports already passed an explicit
"--overlay-ports" argument which duplicated the one in @commonArgs.
That is why this commit only changes the value of the explicit argument.
* Ensure that inactive feature can have broken dependencies
Also audited for:
* Consistently following the 'IDE error format' pointing to portfile.cmake.
* Consistently referring to the correct skip policy in the error message where applicable.
* Printing paths and other information relative to ${CURRENT_PACKAGES_DIR} or similar as appropriate.
* Debug before release.
* Don't duplicate messages when a problem happens for both debug and release.
Drive by bugfix:
if (!build_info.policies.is_enabled(BuildPolicy::ONLY_RELEASE_CRT))
{
error_count += check_crt_linkage_of_libs(
build_info, false, debug_libs, debug_lib_info.value_or_exit(VCPKG_LINE_INFO), msg_sink);
}
was wrong; ONLY_RELEASE_CRT should mean 'these should all be release', not 'we aren't even going to look at debug'.
It is fixed to:
error_count += check_crt_linkage_of_libs(build_info.crt_linkage,
build_info.policies.is_enabled(BuildPolicy::ONLY_RELEASE_CRT),
debug_libs,
debug_lib_info.value_or_exit(VCPKG_LINE_INFO),
msg_sink);
here.
Drive-by bugfix:
EMPTY_INCLUDE_FOLDER should not block CMAKE_HELPER_PORT from checking that the include folder is, in fact, empty.
Drive-by bugfix:
if (!violations.empty())
{
msg_sink.println_warning(msgPortBugRestrictedHeaderPaths);
print_paths(msg_sink, violations);
msg_sink.println(msgPortBugRestrictedHeaderPaths); // <-- duplicate!
return LintStatus::PROBLEM_DETECTED;
}
Drive-by bugfix:
There were duplicate checks for the lib/cmake and debug/lib/cmake directories which even printed the same message; these have been merged.
Drive-by bugfix:
The existing copyright check emitted nonsense output that included full absolute paths like:
warning: The software license must be available at ${CURRENT_PACKAGES_DIR}/share/cmdline/copyright. vcpkg_install_copyright(FILE_LIST "${SOURCE_PATH}/D:/b/cmdline//LICENSE")
since at least https://github.com/microsoft/vcpkg-tool/pull/1116/
That check has been basically rewritten to use vcpkg_install_copyright if there's only one src directory, and otherwise give up and print them all
Drive-by bugfix:
Several of the outdated CRTs didn't have the debug versions listed. Also, P was duplicated and there was no R for VC6.
* Fix wrong Header-only usage message
* Cherry pick tests from https://github.com/microsoft/vcpkg-tool/pull/1405
---------
Co-authored-by: Lily Wang <v-lilywang@microsoft.com>
Co-authored-by: Billy Robert O'Neal III <bion@microsoft.com>
Problems were:
- the only test in e2e_ports folder, everything else in e2e-ports
- tests modify files under $VCPKG_ROOT
- Divided in two files where one enough
- Tests fail if package is already in binary cache
While reviewing changes to https://github.com/microsoft/vcpkg-tool/pull/1339 , I observed that it was strange that the abi hash depends on whether download_only is selected. After discussion with @ras0219-msft , he agreed that the ABI hash shouldn't be affected by this setting.
However, given that in download mode, we intentionally build things which do not have all their dependencies present, it would not be safe to attempt to cache or otherwise install anything in that condition.
This change removes download_only from the ABI calculation, and changes installation to only attempt to install built bits whose dependencies are all satisfied.
Hopefully resolves test failures in https://github.com/microsoft/vcpkg-tool/pull/1129 -- asset caching is not turned on in the tool repo so testing things that need lots of external servers is problematic.
This was added back when the tool and registry were in the same repo in attempt to validate *registry* changes, not tool changes. As a result it doesn't really belong here.
The one thing that might also have been tested here is handling of old CONTROL files ports so I added an explicit test port for that.