Nios® V Processor Software Developer Handbook

ID 743810
Date 7/08/2024
Public
Document Table of Contents

8.8.5.3.3. Setting Destination Files

The destination argument of add_sw_setting specifies settings and their assigned values. This argument controls the file to which the setting is saved in the BSP. The BSP generator formats the setting’s assigned value based on the definition file and type of setting.
Table 36.  Destination File Settings
Destination File Setting Value Notes
system.h system_h_define This destination file is recommended in most cases. Your source code must use a #include <system.h> statement to make the setting definitions available. Settings appear as #define statements in system.h.
toolchain.cmake public_mk_define Definitions appear as -D statements in toolchain.cmake, in the C preprocessor flags assembly. This setting type is passed directly to the compiler during build and is visible during compilation of application and libraries referencing the BSP.
makefile_variable Settings appear as makefile variable assignments in the toolchain.cmake.
Note: Certain setting types are not compatible with the toolchain.cmake destination file types.

For more information, refer to the Tcl Commands for Drivers and Packages chapter.