Linking - Linking - 6.0 English - PG141

DDS Compiler LogiCORE IP Product Guide (PG141)

Document_ID
PG141
Release_Date
2024-12-11
Version
6.0 English

To use the C model, the user executable must be linked against the correct libraries for the target platform.

Linux

The executable must be linked against the libIp_dds_compiler_v6_0_bitacc_cmodel.so library.

Using GCC, linking is typically achieved by adding the following command line options:

-L. -Wl, -rpath,. -lIp_dds_compiler_v6_0_bitacc_cmodel

This assumes the object library is in the current directory. If this is not the case, the -L. option should be changed to specify the library search path to use.

Using GCC, the provided example program run_bitacc_cmodel.c can be compiled and linked using the following command:

gcc -x c++ -I. -L. -lIp_dds_compiler_v6_0_bitacc_cmodel -Wl, -rpath,. -o run_bitacc_cmodel run_bitacc_cmodel.c

Windows

The executable must be linked against the libIp_dds_compiler_v6_0_bitacc_cmodel.dll dynamic link library.

Depending on the compiler, the libIp_dds_compiler_v6_0_bitacc_cmodel.lib import library might also be required.

To link to an import library using Microsoft Visual Studio, add the library to the Additional Dependencies entry under the Linker section of Project Properties.