aboutsummaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorGuangxiong Lin <[email protected]>2022-12-01 15:45:18 +0800
committerGuangxiong Lin <[email protected]>2022-12-01 15:45:18 +0800
commit5626ba1525179d634676a347b5cd869cc3266090 (patch)
treeb6eb244db5070e7b140bafa36241d2bbbae01845 /Makefile
downloadtinyserver-5626ba1525179d634676a347b5cd869cc3266090.tar.gz
tinyserver-5626ba1525179d634676a347b5cd869cc3266090.tar.bz2
tinyserver-5626ba1525179d634676a347b5cd869cc3266090.zip
First commit
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile17
1 files changed, 17 insertions, 0 deletions
diff --git a/Makefile b/Makefile
new file mode 100644
index 0000000..7c005c9
--- /dev/null
+++ b/Makefile
@@ -0,0 +1,17 @@
+CC ?= gcc
+
+.PHONY: all
+all: client server
+
+.PHONY: clean
+clean:
+ rm -rf client server
+
+%.o: %.c
+ $(CC) -c $(CFLAGS) $(CPPFLAGS) $< -o $@
+
+client: client.o
+ $(CC) -o $@ $<
+
+server: server.o
+ $(CC) -o $@ $<