-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathMakefile
32 lines (24 loc) · 874 Bytes
/
Makefile
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
# Copyright (C) 2012-2025 Craig Thomas
# This project uses an MIT style license - see LICENSE for details.
NAME = yac8e
TESTNAME = test
MAINOBJS = src/cpu.o src/keyboard.o src/memory.o src/screen.o src/yac8e.o src/globals.o
TESTOBJS = src/cpu.o src/keyboard.o src/memory.o src/screen.o src/cpu_test.o src/screen_test.o src/test.o src/keyboard_test.o src/globals.o
override CFLAGS += -Wall -g $(shell sdl2-config --cflags)
LDFLAGS += $(shell sdl2-config --libs) -lcunit -lm -lSDL2_mixer
.PHONY: all doc clean
all: $(NAME)
yac8e: $(MAINOBJS)
$(LINK.c) -o $(NAME) $(MAINOBJS) $(LDFLAGS)
test: $(TESTOBJS)
$(LINK.c) -o $(TESTNAME) $(TESTOBJS) $(LDFLAGS)
./$(TESTNAME)
doc:
doxygen doxygen.conf
clean:
@- $(RM) $(wildcard src/*.o)
@- $(RM) $(wildcard src/*.gcda)
@- $(RM) $(wildcard src/*.gcno)
@- $(RM) $(wildcard *.gcov)
@- $(RM) $(NAME)
@- $(RM) $(TESTNAME)