Only build musl binaries on linux.
This commit is contained in:
parent
633d6e421f
commit
3a174dd41b
7
Makefile
7
Makefile
@ -6,9 +6,14 @@ MAKEFLAGS += --warn-undefined-variables
|
|||||||
MAKEFLAGS += --no-builtin-rules
|
MAKEFLAGS += --no-builtin-rules
|
||||||
TESTJOBS := 4
|
TESTJOBS := 4
|
||||||
OS:=$(shell uname -s)
|
OS:=$(shell uname -s)
|
||||||
|
RELEASEFLAGS :=
|
||||||
|
|
||||||
ifeq ($(OS),Linux)
|
ifeq ($(OS),Linux)
|
||||||
TESTJOBS:=$(shell nproc)
|
TESTJOBS:=$(shell nproc)
|
||||||
|
RELEASEFLAGS=--target x86_64-unknown-linux-musl
|
||||||
|
endif
|
||||||
|
ifeq ($(OS),FreeBSD)
|
||||||
|
TESTJOBS:=$(shell sysctl -n hw.ncpu)
|
||||||
endif
|
endif
|
||||||
|
|
||||||
ifeq ($(origin .RECIPEPREFIX), undefined)
|
ifeq ($(origin .RECIPEPREFIX), undefined)
|
||||||
@ -22,7 +27,7 @@ build:
|
|||||||
|
|
||||||
.PHONY: release
|
.PHONY: release
|
||||||
release:
|
release:
|
||||||
> cargo build --release --target x86_64-unknown-linux-musl
|
> cargo build --release $(RELEASEFLAGS)
|
||||||
|
|
||||||
.PHONY: clean
|
.PHONY: clean
|
||||||
clean:
|
clean:
|
||||||
|
Loading…
Reference in New Issue
Block a user