summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorthebenraskin2020-01-11 11:19:49 -0500
committerQuentin Carbonneaux2021-03-02 08:45:51 +0100
commit490f194d9146d3c41ea804047a539fda2f025800 (patch)
tree3c7d8bf641e8676fae3786f046fbcc2e8cda7f3b
parentb9c8db79bf4902329e427dfae03e537f128df4c4 (diff)
install/uninstall targets
-rw-r--r--Makefile10
1 files changed, 10 insertions, 0 deletions
diff --git a/Makefile b/Makefile
index 6bc9835..1db2305 100644
--- a/Makefile
+++ b/Makefile
@@ -3,8 +3,18 @@ BIN = irc
CFLAGS = -std=c99 -Os -D_POSIX_C_SOURCE=201112 -D_GNU_SOURCE -D_XOPEN_CURSES -D_XOPEN_SOURCE_EXTENDED=1 -D_DEFAULT_SOURCE -D_BSD_SOURCE
LDFLAGS = -lncursesw -lssl -lcrypto
+PREFIX=/usr/local
+
all: ${BIN}
+install: ${BIN}
+ mkdir -p ${PREFIX}/bin
+ cp -f ${BIN} ${PREFIX}/bin
+ chmod 755 ${PREFIX}/bin/${BIN}
+
+uninstall:
+ rm -f ${PREFIX}/bin/${BIN}
+
clean:
rm -f ${BIN} *.o