diff options
| author | Gustav Sörnäs <gustav@sornas.net> | 2021-01-26 14:22:46 +0100 |
|---|---|---|
| committer | Gustav Sörnäs <gustav@sornas.net> | 2021-01-26 14:22:55 +0100 |
| commit | 38866c562ee404eb52a536785a5e7fafe7951185 (patch) | |
| tree | 54b87c7c13073e6ce340c222935fc5eeb17fafbc /Makefile | |
| download | linked-list-38866c562ee404eb52a536785a5e7fafe7951185.tar.gz | |
Diffstat (limited to 'Makefile')
| -rw-r--r-- | Makefile | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..0ac8095 --- /dev/null +++ b/Makefile @@ -0,0 +1,21 @@ +SRC = linked_list.c +OBJ = $(SRC:.c=.o) + +all: linked_list + +.c.o: + $(CC) -c $< + +linked_list: $(OBJ) + $(CC) -o $@ $(OBJ) + +run: linked_list + ./linked_list + +valgrind: linked_list + valgrind --tool=memcheck --leak-check=yes ./linked_list + +clean: + rm -f linked_list $(OBJ) + +.PHONY: all run valgrind clean |
