We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent a51daac commit 811167eCopy full SHA for 811167e
src/cmd/link/internal/ld/lib.go
@@ -1343,8 +1343,6 @@ func (ctxt *Link) hostlink() {
1343
if ctxt.HeadType == objabi.Hdarwin {
1344
argv = append(argv, "-dynamiclib")
1345
} else {
1346
- // ELF.
1347
- argv = append(argv, "-Wl,-Bsymbolic")
1348
if ctxt.UseRelro() {
1349
argv = append(argv, "-Wl,-z,relro")
1350
}
@@ -1357,6 +1355,8 @@ func (ctxt *Link) hostlink() {
1357
1355
// Pass -z nodelete to mark the shared library as
1358
1356
// non-closeable: a dlclose will do nothing.
1359
argv = append(argv, "-Wl,-z,nodelete")
+ // Only pass Bsymbolic on non-Windows.
+ argv = append(argv, "-Wl,-Bsymbolic")
1360
1361
1362
case BuildModeShared:
0 commit comments