mirror of
https://github.com/golang/go
synced 2024-11-05 18:36:08 +00:00
test/run: make GO_GCFLAGS mean same thing it does during make.bash
-gcflags=-flag means apply the flags only to the package named on the command line (the main package, for these tests). -gcflags=all=-flag means apply the flags to everything in the build, including the standard library. cmd/dist uses -gcflags=all=$GO_GCFLAGS, so test/run should do the same, as the comment already explains, to avoid rebuilding the entire standard library without the flags during test/run's builds. We changed the scope of the flags without a pattern a few releases ago and missed this one. Change-Id: I039e60ca619d39e5b502261d4a73e1afc7e3f9fc Reviewed-on: https://go-review.googlesource.com/c/go/+/213827 Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
This commit is contained in:
parent
b5c66de089
commit
7dbf12573f
1 changed files with 1 additions and 1 deletions
|
@ -459,7 +459,7 @@ func init() { checkShouldTest() }
|
|||
// or else the commands will rebuild any needed packages (like runtime)
|
||||
// over and over.
|
||||
func goGcflags() string {
|
||||
return "-gcflags=" + os.Getenv("GO_GCFLAGS")
|
||||
return "-gcflags=all=" + os.Getenv("GO_GCFLAGS")
|
||||
}
|
||||
|
||||
// run runs a test.
|
||||
|
|
Loading…
Reference in a new issue