]> git.sesse.net Git - greproxy/commitdiff
Add a simple Makefile and .gitignore.
authorSteinar H. Gunderson <sgunderson@bigfoot.com>
Sat, 7 Feb 2015 00:36:56 +0000 (01:36 +0100)
committerSteinar H. Gunderson <sgunderson@bigfoot.com>
Sat, 7 Feb 2015 00:36:56 +0000 (01:36 +0100)
.gitignore [new file with mode: 0644]
Makefile [new file with mode: 0644]

diff --git a/.gitignore b/.gitignore
new file mode 100644 (file)
index 0000000..2e1c473
--- /dev/null
@@ -0,0 +1,3 @@
+tungre
+*.d
+*.o
diff --git a/Makefile b/Makefile
new file mode 100644 (file)
index 0000000..a0a8774
--- /dev/null
+++ b/Makefile
@@ -0,0 +1,14 @@
+CXXFLAGS=-std=gnu++11 -O2 -g
+
+TUNGRE_OBJS=greprotocol.o reorderer.o tungre.o tunprotocol.o
+
+tungre: $(TUNGRE_OBJS)
+       $(CXX) -o $@ $^ $(LDFLAGS) $(LDLIBS)
+
+%.o: %.cpp
+       $(CXX) -MMD -MP $(CPPFLAGS) $(CXXFLAGS) -o $@ -c $<
+DEPS=$(TUNGRE_OBJS:.o=.d)
+-include $(DEPS)
+
+clean:
+       $(RM) $(TUNGRE_OBJS) $(DEPS) gretun