-
Notifications
You must be signed in to change notification settings - Fork 5.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
"Undefined symbols for architecture arm64" on Apple M1 Max when compiling Inference library #44712
Comments
try import this PR: #42325 |
This helps on building the paddle_python target with no problem. But when it comes to c/c++ inference library it still fails. After the success of the python build, the errors are:
The command I used to build is:
Branch: develop |
I am also facing the same issue. Pls help. |
any update on this? |
Since you haven't replied for more than a year, we have closed this issue/pr. |
问题描述 Issue Description
参考文档/This doc was referred:https://paddle-inference.readthedocs.io/en/latest/guides/install/compile/source_compile_under_MacOS.html
制作Makefile命令/Command to make Makefile:cmake .. -DPY_VERSION=3.9 -DPYTHON_INCLUDE_DIR=${PYTHON_INCLUDE_DIRS}
-DPYTHON_LIBRARY=${PYTHON_LIBRARY} -DWITH_GPU=OFF -DWITH_TESTING=OFF
-DWITH_AVX=OFF -DWITH_ARM=ON -DCMAKE_BUILD_TYPE=Release -DON_INFER=ON
编译命令/Command to compile:make inference_lib_dist TARGET=ARMV8 -j8
报错信息
Error Message:
之所以未按照文档指示使用-DWITH_INFER=ON是因为develop和release/2.3两个分支的此选项均无效,CMakeList.txt中没有相应的配置,实测编译完成后也不会出现c/c++预测库。所以我选择使用-DON_INFER=ON配合make的inference_lib_dist参数进行编译。
The reason why I did not stick to the doc to use -DWITH_INFER=ON but rather chose to use -DON_INFER=ON instead, is that -DWITH_INFER=ON was not working in either develop or release/2.3 branch. So I choose to use -DON_INFER=ON with "inference_lib_dist" parameter.
之所以选用develop分支是因为release/2.3分支在使用-DON_INFER=ON时编译会报illegal hardware instruction问题,此问题已经在其他issue中提出但是没有见到后续回复。develop分支编译没有遇到此问题。
The reason why I chose the develop branch is that I have encountered with "illegal hardware instruction" issue in release/2.3 branch with -DON_INFER=ON. This issue has been raised earlier by someone else and I do not see a solution as of now. There is no such issue in the current develop branch.
版本&环境信息 Version & Environment Information
Paddle version: None
Paddle With CUDA: None
OS: macOs 12.4
Python version: 3.9.12
CUDA version: None
cuDNN version: None.None.None
Nvidia driver version: None
Branch:develop
Commit:fix logging debug level (#44684) 8aa286d
CPU:Apple M1 Max
GPU:Apple M1 Max
The text was updated successfully, but these errors were encountered: