summaryrefslogtreecommitdiff
path: root/Makefile
blob: e157f0f17f84e074fc14629d9839b3a7fc6ee771 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
CC     = gcc
CFLAGS = -Wall -Iinclude/
OUTPUT = main
MAIN   = main.c
DEPS   = include/types.h include/board.h include/print.h include/piece.h include/coordinate.h
OBJ    = lib/board.o lib/print.o lib/piece.o lib/coordinate.o

%.o: %.c $(DEPS)
	$(CC) -c -o $@ $< $(CFLAGS)

all: $(OBJ)
	$(CC) $(CFLAGS) -o $(OUTPUT)  $^ $(MAIN)

clean:
	rm -f $(OUTPUT) $(OBJ)
nihil fit ex nihilo