aports/main/go-bootstrap/no-pic.patch
Sören Tempel bcfbb50807 main/go-boostrap: new aport
This is a more minimal version of the main/go aport. It is only supposed
to be used for bootstrapping go1.5 and to clarify this point it is called
go-bootstrap instead of go1.4.

This package doesn't ship a tools or cross subpackage anymore because
doing so would increase the amount of redundant 'code' in this APKBUILD
and neither tools nor cross compilers are needed for bootstrapping
go1.5.
2015-08-28 11:11:21 +02:00

15 lines
349 B
Diff

--- a/src/cmd/ld/lib.c
+++ b/src/cmd/ld/lib.c
@@ -786,6 +786,11 @@ hostlink(void)
p = strchr(p + 1, ' ');
}
+ // The Go linker does not currently support building objects that
+ // may be linked into a PIE. See:
+ // https://code.google.com/p/go/issues/detail?id=6940
+ argv[argc++] = "-fno-PIC";
+
argv[argc] = nil;
quotefmtinstall();