linker: ensured .bss comes after .data, and added map file output

This commit is contained in:
A.M. Rowsell 2025-12-21 14:40:15 -05:00
commit e3c9c7b642
Signed by: amr
GPG key ID: E0879EDBDB0CA7B1
4 changed files with 11 additions and 5 deletions

View file

@ -2,9 +2,10 @@
# SPDX-FileCopyrightText: (c) 2025 A.M. Rowsell
ASM=vasm_z80_std
LINK=vlink
MAP=zone.map
ASMFLAGS=-Fvobj
LINKFLAGS=-b ihex -T linker.cmd
LINKFLAGS=-b ihex -T linker.cmd -M
all: zone.hex
@ -21,9 +22,9 @@ boot.o: boot.asm
$(ASM) $(ASMFLAGS) -o $@ $<
zone.hex: float.o vectorTable.o zone.o boot.o linker.cmd
$(LINK) $(LINKFLAGS) -o $@ float.o vectorTable.o zone.o boot.o
$(LINK) $(LINKFLAGS) -o $@ float.o vectorTable.o zone.o boot.o > $(MAP)
clean:
rm -f float.o vectorTable.o zone.o boot.o zone.hex
rm -f float.o vectorTable.o zone.o boot.o zone.hex $(MAP)
.PHONY: all clean