You copied the Doc URL to your clipboard.

Building an application with microlib

To build a program using microlib, you must use the command-line option --library_type=microlib. This option can be used by the armasm assembler or linker. Use it with the linker to override all other options.

Example 12 shows this option being used by the assembler.The request to the linker to use microlib is made as a result of assembling more.s with --library_type=microlib.

armasm --cpu=8-A.32 main.s extra.s
armasm --cpu=8-A.32 --library_type=microlib more.s
armlink --force_scanlib -o image.axf main.o extra.o more.o

Example 13 shows this option being used by the linker.

armclang --target armv8a-arm-none-eabi -c main.c
armclang -c extra.c
armlink --force_scanlib --library_type=microlib -o image.axf main.o extra.o