mirror of
https://github.com/XTLS/Xray-core.git
synced 2025-06-15 15:58:41 +00:00
Makefile: export GOARCH, GOOS
This commit is contained in:
parent
0c61752829
commit
befa7b8138
1 changed files with 10 additions and 1 deletions
9
Makefile
9
Makefile
|
@ -2,6 +2,15 @@ NAME = xray
|
||||||
|
|
||||||
VERSION=$(shell git describe --always --dirty)
|
VERSION=$(shell git describe --always --dirty)
|
||||||
|
|
||||||
|
export GOARCH ?=
|
||||||
|
export GOOS ?=
|
||||||
|
|
||||||
|
ifdef GOARCH
|
||||||
|
ifeq ($(GOOS),darwin)
|
||||||
|
NAME:=$(NAME)-$(GOARCH)
|
||||||
|
endif
|
||||||
|
endif
|
||||||
|
|
||||||
LDFLAGS = -X github.com/xtls/xray-core/core.build=$(VERSION) -s -w -buildid=
|
LDFLAGS = -X github.com/xtls/xray-core/core.build=$(VERSION) -s -w -buildid=
|
||||||
PARAMS = -trimpath -ldflags "$(LDFLAGS)" -v
|
PARAMS = -trimpath -ldflags "$(LDFLAGS)" -v
|
||||||
MAIN = ./main
|
MAIN = ./main
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue