CFLAGS=-std=c99 -Wall -g
INDENTOPTS=-kr --no-tabs --braces-on-func-def-line --indent-level2

.PHONY: all
all: approximate-pi linked-list mandelbrot

.PHONY: clean
clean:
	rm -f approximate-pi linked-list mandelbrot *~

.PHONY: indent
indent:
	indent $(INDENTOPTS) *.c

mandelbrot: mandelbrot.c
	$(CC) $(CFLAGS) $(shell sdl-config --cflags) -o $@ $< $(shell sdl-config --libs) -lm