1
0
mirror of https://github.com/golang/go synced 2024-11-19 15:44:44 -07:00

cmd/dist: correct default C++ compiler when using gcc

Fixes #22609

Change-Id: Ic948345e7d1623a7defee6a6493eb81fe7393111
Reviewed-on: https://go-review.googlesource.com/76396
Run-TryBot: Ian Lance Taylor <iant@golang.org>
Reviewed-by: David Crawshaw <crawshaw@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
This commit is contained in:
Ian Lance Taylor 2017-11-07 13:56:05 -08:00
parent 0c0aed3c9f
commit e4a380868d

View File

@ -171,12 +171,12 @@ func xinit() {
gogcflags = os.Getenv("BOOT_GO_GCFLAGS")
cc := "gcc"
cc, cxx := "gcc", "g++"
if defaultclang {
cc = "clang"
cc, cxx = "clang", "clang++"
}
defaultcc = compilerEnv("CC", cc)
defaultcxx = compilerEnv("CXX", cc+"++")
defaultcxx = compilerEnv("CXX", cxx)
defaultcflags = os.Getenv("CFLAGS")
defaultldflags = os.Getenv("LDFLAGS")