mirror of
https://github.com/void-linux/void-packages.git
synced 2025-06-07 15:43:49 +02:00
v2ray: build for go1.20
This commit is contained in:
parent
ebc2783566
commit
d90be61ab3
1 changed files with 3 additions and 7 deletions
|
@ -1,12 +1,13 @@
|
||||||
# Template file for 'v2ray'
|
# Template file for 'v2ray'
|
||||||
pkgname=v2ray
|
pkgname=v2ray
|
||||||
version=5.3.0
|
version=5.3.0
|
||||||
revision=3
|
revision=4
|
||||||
build_style=go
|
build_style=go
|
||||||
go_import_path="github.com/v2fly/v2ray-core/v5"
|
go_import_path="github.com/v2fly/v2ray-core/v5"
|
||||||
go_ldflags="-X github.com/v2fly/v2ray-core/v5.codename=$pkgname
|
go_ldflags="-X github.com/v2fly/v2ray-core/v5.codename=$pkgname
|
||||||
-X github.com/v2fly/v2ray-core/v5.version=$version
|
-X github.com/v2fly/v2ray-core/v5.version=$version
|
||||||
-X github.com/v2fly/v2ray-core/v5.build=$SOURCE_DATE_EPOCH -buildid="
|
-X github.com/v2fly/v2ray-core/v5.build=$SOURCE_DATE_EPOCH -buildid="
|
||||||
|
hostmakedepends="go1.20"
|
||||||
short_desc="Platform for building proxies to bypass network restrictions"
|
short_desc="Platform for building proxies to bypass network restrictions"
|
||||||
maintainer="ipkalm <ipkalm@outlook.com>"
|
maintainer="ipkalm <ipkalm@outlook.com>"
|
||||||
license="MIT"
|
license="MIT"
|
||||||
|
@ -17,15 +18,10 @@ conf_files="/etc/v2ray/config.json"
|
||||||
|
|
||||||
system_accounts="_v2ray"
|
system_accounts="_v2ray"
|
||||||
|
|
||||||
|
export GOTOOLCHAIN=go1.20
|
||||||
export GOFLAGS="-x -p=$XBPS_MAKEJOBS -buildmode=pie -trimpath"
|
export GOFLAGS="-x -p=$XBPS_MAKEJOBS -buildmode=pie -trimpath"
|
||||||
export CGO_ENABLED=0
|
export CGO_ENABLED=0
|
||||||
|
|
||||||
broken="GOTOOLCHAIN not supported"
|
|
||||||
|
|
||||||
pre_build() {
|
|
||||||
export GOTOOLCHAIN="go1.20.7"
|
|
||||||
}
|
|
||||||
|
|
||||||
do_build() {
|
do_build() {
|
||||||
go build -ldflags "${go_ldflags}" -o "${GOPATH}/bin/v2ray" ./main
|
go build -ldflags "${go_ldflags}" -o "${GOPATH}/bin/v2ray" ./main
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue