Unverified Commit 6c2cda6a authored by junji hashimoto's avatar junji hashimoto Committed by GitHub
Browse files

Add vision.cpp in libtorchvision.so (#1843)

* Add vision.cpp in libtorchvision.so

* Define CMAKE_INSTALL_LIBDIR like https://cmake.org/cmake/help/latest/module/GNUInstallDirs.html

* Delete null-check of CMAKE_INSTALL_LIBDIR
parent 52b39ecc
...@@ -14,7 +14,7 @@ find_package(Python3 COMPONENTS Development) ...@@ -14,7 +14,7 @@ find_package(Python3 COMPONENTS Development)
find_package(Torch REQUIRED) find_package(Torch REQUIRED)
file(GLOB HEADERS torchvision/csrc/*.h) file(GLOB HEADERS torchvision/csrc/*.h)
file(GLOB OPERATOR_SOURCES torchvision/csrc/cpu/*.h torchvision/csrc/cpu/*.cpp) file(GLOB OPERATOR_SOURCES torchvision/csrc/cpu/*.h torchvision/csrc/cpu/*.cpp torchvision/csrc/*.cpp)
if(WITH_CUDA) if(WITH_CUDA)
file(GLOB OPERATOR_SOURCES ${OPERATOR_SOURCES} torchvision/csrc/cuda/*.h torchvision/csrc/cuda/*.cu) file(GLOB OPERATOR_SOURCES ${OPERATOR_SOURCES} torchvision/csrc/cuda/*.h torchvision/csrc/cuda/*.cu)
endif() endif()
...@@ -47,7 +47,9 @@ install(FILES ${CMAKE_CURRENT_BINARY_DIR}/TorchVisionConfig.cmake ...@@ -47,7 +47,9 @@ install(FILES ${CMAKE_CURRENT_BINARY_DIR}/TorchVisionConfig.cmake
DESTINATION ${TORCHVISION_CMAKECONFIG_INSTALL_DIR}) DESTINATION ${TORCHVISION_CMAKECONFIG_INSTALL_DIR})
install(TARGETS ${PROJECT_NAME} install(TARGETS ${PROJECT_NAME}
EXPORT TorchVisionTargets) EXPORT TorchVisionTargets
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}
)
install(EXPORT TorchVisionTargets install(EXPORT TorchVisionTargets
NAMESPACE TorchVision:: NAMESPACE TorchVision::
......
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