mirror of
https://github.com/golang/go.git
synced 2026-06-27 03:11:23 +00:00
cmd/link: make -f flag actually ignore version mismatch
The linker's -f flag is documented as "ignore version mismatch", but it currently does not. Make it so. Change-Id: Ieb16acf35f75a2eb9d674bb3a1bd9fd01363867e Reviewed-on: https://go-review.googlesource.com/c/go/+/770680 LUCI-TryBot-Result: golang-scoped@luci-project-accounts.iam.gserviceaccount.com <golang-scoped@luci-project-accounts.iam.gserviceaccount.com> Reviewed-by: David Chase <drchase@google.com>
This commit is contained in:
parent
8191cd8868
commit
cbaecb2830
1 changed files with 1 additions and 1 deletions
|
|
@ -2512,7 +2512,7 @@ func ldobj(ctxt *Link, f *bio.Reader, lib *sym.Library, length int64, pn string,
|
|||
}
|
||||
|
||||
// First, check that the basic GOOS, GOARCH, and Version match.
|
||||
if line != wantHdr {
|
||||
if line != wantHdr && !*flagF {
|
||||
Errorf("%s: linked object header mismatch:\nhave %q\nwant %q\n", pn, line, wantHdr)
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue