1
0
mirror of https://git.yoctoproject.org/poky synced 2026-06-01 13:09:50 +00:00

go: fix linking issues for nativesdk builds

Switch to using an external linker for nativesdk
go, go-runtime, and go package builds, which works
more reliably when building 32-bit SDKs.

(From OE-Core rev: f76779f7ef6636355a5aa5741a736f5234a67fdb)

Signed-off-by: Matt Madison <matt@madison.systems>
Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
Matt Madison
2017-09-14 16:22:28 -03:00
committed by Richard Purdie
parent 82ba908d86
commit 975246ffe6
3 changed files with 11 additions and 1 deletions
+5
View File
@@ -45,6 +45,11 @@ do_install() {
done
}
# Remove test binaries that cannot be relocated
do_install_append_class-nativesdk() {
rm -rf ${D}${libdir}/go/src/runtime/pprof/testdata
}
# These testdata directories aren't needed for builds and contain binaries
# that can cause errors in sysroot_strip(), so just remove them.
sysroot_stage_all_append() {
+3
View File
@@ -14,6 +14,9 @@ export CC_FOR_TARGET = "${CC}"
export CXX_FOR_TARGET = "${CXX}"
export GO_TARGET_INSTALL = "cmd"
export GO_FLAGS = "-a"
GO_LDFLAGS = ""
GO_LDFLAGS_class-nativesdk = "-linkmode external"
export GO_LDFLAGS
do_configure[noexec] = "1"