Refer to Installing AOCL to install the AOCL-Utils library. Then, complete the following steps to compile AOCL-LibM:
Download source from GitHub (amd/aocl-libm-ose).
Navigate to the LibM folder and checkout the branch aocl-5.2:
$ cd aocl-libm-ose $ git checkout aocl-5.2
Create a virtual environment:
$ virtualenv -p python3 .venv3
Activate the virtual environment:
$ source .venv3/bin/activate
Install SCons:
$ pip install scons
Compile AOCL-LibM:
Basic build command: scons --aocl_utils_install_path=<libaoclutils library path> Additional Flags Build in parallel: -j<number of parallel builds> Installation: install --prefix=<path to install> Compiler selection: ALM_CC=<gcc/clang executable path> ALM_CXX=<g++/clang++ executable path> Verbosity: --verbose=1 Debug mode build: --debug_mode=libs
By default, the libraries (static and dynamic) will be compiled and generated in the following location:
aocl-libm-ose/build/aocl-release/src/
If a debug mode build has been selected, the libraries (static and dynamic) will instead be compiled and generated in the following location:
aocl-libm-ose/build/aocl-debug/src
If the installation option is used, the libraries will also be copied to the directory <path to install>/lib.