Skip to content

Commit 558785a

Browse files
committed
cmd/compile: remove -installsuffix flag
Obsoleted by -importcfg. cmd/link has a similar flag, but it seems to still be needed at least for misc/cgo/testshared.TestGopathShlib. I can't immediately tell why (has something to do with finding .so files), but it doesn't appear to possibly affect cmd/compile. Updates #51225. Change-Id: I80c6aef860bd162c010ad4a1a4f532b400cf901c Reviewed-on: https://go-review.googlesource.com/c/go/+/415236 Reviewed-by: David Chase <[email protected]> Run-TryBot: Matthew Dempsky <[email protected]> Reviewed-by: Russ Cox <[email protected]> TryBot-Result: Gopher Robot <[email protected]>
1 parent 1355ea3 commit 558785a

File tree

4 files changed

+1
-10
lines changed

4 files changed

+1
-10
lines changed

src/cmd/compile/doc.go

-3
Original file line numberDiff line numberDiff line change
@@ -68,9 +68,6 @@ Flags:
6868
-importcfg file
6969
Read import configuration from file.
7070
In the file, set importmap, packagefile to specify import resolution.
71-
-installsuffix suffix
72-
Look for packages in $GOROOT/pkg/$GOOS_$GOARCH_suffix
73-
instead of $GOROOT/pkg/$GOOS_$GOARCH.
7471
-l
7572
Disable inlining.
7673
-lang version

src/cmd/compile/internal/base/flag.go

-1
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,6 @@ type CmdFlags struct {
100100
GenDwarfInl int "help:\"generate DWARF inline info records\"" // 0=disabled, 1=funcs, 2=funcs+formals/locals
101101
GoVersion string "help:\"required version of the runtime\""
102102
ImportCfg func(string) "help:\"read import configuration from `file`\""
103-
InstallSuffix string "help:\"set pkg directory `suffix`\""
104103
JSON string "help:\"version,file for JSON compiler/optimizer detail output\""
105104
Lang string "help:\"Go language version source code expects\""
106105
LinkObj string "help:\"write linker-specific object to `file`\""

src/cmd/compile/internal/noder/import.go

+1-3
Original file line numberDiff line numberDiff line change
@@ -102,9 +102,7 @@ func openPackage(path string) (*os.File, error) {
102102

103103
if buildcfg.GOROOT != "" {
104104
suffix := ""
105-
if base.Flag.InstallSuffix != "" {
106-
suffix = "_" + base.Flag.InstallSuffix
107-
} else if base.Flag.Race {
105+
if base.Flag.Race {
108106
suffix = "_race"
109107
} else if base.Flag.MSan {
110108
suffix = "_msan"

src/cmd/go/internal/work/gc.go

-3
Original file line numberDiff line numberDiff line change
@@ -128,9 +128,6 @@ func (gcToolchain) gc(b *Builder, a *Action, archive string, importcfg, embedcfg
128128
if extFiles == 0 {
129129
defaultGcFlags = append(defaultGcFlags, "-complete")
130130
}
131-
if cfg.BuildContext.InstallSuffix != "" {
132-
defaultGcFlags = append(defaultGcFlags, "-installsuffix", cfg.BuildContext.InstallSuffix)
133-
}
134131
if a.buildID != "" {
135132
defaultGcFlags = append(defaultGcFlags, "-buildid", a.buildID)
136133
}

0 commit comments

Comments
 (0)