Skip to content
Snippets Groups Projects
Forked from orestis.malaspin / isc_physics
312 commits behind the upstream repository.
Makefile 454 B
CC=clang
# OPTS=-g -O3 -Wall -Wextra -fsanitize=address -fsanitize=leak -std=c11
# LINK=-lm -fsanitize=address -fsanitize=leak

OPTS=-g -O3 -Wall -Wextra -std=c11
LINK=-lm

vec2_tests: vec2_tests.o vec2.o util.o
	$(CC) $(OPTS) -o $@ $^ $(LINK)

test: vec2_tests
	./vec2_tests

vec2_tests.o: vec2_tests.c
	$(CC) $(OPTS) -c $^

vec2.o: ../vec2.c ../vec2.h
	$(CC) $(OPTS) -c $^

util.o: ../util.c ../util.h
	$(CC) $(OPTS) -c $^

clean:
	rm -f *.o vec2_tests