mirror of https://github.com/golang/go.git
cmd/ld: make hostobj work on newer openbsd
Make hostobj work on OpenBSD 5.3/5.4/-current - these have PIE enabled by default and linking fails since the Go linker generates objects that are neither PIC nor PIE. Fixes #5067 R=golang-dev, rsc CC=golang-dev https://golang.org/cl/7572049
This commit is contained in:
parent
efd1d05023
commit
0eaabf6452
|
|
@ -574,6 +574,8 @@ hostlink(void)
|
|||
}
|
||||
if(HEADTYPE == Hdarwin)
|
||||
argv[argc++] = "-Wl,-no_pie,-pagezero_size,4000000";
|
||||
if(HEADTYPE == Hopenbsd)
|
||||
argv[argc++] = "-Wl,-nopie";
|
||||
|
||||
if(iself && AssumeGoldLinker)
|
||||
argv[argc++] = "-Wl,--rosegment";
|
||||
|
|
|
|||
Loading…
Reference in New Issue