mirror of
https://github.com/octoleo/syncthing.git
synced 2024-12-23 03:18:59 +00:00
Correctly set GOARM on ARM builds
This commit is contained in:
parent
c74509dd5f
commit
dda0390156
2
build.go
2
build.go
@ -158,6 +158,7 @@ func test(pkg string) {
|
||||
|
||||
func install(pkg string) {
|
||||
os.Setenv("GOBIN", "./bin")
|
||||
setBuildEnv()
|
||||
runPrint("godep", "go", "install", "-ldflags", ldflags(), pkg)
|
||||
}
|
||||
|
||||
@ -212,6 +213,7 @@ func setBuildEnv() {
|
||||
os.Setenv("GOOS", goos)
|
||||
if strings.HasPrefix(goarch, "arm") {
|
||||
os.Setenv("GOARCH", "arm")
|
||||
os.Setenv("GOARM", goarch[4:])
|
||||
} else {
|
||||
os.Setenv("GOARCH", goarch)
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user