mirror of
https://github.com/golang/go.git
synced 2025-12-08 06:10:04 +00:00
cmd/internal/ld, cmd/dist: support -buildmode=c-archive on linux
Change-Id: I8c97751a79b57197428b0f0b66fc9575708a2eb0 Reviewed-on: https://go-review.googlesource.com/8979 Run-TryBot: Ian Lance Taylor <iant@golang.org> Reviewed-by: David Crawshaw <crawshaw@golang.org>
This commit is contained in:
parent
c1c667542c
commit
449969a4ac
2 changed files with 24 additions and 3 deletions
|
|
@ -288,7 +288,9 @@ func (mode *BuildMode) Set(s string) error {
|
|||
case "exe":
|
||||
*mode = BuildmodeExe
|
||||
case "c-archive":
|
||||
if goos != "darwin" {
|
||||
switch goos {
|
||||
case "darwin", "linux":
|
||||
default:
|
||||
return badmode()
|
||||
}
|
||||
*mode = BuildmodeCArchive
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue