PREFIX ?= /usr/local BIN_DEST ?= ${PREFIX}/bin MAN_DEST ?= ${PREFIX}/man CARGO ?= cargo SCDOC ?= scdoc RM ?= rm man_targets = man/rs.1 .PHONY: default default: @${CARGO} build man/rs.%: @${SCDOC} < $@.scd > $@ target/release/rs: @echo Building default target @${CARGO} build --release --locked --all-features --target-dir=target target/%/release/rs: @echo Building target $* @${CARGO} build --target $* --release --locked --all-features --target-dir=target musl: target/x86_64-unknown-linux-musl/release/rs strip target/x86_64-unknown-linux-musl/release/rs @${CARGO} run --target x86_64-unknown-linux-musl --release test-musl: @${CARGO} test --target x86_64-unknown-linux-musl --release --locked --all-features --target-dir=target