]> code.ossystems Code Review - openembedded-core.git/commitdiff
go-runtime: remove unneeded nativesdk override, rename variable
authorMatt Madison <matt@madison.systems>
Sun, 4 Mar 2018 21:09:36 +0000 (13:09 -0800)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Tue, 6 Mar 2018 14:36:33 +0000 (06:36 -0800)
since GO_LDFLAGS is also used by the dist tool, and it's confusing
to use a variable with the same name (but not exported, so unused
by make.bash/dist).

Signed-off-by: Matt Madison <matt@madison.systems>
Signed-off-by: Ross Burton <ross.burton@intel.com>
meta/recipes-devtools/go/go-runtime.inc

index a79295df47e49d72d74a6e28ae0aab513f2a2d38..0041e8afab43eeefa1af19bea9aacb9c8d66e73b 100644 (file)
@@ -17,9 +17,7 @@ export CGO_CXXFLAGS = "${CXXFLAGS}"
 export CGO_LDFLAGS = "${LDFLAGS}"
 
 GO_EXTLDFLAGS ?= "${HOST_CC_ARCH}${TOOLCHAIN_OPTIONS} ${LDFLAGS}"
-GO_LINKMODE ?= ""
-GO_LINKMODE_class-nativesdk = "--linkmode=external"
-GO_LDFLAGS ?= '-ldflags="${GO_LINKMODE} -extldflags '${GO_EXTLDFLAGS}'"'
+GO_SHLIB_LDFLAGS ?= '-ldflags="--linkmode=external -extldflags '${GO_EXTLDFLAGS}'"'
 
 do_configure() {
        :
@@ -38,7 +36,7 @@ do_compile() {
        if [ -n "${GO_DYNLINK}" ]; then
                export GOTOOLDIR="${B}/pkg/tool/native_native"
                CC="$CC_FOR_${TARGET_GOOS}_${TARGET_GOARCH}" GOARCH="${TARGET_GOARCH}" GOOS="${TARGET_GOOS}" GOROOT=${B} \
-                       $GOTOOLDIR/go_bootstrap install -linkshared -buildmode=shared ${GO_LDFLAGS} std
+                       $GOTOOLDIR/go_bootstrap install -linkshared -buildmode=shared ${GO_SHLIB_LDFLAGS} std
        fi
        cd ${B}
 }