Add onnxruntime gpu for cmake (#153)

* add onnxruntime gpu for cmake

* fix clang

* fix typo

* cpplint
This commit is contained in:
Yuekai Zhang
2023-05-12 22:30:47 +08:00
committed by GitHub
parent cea718e3d8
commit b8fbf8e5ce
4 changed files with 90 additions and 18 deletions

View File

@@ -78,6 +78,12 @@ target_link_libraries(sherpa-onnx-core
kaldi-native-fbank-core
)
if(SHERPA_ONNX_ENABLE_GPU)
target_link_libraries(sherpa-onnx-core
onnxruntime_providers_cuda
)
endif()
if(SHERPA_ONNX_ENABLE_CHECK)
target_compile_definitions(sherpa-onnx-core PUBLIC SHERPA_ONNX_ENABLE_CHECK=1)