diff options
author | Daniel Jones <admin@danieljon.es> | 2019-03-06 12:15:30 +1030 |
---|---|---|
committer | Daniel Jones <admin@danieljon.es> | 2019-03-06 12:15:30 +1030 |
commit | 81684d580370b9f45643078469beab3c73d29db3 (patch) | |
tree | d3d6127117fccbbd5ac65f8342110030800c2365 /makefile | |
download | urlopener-81684d580370b9f45643078469beab3c73d29db3.tar.gz urlopener-81684d580370b9f45643078469beab3c73d29db3.zip |
first code commit
Diffstat (limited to 'makefile')
-rw-r--r-- | makefile | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/makefile b/makefile new file mode 100644 index 0000000..e1a652a --- /dev/null +++ b/makefile @@ -0,0 +1,25 @@ +TARGET = urlopen +LIBS = +CC = gcc +CFLAGS = -g -Wall -Wextra + +.PHONY: default all clean + +default: $(TARGET) +all: default + +OBJECTS = $(patsubst %.c, %.o, $(wildcard *.c)) +HEADERS = $(wildcard *.h) + +%.o: %.c $(HEADERS) + $(CC) $(CFLAGS) -c $< -o $@ + +.PRECIOUS: $(TARGET) $(OBJECTS) + +$(TARGET): $(OBJECTS) + $(CC) $(OBJECTS) -Wall $(LIBS) -o $@ + +clean: + -rm -f *.o + -rm -f $(TARGET) + |