]> arthur.barton.de Git - bup.git/blobdiff - Makefile
Add a 'bup' wrapper program.
[bup.git] / Makefile
index a26c421ce6d70c3eb090472f7c59f4b9b8e79f5c..170756039d64073d88fd2e44e594e7627f160adb 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -2,7 +2,7 @@ CFLAGS=-Wall -g -O2 -Werror -I/usr/include/python2.5 -g -fwrapv -fPIC
 
 default: all
 
-all: hashsplit hashjoin datagen hashsplit.so
+all: bup-split bup-join bup datagen hashsplit.so
 
 datagen: datagen.o
 
@@ -10,24 +10,28 @@ hashsplit.so: hashsplitmodule.o
        $(CC) -shared -Wl,-Bsymbolic-functions -o $@ $<
 
 test: all
-       ./hashsplit.py <testfile1 >tags1
-       ./hashsplit.py <testfile2 >tags2
+       ./bup split <testfile1 >tags1
+       ./bup split <testfile2 >tags2
        diff -u tags1 tags2 || true
        wc -c testfile1 testfile2
        wc -l tags1 tags2
-       ./hashjoin <tags1 >out1
-       ./hashjoin <tags2 >out2
+       ./bup join <tags1 >out1
+       ./bup join <tags2 >out2
        diff -u testfile1 out1
        diff -u testfile2 out2
 
 %: %.o
        gcc -o $@ $< $(LDFLAGS) $(LIBS)
        
-%: %.py
+bup: bup.py
        rm -f $@
        ln -s $^ $@
        
-%: %.sh
+bup-%: cmd-%.py
+       rm -f $@
+       ln -s $^ $@
+       
+bup-%: cmd-%.sh
        rm -f $@
        ln -s $^ $@
        
@@ -35,5 +39,6 @@ test: all
        gcc -c -o $@ $^ $(CPPFLAGS) $(CFLAGS)
 
 clean:
-       rm -f *.o *.so *~ hashsplit hashjoin hsplit hjoin datagen *.pyc \
-               out[12] tags[12] .*~
+       rm -f *.o *.so *~ .*~ *.pyc \
+               bup bup-split bup-join datagen \
+               out[12] tags[12]