X-Git-Url: https://git.madduck.net/code/myrepos.git/blobdiff_plain/2ccb790eda1239207af9566efcf0a13d1139b682..bec1b0321b56410a91383b3e6d5efacff9cc14a9:/Makefile?ds=inline diff --git a/Makefile b/Makefile index ea439ec..3718e32 100644 --- a/Makefile +++ b/Makefile @@ -1,7 +1,32 @@ -build: +PREFIX:=/usr + +mans=mr.1 webcheckout.1 + +build: $(mans) + +mr.1: mr pod2man -c mr mr > mr.1 +webcheckout.1: webcheckout + pod2man -c webcheckout webcheckout > webcheckout.1 + test: - (echo "[]"; echo "checkout=") > mrconfig.tmp - ./mr -c mrconfig.tmp ed | grep -q "horse" + (echo "[.]"; echo "checkout=") > mrconfig.tmp + ./mr --trust-all -c mrconfig.tmp ed | grep -q "horse" rm -f mrconfig.tmp + +install: build + install -d ${DESTDIR}${PREFIX}/bin + install -d ${DESTDIR}${PREFIX}/share/man/man1 + install -d ${DESTDIR}${PREFIX}/share/mr + + install -m0755 mr ${DESTDIR}${PREFIX}/bin/ + install -m0755 webcheckout ${DESTDIR}${PREFIX}/bin/ + + install -m0644 mr.1 ${DESTDIR}${PREFIX}/share/man/man1/ + install -m0644 webcheckout.1 ${DESTDIR}${PREFIX}/share/man/man1/ + + install -m0644 lib/* ${DESTDIR}${PREFIX}/share/mr/ + +clean: + rm -f $(mans)