Skip to content

Unresolved External Error __imp__OrtGetApiBase@0 #6808

Answered by matt256
matt256 asked this question in Other Q&A
Discussion options

You must be logged in to vote

update:
As I thought it may have been, I was having build issues where I was improperly linking the onnxruntime.lib file. It works now. The below is a revision to the part of the CMakeLists file referenced above:

include_directories("${ONNXRUNTIME_ROOTDIR}include" "${ONNXRUNTIME_ROOTDIR}/include/onnxruntime/core/session","${ONNXRUNTIME_ROOTDIR}/build/Windows/RelWithDebInfo/RelWithDebInfo")
target_link_libraries(MyExample "${ONNXRUNTIME_ROOTDIR}/build/Windows/RelWithDebInfo/RelWithDebInfo/onnxruntime.lib")

I actually tried to just delete this thread because it was more of a novice C++ issue rather than an ONNX issue. I suppose that's up to the moderators.

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by matt256
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
1 participant