Compiling the Source Code
Go to the ONNX Runtime source code directory, run the compilation script, and set the relevant parameters, such as configuring the type, creating a shared library, and performing parallel compilation. Upon successful compilation, the corresponding command output is displayed.
- Go to the /path/to/ONNX_Runtime/onnxruntime directory.
1cd /path/to/ONNX_Runtime/onnxruntime
- Compile the ONNX Runtime source code to obtain the library file libonnxruntime.so and the wheel package onnxruntime-1.19.2-cp39-cp39-linux_aarch64.whl.
./build.sh --config RelWithDebInfo --build_shared_lib --build_wheel --parallel --compile_no_warning_as_error --skip_submodule_sync --cmake_extra_defines CMAKE_OSX_ARCHITECTURES=arm64 --allow_running_as_root --skip-keras-test --skip_onnx_tests --skip_tests --build_dir build
If the following information is displayed, the compilation is successful.

- (Optional) Install the wheel package.
pip install /path/to/ONNX_Runtime/onnxruntime/build/RelWithDebInfo/dist/onnxruntime-1.19.2-cp39-cp39-linux_aarch64.whl
The installation is successful if the following information is displayed:
