mirror of
https://github.com/microsoft/vcpkg.git
synced 2024-11-28 23:59:37 +08:00
[vcpkg] Enable packages to provide cmake wrapper scripts.
This commit is contained in:
parent
7aaa59fc9d
commit
4338ae25a1
@ -184,7 +184,11 @@ function(add_library name)
|
||||
endfunction()
|
||||
|
||||
macro(find_package name)
|
||||
if("${name}" STREQUAL "Boost")
|
||||
string(TOLOWER "${name}" _vcpkg_lowercase_name)
|
||||
if(EXISTS "${_VCPKG_INSTALLED_DIR}/${VCPKG_TARGET_TRIPLET}/share/${_vcpkg_lowercase_name}/vcpkg-cmake-wrapper.cmake")
|
||||
set(ARGS "${ARGV}")
|
||||
include(${_VCPKG_INSTALLED_DIR}/${VCPKG_TARGET_TRIPLET}/share/${_vcpkg_lowercase_name}/vcpkg-cmake-wrapper.cmake)
|
||||
elseif("${name}" STREQUAL "Boost")
|
||||
set(_Boost_USE_STATIC_LIBS ${Boost_USE_STATIC_LIBS})
|
||||
set(_Boost_USE_MULTITHREADED ${Boost_USE_MULTITHREADED})
|
||||
set(_Boost_USE_STATIC_RUNTIME ${Boost_USE_STATIC_RUNTIME})
|
||||
|
Loading…
Reference in New Issue
Block a user