aboutsummaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile21
1 files changed, 21 insertions, 0 deletions
diff --git a/Makefile b/Makefile
new file mode 100644
index 0000000..084bee4
--- /dev/null
+++ b/Makefile
@@ -0,0 +1,21 @@
+PROJ=slowbaud
+
+CC=gcc
+CFLAGS=-Wall -O2 $(EXTRACFLAGS)
+LIBS=-lutil
+RST2MAN=rst2man.py
+
+all: $(PROJ)
+
+$(PROJ): $(PROJ).c $(PROJ).1 README.txt
+ $(CC) $(CFLAGS) -o $(PROJ) $(PROJ).c $(LIBS)
+
+$(PROJ).1: $(PROJ).rst
+ $(RST2MAN) $(PROJ).rst > $(PROJ).1
+
+README.txt: $(PROJ).1
+ man ./$(PROJ).1 | sed 's,_\010,,' > README.txt
+
+# Don't remove the man page or README here, it's in git.
+clean:
+ rm -f $(PROJ) core *.o