Skip to content

Commit 2b5c0bc

Browse files
authored
fix deps copy for nodejs binding build (microsoft#24712)
### Description <!-- Describe your changes. --> fix the copy of the dependencies and now it does not only work in windows. ### Motivation and Context <!-- - Why is this change required? What problem does it solve? - If it fixes an open issue, please link to the issue here. -->
1 parent a956551 commit 2b5c0bc

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

js/node/CMakeLists.txt

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -113,12 +113,6 @@ endif()
113113
if (WIN32)
114114
file(COPY ${ONNXRUNTIME_WIN_BIN_DIR}/onnxruntime.dll
115115
DESTINATION ${dist_folder})
116-
if (ORT_NODEJS_DLL_DEPS)
117-
foreach(dll ${ORT_NODEJS_DLL_DEPS})
118-
file(COPY ${dll} DESTINATION ${dist_folder})
119-
endforeach()
120-
endif()
121-
122116
elseif (APPLE)
123117
file(COPY ${ONNXRUNTIME_BUILD_DIR}/libonnxruntime.dylib
124118
DESTINATION ${dist_folder} FOLLOW_SYMLINK_CHAIN)
@@ -128,3 +122,9 @@ elseif (UNIX)
128122
else()
129123
message(FATAL_ERROR "Platform not supported.")
130124
endif()
125+
126+
if (ORT_NODEJS_DLL_DEPS)
127+
foreach(dll ${ORT_NODEJS_DLL_DEPS})
128+
file(COPY ${dll} DESTINATION ${dist_folder})
129+
endforeach()
130+
endif()

0 commit comments

Comments
 (0)