diff options
Diffstat (limited to 'meta/recipes-devtools/go')
-rw-r--r-- | meta/recipes-devtools/go/go-runtime.inc | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/meta/recipes-devtools/go/go-runtime.inc b/meta/recipes-devtools/go/go-runtime.inc index a79295df47..0041e8afab 100644 --- a/meta/recipes-devtools/go/go-runtime.inc +++ b/meta/recipes-devtools/go/go-runtime.inc | |||
@@ -17,9 +17,7 @@ export CGO_CXXFLAGS = "${CXXFLAGS}" | |||
17 | export CGO_LDFLAGS = "${LDFLAGS}" | 17 | export CGO_LDFLAGS = "${LDFLAGS}" |
18 | 18 | ||
19 | GO_EXTLDFLAGS ?= "${HOST_CC_ARCH}${TOOLCHAIN_OPTIONS} ${LDFLAGS}" | 19 | GO_EXTLDFLAGS ?= "${HOST_CC_ARCH}${TOOLCHAIN_OPTIONS} ${LDFLAGS}" |
20 | GO_LINKMODE ?= "" | 20 | GO_SHLIB_LDFLAGS ?= '-ldflags="--linkmode=external -extldflags '${GO_EXTLDFLAGS}'"' |
21 | GO_LINKMODE_class-nativesdk = "--linkmode=external" | ||
22 | GO_LDFLAGS ?= '-ldflags="${GO_LINKMODE} -extldflags '${GO_EXTLDFLAGS}'"' | ||
23 | 21 | ||
24 | do_configure() { | 22 | do_configure() { |
25 | : | 23 | : |
@@ -38,7 +36,7 @@ do_compile() { | |||
38 | if [ -n "${GO_DYNLINK}" ]; then | 36 | if [ -n "${GO_DYNLINK}" ]; then |
39 | export GOTOOLDIR="${B}/pkg/tool/native_native" | 37 | export GOTOOLDIR="${B}/pkg/tool/native_native" |
40 | CC="$CC_FOR_${TARGET_GOOS}_${TARGET_GOARCH}" GOARCH="${TARGET_GOARCH}" GOOS="${TARGET_GOOS}" GOROOT=${B} \ | 38 | CC="$CC_FOR_${TARGET_GOOS}_${TARGET_GOARCH}" GOARCH="${TARGET_GOARCH}" GOOS="${TARGET_GOOS}" GOROOT=${B} \ |
41 | $GOTOOLDIR/go_bootstrap install -linkshared -buildmode=shared ${GO_LDFLAGS} std | 39 | $GOTOOLDIR/go_bootstrap install -linkshared -buildmode=shared ${GO_SHLIB_LDFLAGS} std |
42 | fi | 40 | fi |
43 | cd ${B} | 41 | cd ${B} |
44 | } | 42 | } |