28 lines
379 B
Makefile
28 lines
379 B
Makefile
CC=gcc
|
|
CFLAGS=-g3
|
|
LIBFLAGS=-c
|
|
CFILES=streecmp.c
|
|
TFILES=test.c
|
|
LEAKSFILE=LEAKS
|
|
OUTPUT=streecmp
|
|
TOUTPUT=test
|
|
|
|
all:
|
|
$(CC) $(LIBFLAGS) $(CFLAGS) $(CFILES) -o $(OUTPUT)
|
|
make test
|
|
|
|
test:
|
|
$(CC) $(CFLAGS) $(CFILES) $(TFILES) -o $(TOUTPUT)
|
|
|
|
run:
|
|
./$(OUTPUT)
|
|
|
|
run_test:
|
|
./$(TOUTPUT)
|
|
|
|
memcheck:
|
|
valgrind ./$(TOUTPUT) 2>&1 | tee $(LEAKSFILE)
|
|
|
|
clean:
|
|
rm -rf $(OUTPUT) $(TOUTPUT)
|