diff options
Diffstat (limited to 'Makefile')
-rw-r--r-- | Makefile | 24 |
1 files changed, 22 insertions, 2 deletions
@@ -1,6 +1,26 @@ PREFIX ?= /usr/local -MAN_PREFIX ?= ${PREFIX}/man +BIN_DEST ?= ${PREFIX}/bin +MAN_DEST ?= ${PREFIX}/man +CARGO ?= cargo +SCDOC ?= scdoc +RM ?= rm + +default: + @${CARGO} build +release: + @${CARGO} build --release --locked --all-features --target-dir=target manpage: - scdoc < man/rs.1.scd > man/rs.1 + @${SCDOC} < man/rs.1.scd > man/rs.1 +install: release manpage + install -Dm 755 -t "${BIN_DEST}" target/release/rs + install -Dm 555 -t "${MAN_DEST}" man/rs.1 + +run: + @${CARGO} run +fmt: + @${CARGO} fmt +clean: + @${RM} man/rs.1 + @${CARGO} clean |