From 95ed5c3800a87ddf9b0ec3958eaaa1a969306293 Mon Sep 17 00:00:00 2001 From: Russ Cox Date: Thu, 15 Apr 2021 23:05:49 -0400 Subject: internal/buildcfg: move build configuration out of cmd/internal/objabi The go/build package needs access to this configuration, so move it into a new package available to the standard library. Change-Id: I868a94148b52350c76116451f4ad9191246adcff Reviewed-on: https://go-review.googlesource.com/c/go/+/310731 Trust: Russ Cox Run-TryBot: Russ Cox Reviewed-by: Austin Clements Reviewed-by: Jay Conrod --- src/cmd/compile/internal/staticdata/data.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/cmd/compile/internal/staticdata/data.go') diff --git a/src/cmd/compile/internal/staticdata/data.go b/src/cmd/compile/internal/staticdata/data.go index 7ca05d3bf4..b5206c2442 100644 --- a/src/cmd/compile/internal/staticdata/data.go +++ b/src/cmd/compile/internal/staticdata/data.go @@ -8,6 +8,7 @@ import ( "crypto/sha256" "fmt" "go/constant" + "internal/buildcfg" "io" "io/ioutil" "os" @@ -269,7 +270,7 @@ func NeedFuncSym(fn *ir.Func) { // funcsymsmu, like in FuncSym. base.Fatalf("NeedFuncSym must be called in serial") } - if fn.ABI != obj.ABIInternal && objabi.Experiment.RegabiWrappers { + if fn.ABI != obj.ABIInternal && buildcfg.Experiment.RegabiWrappers { // Function values must always reference ABIInternal // entry points, so it doesn't make sense to create a // funcsym for other ABIs. -- cgit v1.3