Merge pull request #10935 from drTr0jan/msgpack

GetMsgpack: add 4+ versions of upstream
This commit is contained in:
Jingyu Zhou 2024-01-17 13:02:00 -08:00 committed by GitHub
commit e2fc5f3f1c
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 5 additions and 1 deletions

View File

@ -1,9 +1,13 @@
find_package(msgpack 3.3.0 EXACT QUIET CONFIG)
find_package(msgpackc-cxx 4.0.0...<6 QUIET CONFIG)
find_package(msgpack-cxx 6 QUIET CONFIG)
add_library(msgpack INTERFACE)
if(msgpack_FOUND)
if(msgpack_FOUND OR msgpackc-cxx_FOUND)
target_link_libraries(msgpack INTERFACE msgpackc-cxx)
elseif(msgpack-cxx_FOUND)
target_link_libraries(msgpack INTERFACE msgpack-cxx)
else()
include(ExternalProject)
ExternalProject_add(msgpackProject