Permalink
Browse files

add install and uninstall targets

  • Loading branch information...
1 parent b4a78de commit 209084ce2316796081dcea01d51a581d6bd74fef @tj committed Jan 26, 2013
Showing with 10 additions and 2 deletions.
  1. +10 −2 Makefile
View
@@ -2,11 +2,19 @@
SRC = $(wildcard src/*.c)
SRC += $(wildcard deps/*.c)
OBJ = $(SRC:.c=.o)
+PREFIX=/usr/local
+BIN=histo
histo: $(SRC)
$(CC) $^ -std=c99 -lm -I deps -o $@
+install: $(BIN)
+ install $(BIN) $(PREFIX)/bin
+
+uninstall:
+ rm $(PREFIX)/bin/$(BIN)
+
clean:
- rm -f histo $(OBJ)
+ rm -f $(BIN) $(OBJ)
-.PHONY: clean
+.PHONY: clean install uninstall

0 comments on commit 209084c

Please sign in to comment.