-
Notifications
You must be signed in to change notification settings - Fork 8
Expand file tree
/
Copy pathMakefile.asmexamples
More file actions
40 lines (30 loc) · 797 Bytes
/
Copy pathMakefile.asmexamples
File metadata and controls
40 lines (30 loc) · 797 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
#
# Created by Joakim Larsson Edström, (c) 2015
#
LB=/usr/local/bin/aslib
LN=/usr/local/bin/aslink
AS=/usr/local/bin/as6809
AFLAGS=-l -og
CC=/usr/local/libexec/gcc/m6809-unknown-none/4.3.4/cc1
BINS = vp.bin dt2.bin ln1.bin ln2.bin snd1.bin
OBJS = $(BINS:.bin=.o)
RELS = $(BINS:.bin=.rel)
LSTS = $(BINS:.bin=.lst)
MAPS = $(BINS:.bin=.map)
ROMS = $(BINS:.bin=.rom)
RAMS = $(BINS:.bin=.ram)
ASRC = $(BINS:.bin=.s)
S19S = $(BINS:.bin=.s19)
S19S += $(BINS:.bin=_ram.s19)
CLEAN_LIST= $(S19S) $(ASRC) $(OBJS) $(RELS) $(LSTS) $(MAPS) *~ $(RAMS) $(ROMS)
.PHONY: clean all
all: $(BINS)
%.bin: %.s19 %_ram.s19
srec_cat $*.s19 -o bin/$*.bin -binary
%.s19 %_ram.s19: %.o crt0.o
$(LN) -m -nws -b .text=0x0 $*.o
clean:
@- $(RM) $(CLEAN_LIST)
%.o: %.asm
$(AS) -l -og $<
mv $*.rel $*.o