Unverified Commit fc490902 authored by martingasser's avatar martingasser Committed by GitHub
Browse files

added cmake interface dependency (#2684)


Co-authored-by: default avatarYour Name <you@example.com>
Co-authored-by: default avatarFrancisco Massa <fvsmassa@gmail.com>
parent 2801a76d
......@@ -31,7 +31,9 @@ endif()
if(NOT TARGET Python3::Python)
find_package(Python3 COMPONENTS Development)
endif()
target_link_libraries(TorchVision::TorchVision INTERFACE ${TORCH_LIBRARIES} Python3::Python)
set_target_properties(TorchVision::TorchVision PROPERTIES INTERFACE_INCLUDE_DIRECTORIES "${PACKAGE_PREFIX_DIR}/@CMAKE_INSTALL_INCLUDEDIR@" INTERFACE_LINK_LIBRARIES "torch;Python3::Python" )
if(@WITH_CUDA@)
target_compile_definitions(TorchVision::TorchVision INTERFACE WITH_CUDA)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment