# tools
ASM=acme
EMU=x64

# sources and binaries
SOURCE=c64-test.asm
BIN=c64-test.o
# symbol and vice-label files
SYM=$(BIN:%.o=%.lst)
VICELABELS=$(BIN:%.o=%.lbl)

all: build

# build binary and generate label/symbol files
build: $(SOURCE)
	$(ASM) --format cbm --symbollist $(SYM) --vicelabels $(VICELABELS) --outfile $(BIN) $+

# run vice with binary and vice-label-file
run:
	$(EMU) --moncommands $(VICELABELS) $(BIN)

clean:
	rm -f $(BIN) $(SYM) $(VICELABELS)
