-
Notifications
You must be signed in to change notification settings - Fork 18k
cmd/link: -buildmode=c-shared exports many functions, not just //export functions [1.15 backport] #43591
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Filed in case fix for #40795 depends on this. |
We've discussed this in a release meeting and it didn't seem like this is needed for #43592. CC @ianlancetaylor, @jeremyfaller. @networkimprov If you still think that CL 262797 (fix for #30674) should be backported, please provide a rationale as described in the third paragraph of https://golang.org/wiki/MinorReleases. It seems to be about buildmode=c-shared, which doesn't match the current backport rationale. |
e463c28 adds a hardcoded dummy variable tagged with What 6f7b553 does is add the Backporting e463c28 without either backporting 6f7b553 or setting again |
FYI @alexbrainman @zx2c4 |
Change https://golang.org/cl/300693 mentions this issue: |
Change https://golang.org/cl/300694 mentions this issue: |
Should https://golang.org/cl/300692 reference this issue? |
I'm referring to #40795 which this is the backport for. |
Closed by merging 5055314 to release-branch.go1.15. |
…ws buildmode=c-shared Disable default symbol auto-export behaviour by marking exported function with the __declspec(dllexport) attribute. Old behaviour can still be used by setting -extldflags=-Wl,--export-all-symbols. See https://sourceware.org/binutils/docs/ld/WIN32.html for more info. This change cuts 50kb of a "hello world" dll. Updates #6853. Updates #30674. Fixes #43591. Change-Id: I9c7fb09c677cc760f24d0f7d199740ae73981413 Reviewed-on: https://go-review.googlesource.com/c/go/+/262797 Run-TryBot: Ian Lance Taylor <[email protected]> TryBot-Result: Go Bot <[email protected]> Reviewed-by: Ian Lance Taylor <[email protected]> Reviewed-by: Alex Brainman <[email protected]> Trust: Alex Brainman <[email protected]> Reviewed-on: https://go-review.googlesource.com/c/go/+/300693 Trust: Dmitri Shuralyov <[email protected]> Run-TryBot: Dmitri Shuralyov <[email protected]> Reviewed-by: David Chase <[email protected]>
This comment has been minimized.
This comment has been minimized.
…rt header The cgo header has an unnecessary space in the exported function definition on non-windows goos. This was introduced in go1.16 so it would be good to fix it before release. Example: // Current behavior, notice there is an unecessary space // between extern and void extern void Foo(); // With this CL extern void Foo(); Updates #43591. Change-Id: Ic2c21f8d806fe35a7be7183dbfe35ac605b6e4f6 Reviewed-on: https://go-review.googlesource.com/c/go/+/283892 Reviewed-by: Ian Lance Taylor <[email protected]> Trust: Katie Hockman <[email protected]> Reviewed-on: https://go-review.googlesource.com/c/go/+/300694 Trust: Dmitri Shuralyov <[email protected]> Trust: Emmanuel Odeke <[email protected]> Run-TryBot: Dmitri Shuralyov <[email protected]> TryBot-Result: Go Bot <[email protected]> Reviewed-by: David Chase <[email protected]>
@networkimprov requested issue #30674 (fixed by 6f7b553 in Go 1.16) to be considered for backport to the next 1.15 minor release.
The text was updated successfully, but these errors were encountered: