]> Cypherpunks repositories - gostls13.git/commit
cmd/link: don't pass all linker args when testing flag
authorIan Lance Taylor <iant@golang.org>
Fri, 7 Sep 2018 19:53:52 +0000 (12:53 -0700)
committerIan Lance Taylor <iant@golang.org>
Tue, 11 Sep 2018 20:28:15 +0000 (20:28 +0000)
commit023dbb188dda6aa49ccc41c8e38f2703700b3f5a
tree47b1a949c8e2f4e5b16d9dd4a6f737ed7c027904
parent1a1c45b32e987544d4c23f6df5108bf747d44c31
cmd/link: don't pass all linker args when testing flag

Some linker flags can actually be input files, which can cause
misleading errors when doing the trial link, which can cause the
linker to incorrectly decide that the flag is not supported, which can
cause the link to fail.

Fixes #27510
Updates #27110
Updates #27293

Change-Id: I70c1e913cee3c813e7b267bf779bcff26d4d194a
Reviewed-on: https://go-review.googlesource.com/134057
Run-TryBot: Ian Lance Taylor <iant@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Lynn Boger <laboger@linux.vnet.ibm.com>
Reviewed-by: Damien Neil <dneil@google.com>
src/cmd/link/internal/ld/lib.go
src/cmd/link/internal/ld/util.go