To link a binary file using Command line, perform the following steps:
- Linker recognizes
.bin extension as a binary data input file. If binary file has another extension it may not be recognized correctly by the command line linker.
- Update linker command file (
.lcf ) and place
.BINARY section into memory.
Linker Command File with .BINARY section shows a sample linker command file with
.BINARY section.
- Add a binary file (
.bin ) as an input file for linker (MWLDEPPC.exe)
mwldeppc main.o msl.lib bin_data.bin -o myapp.elf -lcf commandfile.lcf