File tree Expand file tree Collapse file tree 1 file changed +4
-5
lines changed Expand file tree Collapse file tree 1 file changed +4
-5
lines changed Original file line number Diff line number Diff line change @@ -453,9 +453,9 @@ func (ctxt *Link) loadlib() {
453
453
Linkmode = LinkExternal
454
454
}
455
455
456
- // Force external linking for PIE executables, as
457
- // internal linking does not support TLS_IE .
458
- if Buildmode == BuildmodePIE {
456
+ // Force external linking for PIE binaries on systems
457
+ // that do not support internal PIE linking .
458
+ if Buildmode == BuildmodePIE && ( obj . GOOS != "linux" || SysArch . Family != sys . AMD64 ) {
459
459
Linkmode = LinkExternal
460
460
}
461
461
@@ -636,8 +636,7 @@ func (ctxt *Link) loadlib() {
636
636
// binaries, so leave it enabled on OS X (Mach-O) binaries.
637
637
// Also leave it enabled on Solaris which doesn't support
638
638
// statically linked binaries.
639
- switch Buildmode {
640
- case BuildmodeExe , BuildmodePIE :
639
+ if Buildmode == BuildmodeExe {
641
640
if havedynamic == 0 && Headtype != obj .Hdarwin && Headtype != obj .Hsolaris {
642
641
* FlagD = true
643
642
}
You can’t perform that action at this time.
0 commit comments