vcpkg/ports/sockpp/sockppConfig.cmake
Ankush Singh f5676127ee
[sockpp] Add new port (#11562)
* [sockpp] Add new port

* [sockpp] Address review comments

* [sockpp] Update ci.baseline

* [sockpp] Fix typo

* [sockpp] Fix sockppConfig.cmake
2020-06-01 19:10:23 -07:00

24 lines
789 B
CMake

get_filename_component(_DIR "${CMAKE_CURRENT_LIST_DIR}/../../" ABSOLUTE)
if(NOT SOCKPP_FIND_COMPONENTS)
set(SOCKPP_FIND_COMPONENTS sockpp)
if(SOCKPP_FIND_REQUIRED)
set(SOCKPP_FIND_REQUIRED_sockpp TRUE)
endif()
set(SOCKPP_FOUND TRUE)
endif()
set(SOCKPP_INCLUDE_DIRS ${_DIR}/include)
set(SOCKPP_LIBRARIES)
if (EXISTS ${_DIR}/lib/libsockpp.a)
list(APPEND SOCKPP_LIBRARIES optimized ${_DIR}/lib/libsockpp.a)
endif()
if (EXISTS ${_DIR}/debug/lib/libsockpp.a)
list(APPEND SOCKPP_LIBRARIES debug ${_DIR}/debug/lib/libsockpp.a)
endif()
if (EXISTS ${_DIR}/lib/sockpp.lib)
list(APPEND SOCKPP_LIBRARIES optimized ${_DIR}/lib/sockpp.lib)
endif()
if (EXISTS ${_DIR}/debug/lib/sockpp.lib)
list(APPEND SOCKPP_LIBRARIES debug ${_DIR}/debug/lib/sockpp.lib)
endif()