Add Makefile - dedup - deduplicating backup program
HTML git clone git://bitreich.org/dedup/ git://enlrupgkhuxnvlhsf6lc3fziv5h2hhfrinws65d7roiv6bfj7d652fid.onion/dedup/
DIR Log
DIR Files
DIR Refs
DIR Tags
DIR README
DIR LICENSE
---
DIR commit 53e9db19eac9711cda7a658131d9cb1b42892113
DIR parent 72a5c2c2269c959061bfb34a05f29875653f3e92
HTML Author: sin <sin@2f30.org>
Date: Tue, 20 Mar 2018 16:40:33 +0000
Add Makefile
Diffstat:
A Makefile | 40 +++++++++++++++++++++++++++++++
1 file changed, 40 insertions(+), 0 deletions(-)
---
DIR diff --git a/Makefile b/Makefile
@@ -0,0 +1,40 @@
+VERSION = 0.0
+PREFIX = /usr/local
+SRC = dedup.c
+OBJ = dedup.o
+BIN = dedup
+DISTFILES = $(SRC) LICENSE Makefile arg.h
+
+CPPFLAGS = -I/usr/local/include
+LDLIBS = -lcrypto
+
+all: $(BIN)
+
+dedup.o: arg.h
+
+clean:
+ rm -f $(OBJ) $(BIN) $(BIN)-$(VERSION).tar.gz
+
+install: all
+ mkdir -p $(DESTDIR)$(PREFIX)/bin
+ cp -f $(BIN) $(DESTDIR)$(PREFIX)/bin
+
+uninstall:
+ rm -f $(DESTDIR)$(PREFIX)/bin/$(BIN)
+
+dist:
+ mkdir -p $(BIN)-$(VERSION)
+ cp $(DISTFILES) $(BIN)-$(VERSION)
+ tar -cf $(BIN)-$(VERSION).tar $(BIN)-$(VERSION)
+ gzip $(BIN)-$(VERSION).tar
+ rm -rf $(BIN)-$(VERSION)
+
+.PHONY: all clean install uninstall dist
+
+.SUFFIXES: .c .o
+
+.c.o:
+ $(CC) $(CPPFLAGS) $(CFLAGS) -c $<
+
+$(BIN): $(OBJ)
+ $(CC) -o $@ $(OBJ) $(LDFLAGS) $(LDLIBS)