]> git.sur5r.net Git - cc65/blob - test/err/Makefile
use 'testwrk' dir for bdiff
[cc65] / test / err / Makefile
1
2 # makefile for the tests that MUST NOT compile
3
4 ifneq ($(shell echo),)
5   CMD_EXE = 1
6 endif
7
8 CC65FLAGS = -t sim6502
9
10 CL65 := $(if $(wildcard ../../bin/cl65*),../../bin/cl65,cl65)
11
12 ifdef CMD_EXE
13 RM := del /f
14 else
15 RM := rm -f
16 endif
17
18 WORKDIR := ./../../testwrk
19
20 .PHONY: all clean
21
22 TESTS := $(patsubst %.c,%.prg,$(wildcard *.c))
23 TESTS += $(patsubst %.c,%.o.prg,$(wildcard *.c))
24 TESTS += $(patsubst %.c,%.os.prg,$(wildcard *.c))
25 TESTS += $(patsubst %.c,%.osi.prg,$(wildcard *.c))
26 TESTS += $(patsubst %.c,%.osir.prg,$(wildcard *.c))
27 TESTS += $(patsubst %.c,%.oi.prg,$(wildcard *.c))
28 TESTS += $(patsubst %.c,%.oir.prg,$(wildcard *.c))
29 TESTS += $(patsubst %.c,%.or.prg,$(wildcard *.c))
30
31 all: $(TESTS)
32
33 %.prg: %.c
34         ! $(CL65) $(CC65FLAGS) $< -o $@
35 %.o.prg: %.c
36         ! $(CL65) $(CC65FLAGS) $< -o $@
37 %.os.prg: %.c
38         ! $(CL65) $(CC65FLAGS) $< -o $@
39 %.osi.prg: %.c
40         ! $(CL65) $(CC65FLAGS) $< -o $@
41 %.osir.prg: %.c
42         ! $(CL65) $(CC65FLAGS) $< -o $@
43 %.oi.prg: %.c
44         ! $(CL65) $(CC65FLAGS) $< -o $@
45 %.oir.prg: %.c
46         ! $(CL65) $(CC65FLAGS) $< -o $@
47 %.or.prg: %.c
48         ! $(CL65) $(CC65FLAGS) $< -o $@
49 clean:
50         @$(RM) *.o
51         @$(RM) *.prg