mirror of
https://github.com/tinygo-org/tinygo.git
synced 2026-08-12 23:13:40 +00:00
compiler: add support for CGO_ENABLED environment variable
This commit is contained in:
committed by
Ron Evans
parent
9a69c6bcca
commit
1a32a68674
@@ -193,7 +193,7 @@ func (c *Compiler) Compile(mainPath string) []error {
|
||||
GOOS: c.GOOS(),
|
||||
GOROOT: goenv.Get("GOROOT"),
|
||||
GOPATH: goenv.Get("GOPATH"),
|
||||
CgoEnabled: true,
|
||||
CgoEnabled: c.CgoEnabled(),
|
||||
UseAllFiles: false,
|
||||
Compiler: "gc", // must be one of the recognized compilers
|
||||
BuildTags: c.BuildTags(),
|
||||
@@ -203,7 +203,7 @@ func (c *Compiler) Compile(mainPath string) []error {
|
||||
GOOS: c.GOOS(),
|
||||
GOROOT: goenv.Get("TINYGOROOT"),
|
||||
GOPATH: overlayGopath,
|
||||
CgoEnabled: true,
|
||||
CgoEnabled: c.CgoEnabled(),
|
||||
UseAllFiles: false,
|
||||
Compiler: "gc", // must be one of the recognized compilers
|
||||
BuildTags: c.BuildTags(),
|
||||
|
||||
Reference in New Issue
Block a user