From 71218ef0d30820d3220fde2f7e4528661f57a736 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E4=B8=96=E7=95=8C?= Date: Mon, 13 Nov 2023 14:12:22 +0800 Subject: [PATCH] build: Unify build tags --- .goreleaser.yaml | 4 ++++ Dockerfile | 3 ++- Makefile | 2 +- 3 files changed, 7 insertions(+), 2 deletions(-) diff --git a/.goreleaser.yaml b/.goreleaser.yaml index 82eafe45..d425db91 100644 --- a/.goreleaser.yaml +++ b/.goreleaser.yaml @@ -19,6 +19,7 @@ builds: - with_ech - with_utls - with_reality_server + - with_acme - with_clash_api env: - CGO_ENABLED=0 @@ -55,6 +56,7 @@ builds: - with_ech - with_utls - with_reality_server + - with_acme - with_clash_api env: - CGO_ENABLED=0 @@ -83,6 +85,8 @@ builds: - with_wireguard - with_ech - with_utls + - with_reality_server + - with_acme - with_clash_api env: - CGO_ENABLED=1 diff --git a/Dockerfile b/Dockerfile index 5b80ff61..52adff51 100644 --- a/Dockerfile +++ b/Dockerfile @@ -12,7 +12,8 @@ RUN set -ex \ && apk add git build-base \ && export COMMIT=$(git rev-parse --short HEAD) \ && export VERSION=$(go run ./cmd/internal/read_tag) \ - && go build -v -trimpath -tags with_gvisor,with_quic,with_dhcp,with_wireguard,with_ech,with_utls,with_reality_server,with_clash_api,with_acme \ + && go build -v -trimpath -tags \ + "with_gvisor,with_quic,with_dhcp,with_wireguard,with_ech,with_utls,with_reality_server,with_acme,with_clash_api" \ -o /go/bin/sing-box \ -ldflags "-X \"github.com/sagernet/sing-box/constant.Version=$VERSION\" -s -w -buildid=" \ ./cmd/sing-box diff --git a/Makefile b/Makefile index 73b2d4ac..f8efc9cc 100644 --- a/Makefile +++ b/Makefile @@ -3,7 +3,7 @@ COMMIT = $(shell git rev-parse --short HEAD) TAGS_GO118 = with_gvisor,with_dhcp,with_wireguard,with_utls,with_reality_server,with_clash_api TAGS_GO120 = with_quic,with_ech TAGS ?= $(TAGS_GO118),$(TAGS_GO120) -TAGS_TEST ?= with_gvisor,with_quic,with_wireguard,with_grpc,with_ech,with_utls,with_reality_server,with_shadowsocksr +TAGS_TEST ?= with_gvisor,with_quic,with_wireguard,with_grpc,with_ech,with_utls,with_reality_server GOHOSTOS = $(shell go env GOHOSTOS) GOHOSTARCH = $(shell go env GOHOSTARCH)