8.3.13 Nostdlib Option

The -nostdlib option will prevent the standard system startup files and libraries being linked into the project. No startup files and only the libraries you specify are passed to the linker.

Note that both the driver and linker have -nostdlib options. Almost certainly, you will intend to use the driver version of this option, as it will look on search paths given in linker scripts. To use the driver option, do not prefix the option with -Wl,.

The compiler may generate calls to memcmp(), memset() and memcpy(). These entries are usually resolved by entries in standard compiler libraries. These entry points should be supplied through some other mechanism when this option is specified.