mirror of
https://github.com/microsoft/vcpkg.git
synced 2024-12-05 10:39:01 +08:00
4d84733f48
Co-authored-by: Nick D'Ademo <dademo.n@duerr-ndt.com> Co-authored-by: Kai Pastor <dg0yt@darc.de>
20 lines
1.1 KiB
CMake
20 lines
1.1 KiB
CMake
if(NOT TARGET unofficial::libusbp::libusbp)
|
|
add_library(unofficial::libusbp::libusbp UNKNOWN IMPORTED)
|
|
|
|
set_target_properties(unofficial::libusbp::libusbp PROPERTIES
|
|
INTERFACE_INCLUDE_DIRECTORIES "${_VCPKG_INSTALLED_DIR}/${VCPKG_TARGET_TRIPLET}/include/libusbp-1"
|
|
)
|
|
|
|
find_library(libusbp_LIBRARY_RELEASE NAMES usbp-1 PATHS "${_VCPKG_INSTALLED_DIR}/${VCPKG_TARGET_TRIPLET}/lib" NO_DEFAULT_PATH)
|
|
if(EXISTS "${libusbp_LIBRARY_RELEASE}")
|
|
set_property(TARGET unofficial::libusbp::libusbp APPEND PROPERTY IMPORTED_CONFIGURATIONS "Release")
|
|
set_target_properties(unofficial::libusbp::libusbp PROPERTIES IMPORTED_LOCATION_RELEASE "${libusbp_LIBRARY_RELEASE}")
|
|
endif()
|
|
|
|
find_library(libusbp_LIBRARY_DEBUG NAMES usbp-1 PATHS "${_VCPKG_INSTALLED_DIR}/${VCPKG_TARGET_TRIPLET}/debug/lib" NO_DEFAULT_PATH)
|
|
if(EXISTS "${libusbp_LIBRARY_DEBUG}")
|
|
set_property(TARGET unofficial::libusbp::libusbp APPEND PROPERTY IMPORTED_CONFIGURATIONS "Debug")
|
|
set_target_properties(unofficial::libusbp::libusbp PROPERTIES IMPORTED_LOCATION_DEBUG "${libusbp_LIBRARY_DEBUG}")
|
|
endif()
|
|
endif()
|