diff --git a/scripts/cmake/vcpkg_from_github.cmake b/scripts/cmake/vcpkg_from_github.cmake index 1c1b71679f95b8..f77d1b2e20f50a 100644 --- a/scripts/cmake/vcpkg_from_github.cmake +++ b/scripts/cmake/vcpkg_from_github.cmake @@ -129,6 +129,11 @@ function(vcpkg_from_github) set(VCPKG_USE_HEAD_VERSION OFF) endif() + if(VCPKG_MANIFEST_MODE AND NOT VCPKG_USE_HEAD_VERSION AND NOT DEFINED _vdud_REF) + message(STATUS "Package specifies HEAD_REF but not REF, and --head was not passed to vcpkg. Manifest mode is active, so HEAD_REF is being used.") + set(VCPKG_USE_HEAD_VERSION ON) + endif() + # Handle --no-head scenarios if(NOT VCPKG_USE_HEAD_VERSION) if(NOT _vdud_REF)