mirror of https://github.com/v2ray/v2ray-core
Fix build break
parent
7460f61f39
commit
c096ee0a81
|
@ -94,7 +94,7 @@ jobs:
|
||||||
displayName: 'Install Bazel'
|
displayName: 'Install Bazel'
|
||||||
- script: |
|
- script: |
|
||||||
cd ./src/v2ray.com/core
|
cd ./src/v2ray.com/core
|
||||||
$HOME/bin/bazel build --action_env=GOPATH=$GOPATH --action_env=PATH=$PATH --action_env=GPG_PASS=${SIGN_KEY_PASS} //release:all
|
$HOME/bin/bazel build --action_env=GOPATH=$GOPATH --action_env=PATH=$PATH --action_env=GPG_PASS=${SIGN_KEY_PASS} --action_env=SPWD=$PWD //release:all
|
||||||
workingDirectory: '$(GOPATH)'
|
workingDirectory: '$(GOPATH)'
|
||||||
displayName: 'Build Binaries'
|
displayName: 'Build Binaries'
|
||||||
- script: |
|
- script: |
|
||||||
|
|
4
core.go
4
core.go
|
@ -17,9 +17,9 @@ import (
|
||||||
)
|
)
|
||||||
|
|
||||||
const (
|
const (
|
||||||
version = "4.19"
|
version = "4.20"
|
||||||
build = "Custom"
|
build = "Custom"
|
||||||
codename = "Po"
|
codename = "Let's Fly"
|
||||||
intro = "A unified platform for anti-censorship."
|
intro = "A unified platform for anti-censorship."
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -28,8 +28,8 @@ def _go_command(ctx):
|
||||||
"CGO_ENABLED=0",
|
"CGO_ENABLED=0",
|
||||||
"GOOS="+ctx.attr.os,
|
"GOOS="+ctx.attr.os,
|
||||||
"GOARCH="+ctx.attr.arch,
|
"GOARCH="+ctx.attr.arch,
|
||||||
"GOROOT_FINAL=/go",
|
#"GOROOT_FINAL=/go",
|
||||||
"GOCACHE=@D",
|
"GO111MODULE=on",
|
||||||
]
|
]
|
||||||
|
|
||||||
if ctx.attr.mips: # https://github.com/golang/go/issues/27260
|
if ctx.attr.mips: # https://github.com/golang/go/issues/27260
|
||||||
|
@ -40,7 +40,9 @@ def _go_command(ctx):
|
||||||
if ctx.attr.arm:
|
if ctx.attr.arm:
|
||||||
envs+=["GOARM="+ctx.attr.arm]
|
envs+=["GOARM="+ctx.attr.arm]
|
||||||
|
|
||||||
command = " ".join(envs) + " " + command
|
switchToPwd="cd ${SPWD} && "
|
||||||
|
|
||||||
|
command = switchToPwd + " ".join(envs) + " " + command
|
||||||
|
|
||||||
ctx.actions.run_shell(
|
ctx.actions.run_shell(
|
||||||
outputs = [output_file],
|
outputs = [output_file],
|
||||||
|
|
Loading…
Reference in New Issue