From 73c9bccfff73f4eee256dec6ded061f84310b091 Mon Sep 17 00:00:00 2001 From: Baiju Meswani Date: Mon, 23 Sep 2024 22:52:21 +0000 Subject: [PATCH] Share downloaded ort with ort-extensions --- CMakeLists.txt | 2 +- cmake/ortlib.cmake | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index a3d1bac27..45ae064a1 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -20,8 +20,8 @@ if(MSVC) add_compile_definitions(_DISABLE_CONSTEXPR_MUTEX_CONSTRUCTOR) endif() -include(cmake/external/onnxruntime_external_deps.cmake) include(cmake/ortlib.cmake) +include(cmake/external/onnxruntime_external_deps.cmake) # All Global variables, including GLOB, for the top level CMakeLists.txt should be defined here include(cmake/global_variables.cmake) # Checking if CUDA is supported diff --git a/cmake/ortlib.cmake b/cmake/ortlib.cmake index 23b6d7516..45d7adab7 100644 --- a/cmake/ortlib.cmake +++ b/cmake/ortlib.cmake @@ -121,5 +121,9 @@ if(USE_DML) set(D3D12_LIB_DIR ${d3d12lib_SOURCE_DIR}/build/native/bin/${DML_BINARY_PLATFORM}) endif() +# onnxruntime-extensions can use the same onnxruntime headers +set(ONNXRUNTIME_INCLUDE_DIR ${ORT_HEADER_DIR}) +set(ONNXRUNTIME_LIB_DIR ${ORT_LIB_DIR}) + message(STATUS "ORT_HEADER_DIR: ${ORT_HEADER_DIR}") message(STATUS "ORT_LIB_DIR: ${ORT_LIB_DIR}")