1 Star 0 Fork 1

shineboy/pytorch-TensorRT

forked from mirrors/pytorch-TensorRT 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
CMakeLists.txt 1.27 KB
一键复制 编辑 原始数据 按行查看 历史
cmake_minimum_required(VERSION 3.17)
project(Torch-TensorRT LANGUAGES CXX)
# use c++14 like PyTorch
set(CMAKE_CXX_STANDARD 14)
# Build the libraries with -fPIC
set(CMAKE_POSITION_INDEPENDENT_CODE ON)
if (DEFINED CMAKE_MODULE_PATH)
set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} CACHE PATH "Path to the folder containing finders")
endif()
include(cmake/build_options.cmake)
include(cmake/paths.cmake)
include(cmake/dependencies.cmake)
if(MSVC)
add_compile_options(/wd4624 /wd4067 /permissive-)
# When using Ninja generator, suppress the warning D9025
string(REPLACE "/Zi" "/Z7" CMAKE_C_FLAGS_DEBUG "${CMAKE_C_FLAGS_DEBUG}")
string(REPLACE "/Zi" "/Z7" CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG}")
endif()
# -----------------------------------------
# compilation
# -----------------------------------------
add_subdirectory(core)
add_subdirectory(cpp)
include(CMakePackageConfigHelpers)
configure_package_config_file(${CMAKE_CURRENT_SOURCE_DIR}/Config.cmake.in
"${CMAKE_CURRENT_BINARY_DIR}/torchtrtConfig.cmake"
INSTALL_DESTINATION ${CMAKE_INSTALL_LIBDIR}/cmake/torchtrt
)
install(FILES
"${CMAKE_CURRENT_BINARY_DIR}/torchtrtConfig.cmake"
# "${CMAKE_CURRENT_BINARY_DIR}/torchtrtConfigVersion.cmake"
DESTINATION ${CMAKE_INSTALL_LIBDIR}/cmake/torchtrt
)
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
C++
1
https://gitee.com/shineboy/pytorch-tensor-rt.git
git@gitee.com:shineboy/pytorch-tensor-rt.git
shineboy
pytorch-tensor-rt
pytorch-TensorRT
1.4_docs_archive

搜索帮助