1
0
mirror of https://git.yoctoproject.org/poky synced 2026-05-31 00:39:46 +00:00

go: Enable CGO and pie buildmode on rv64

go1.16 has added CGO support for riscv64 arch

(From OE-Core rev: 8e078238312948e8c7b09c66ba7a186512e995d3)

Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
Khem Raj
2021-02-23 20:13:19 -08:00
committed by Richard Purdie
parent cedb3aa817
commit b1eea8178a
3 changed files with 4 additions and 7 deletions
@@ -1,4 +1,3 @@
export CGO_ENABLED_riscv64 = ""
require go-${PV}.inc
require go-runtime.inc
+2 -3
View File
@@ -4,15 +4,14 @@ require go-target.inc
inherit linuxloader
export GOBUILDMODE=""
export CGO_ENABLED_riscv64 = ""
export GO_LDSO = "${@get_linuxloader(d)}"
export CC_FOR_TARGET = "gcc"
export CXX_FOR_TARGET = "g++"
# mips/rv64 doesn't support -buildmode=pie, so skip the QA checking for mips/riscv and its
# mips/rv64 doesn't support -buildmode=pie, so skip the QA checking for mips/riscv32 and its
# variants.
python() {
if 'mips' in d.getVar('TARGET_ARCH',True) or 'riscv' in d.getVar('TARGET_ARCH',True):
if 'mips' in d.getVar('TARGET_ARCH',True) or 'riscv32' in d.getVar('TARGET_ARCH',True):
d.appendVar('INSANE_SKIP_%s' % d.getVar('PN',True), " textrel")
}