Commit 99d7121
cmd/link: add more clang driver flags when testing flag
This changes does 2 things:
- Move `-L` to `prefixesToKeep` since it allows providing a custom
default libs search path.
- Allow various flags that impact the behaviour of the clang driver.
The latter allows for LLVM only toolchains to be compatible with
linkerFlagSupported checks.
The end goal of this PR is to allow fully hermetic toolchains,
especially pure LLVM ones, to be used to cross-compile CGO.
Fixes golang#76825
Change-Id: I2311c9566ce9c7e8f6b325258af58eb333663cf0
GitHub-Last-Rev: 74342aa
GitHub-Pull-Request: golang#76858
Reviewed-on: https://go-review.googlesource.com/c/go/+/730561
Auto-Submit: Ian Lance Taylor <iant@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@google.com>
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
Reviewed-by: Michael Pratt <mpratt@google.com>
Reviewed-by: Ian Lance Taylor <iant@golang.org>1 parent b8bccb9 commit 99d7121
1 file changed
+18
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2208 | 2208 | | |
2209 | 2209 | | |
2210 | 2210 | | |
2211 | | - | |
2212 | 2211 | | |
2213 | 2212 | | |
2214 | 2213 | | |
2215 | 2214 | | |
2216 | 2215 | | |
2217 | 2216 | | |
| 2217 | + | |
| 2218 | + | |
2218 | 2219 | | |
2219 | 2220 | | |
2220 | 2221 | | |
2221 | 2222 | | |
2222 | 2223 | | |
| 2224 | + | |
| 2225 | + | |
| 2226 | + | |
| 2227 | + | |
| 2228 | + | |
| 2229 | + | |
| 2230 | + | |
2223 | 2231 | | |
2224 | 2232 | | |
| 2233 | + | |
| 2234 | + | |
2225 | 2235 | | |
2226 | 2236 | | |
2227 | 2237 | | |
| |||
2231 | 2241 | | |
2232 | 2242 | | |
2233 | 2243 | | |
| 2244 | + | |
| 2245 | + | |
| 2246 | + | |
| 2247 | + | |
| 2248 | + | |
| 2249 | + | |
| 2250 | + | |
2234 | 2251 | | |
2235 | 2252 | | |
2236 | 2253 | | |
| |||
0 commit comments