Add makefile
This commit is contained in:
parent
e41a7d84c2
commit
66cd9d46d6
27
Makefile
Normal file
27
Makefile
Normal file
@ -0,0 +1,27 @@
|
|||||||
|
# Macros
|
||||||
|
CC = gcc
|
||||||
|
CFLAGS = -ansi -Wall -g -O0 -Wshadow -Wwrite-strings \
|
||||||
|
-fstack-protector-all
|
||||||
|
LDLIBS = -lncurses
|
||||||
|
|
||||||
|
all: typing_test debugger
|
||||||
|
|
||||||
|
# Create executables
|
||||||
|
typing_test: typing_test.o string_helpers.o
|
||||||
|
$(CC) -o typing_test typing_test.o string_helpers.o $(LDLIBS)
|
||||||
|
|
||||||
|
debugger: debugger.o utilities.o
|
||||||
|
$(CC) -o debugger debugger.o utilities.o
|
||||||
|
|
||||||
|
typing_test.o: typing_test.c
|
||||||
|
$(CC) $(CFLAGS) -c typing_test.c $(LDLIBS)
|
||||||
|
|
||||||
|
debugger.o: debugger.c utilities.h
|
||||||
|
$(CC) $(CFLAGS) -c debugger.c
|
||||||
|
|
||||||
|
utilities.o: utilities.c
|
||||||
|
$(CC) $(CFLAGS) -c utilities.c
|
||||||
|
|
||||||
|
clean:
|
||||||
|
@echo "Cleaning system"
|
||||||
|
@rm -f *.o
|
Loading…
x
Reference in New Issue
Block a user