##
# makefile
#
# AUTHORS: Robert Fahy <rfahy@ymail.com>
# CREDITS: the internet
# VERSION: 1.00
#
##

##
# TASK:
# - automation
#
##

##
# TODO:
# - beg someone to rewrite it
#
##

CC=gcc
CFLAGS=-Wall -Wpointer-arith -Wstrict-prototypes -O2
PRGNAME=TEST_error.exe
COMPILE=$(CC) $(CFLAGS) -c
OBJFILES:=$(patsubst %.c,%.o, $(wildcard *.c))

the_program: compile run

compile: $(OBJFILES)
	$(CC) -o $(PRGNAME) $(OBJFILES)

%.o: %.c
	$(COMPILE) -o $@ $<

run:
	./$(PRGNAME)

clean:
	rm -v *~ *.exe *.o
