aboutsummaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile10
1 files changed, 9 insertions, 1 deletions
diff --git a/Makefile b/Makefile
index 29e233f..02d1996 100644
--- a/Makefile
+++ b/Makefile
@@ -2,6 +2,8 @@ CC := gcc
CFLAGS :=
CFLAGS_EXTRA := -std=c99 -Wpedantic -Wall -Wextra
LDFLAGS :=
+PREFIX :=
+UTILS := true false basename
BIN := futiles
OBJS := $(patsubst %.c, %.o, $(wildcard src/*.c))
@@ -17,4 +19,10 @@ src/%.o: src/%.c
clean:
rm -f $(BIN) $(OBJS)
-.PHONY: clean
+install: $(BIN)
+ install -m 755 $(BIN) $(PREFIX)/bin/
+ for util in $(UTILS) ; do \
+ ln -sf futiles /usr/bin/$$util; \
+ done
+
+.PHONY: clean install