
CC=gcc
CFLAGS=-std=c99 -pedantic -Wall -D_DEFAULT_SOURCE -D_BSD_SOURCE -D_SVID_SOURCE -D_POSIX_C_SOURCE=200809L -g

.PHONY: all clean
all: default
default: main

main.o: main.c
	$(CC) -c -o $@ $^ $(CFLAGS)

main: main.o
	$(CC) -o $@ $^ $(CFLAGS) -lc

clean:
	rm -rf main *.o
