about summary refs log tree commit diff
path: root/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile7
1 files changed, 4 insertions, 3 deletions
diff --git a/Makefile b/Makefile
index fb51c92..75ceac7 100644
--- a/Makefile
+++ b/Makefile
@@ -7,8 +7,9 @@ OBJS += root.o
 CFLAGS += $(shell curl-config --cflags)
 CFLAGS += -std=c11
 
-LDFLAGS += $(shell curl-config --libs)
-LDFLAGS += -lcpetpet
+LDLIBS += $(shell curl-config --libs)
+LDLIBS += -lcpetpet
+LDLIBS += -lcurl
 RM = rm -f
 
 all: cptc
@@ -20,7 +21,7 @@ root.c: utils/convert README
 	echo "const char *CPTC_root = \"$$(cat README | utils/convert)\";" > $@
 
 cptc: $(OBJS)
-	$(CC) -o $@ $^ $(LDFLAGS)
+	$(CC) $(LDFLAGS) $(OBJS) $(LDLIBS) -o $@
 
 clean:
 	$(RM) cptc *.o