diff --git a/Makefile b/Makefile index dfad1d3d..0728dd86 100644 --- a/Makefile +++ b/Makefile @@ -6,9 +6,14 @@ MAKEFLAGS += --warn-undefined-variables MAKEFLAGS += --no-builtin-rules TESTJOBS := 4 OS:=$(shell uname -s) +RELEASEFLAGS := ifeq ($(OS),Linux) TESTJOBS:=$(shell nproc) + RELEASEFLAGS=--target x86_64-unknown-linux-musl +endif +ifeq ($(OS),FreeBSD) + TESTJOBS:=$(shell sysctl -n hw.ncpu) endif ifeq ($(origin .RECIPEPREFIX), undefined) @@ -22,7 +27,7 @@ build: .PHONY: release release: -> cargo build --release --target x86_64-unknown-linux-musl +> cargo build --release $(RELEASEFLAGS) .PHONY: clean clean: