DefTruth / lite.ai.toolkit

🛠 A lite C++ toolkit of awesome AI models, support ONNXRuntime, MNN. Contains YOLOv5, YOLOv6, YOLOX, YOLOv8, FaceDet, HeadSeg, HeadPose, Matting etc. Engine: ONNXRuntime, MNN.
https://github.com/DefTruth/lite.ai.toolkit
GNU General Public License v3.0
3.53k stars 672 forks source link

Compile on M1 Chip #391

Open shersoni610 opened 1 year ago

shersoni610 commented 1 year ago

Hello,

On Apple M1 Chip, I get the following error:

ld: warning: ignoring file /Users/Projects/CompVis/LiteAi/lite.ai.toolkit/lib/macos/libopencv_videoio.dylib, building for macOS-arm64 but attempting to link with file built for macOS-x86_64 Undefined symbols for architecture arm64: "_OrtGetApiBase", referenced from: _cxx_global_var_init.8 in agegooglenet.cpp.o cxx_global_var_init.19 in backgroundmattingv2.cpp.o _cxx_global_var_init.18 in backgroundmattingv2dyn.cpp.o cxx_global_var_init.8 in cava_combined_face.cpp.o _cxx_global_var_init.8 in cava_ghostarcface.cpp.o cxx_global_var_init.8 in center_loss_face.cpp.o ___cxx_global_var_init.8 in colorizer.cpp.o ...

Leo-WL commented 1 year ago

same error here, please help "ld: error: undefined symbol: OrtGetApiBase referenced by onnxruntime_cxx_api.h:114"

wangzijian1010 commented 1 year ago

same error plz help!!!

naonao-cola commented 10 months ago

同样遇到这个问题了,mac 系统说的应该是macOS-X86_64,不是macOS-arm64。暂时无法解决。只能看看源码怎么写的了

xp19870106 commented 9 months ago

U r linking to a x86 architecture library, just change it to an arm64 architecture library, it will be ok

github-actions[bot] commented 4 months ago

This issue is stale because it has been open for 30 days with no activity.