summaryrefslogtreecommitdiffstats
path: root/meta
diff options
context:
space:
mode:
authorKhem Raj <raj.khem@gmail.com>2017-03-13 12:57:37 -0700
committerRichard Purdie <richard.purdie@linuxfoundation.org>2017-03-14 14:42:18 +0000
commit49c4fb941ebe8fca69402675d079149837104640 (patch)
tree57f63d14c13c6ef9f16a935009a4dc319bbaa48e /meta
parentc46c25dcfeb3509ead23cb297e7dc62e025ba8f4 (diff)
downloadpoky-49c4fb941ebe8fca69402675d079149837104640.tar.gz
go: add native recipes for 1.8
(From OE-Core rev: 13a5c3dac4b5b0ccb4c5dfebf79b468acd8e1983) Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta')
-rw-r--r--meta/recipes-devtools/go/go-bootstrap-native_1.4.bb3
-rw-r--r--meta/recipes-devtools/go/go-native.inc16
-rw-r--r--meta/recipes-devtools/go/go-native_1.8.bb (renamed from meta/recipes-devtools/go/go-native_1.4.bb)1
-rw-r--r--meta/recipes-devtools/go/go.inc4
4 files changed, 15 insertions, 9 deletions
diff --git a/meta/recipes-devtools/go/go-bootstrap-native_1.4.bb b/meta/recipes-devtools/go/go-bootstrap-native_1.4.bb
new file mode 100644
index 0000000000..3d4141e879
--- /dev/null
+++ b/meta/recipes-devtools/go/go-bootstrap-native_1.4.bb
@@ -0,0 +1,3 @@
1BOOTSTRAP = "1.4"
2require go-native.inc
3require go-${PV}.inc
diff --git a/meta/recipes-devtools/go/go-native.inc b/meta/recipes-devtools/go/go-native.inc
index 89bc63459d..c1ada5121a 100644
--- a/meta/recipes-devtools/go/go-native.inc
+++ b/meta/recipes-devtools/go/go-native.inc
@@ -1,8 +1,10 @@
1inherit native 1inherit native
2 2
3BOOTSTRAP ?= ""
3export GOOS = "${BUILD_GOOS}" 4export GOOS = "${BUILD_GOOS}"
4export GOARCH = "${BUILD_GOARCH}" 5export GOARCH = "${BUILD_GOARCH}"
5export GOROOT_FINAL = "${STAGING_LIBDIR_NATIVE}/go" 6export GOROOT_FINAL = "${STAGING_LIBDIR_NATIVE}/go${BOOTSTRAP}"
7export GOROOT_BOOTSTRAP = "${STAGING_LIBDIR_NATIVE}/go1.4"
6export CGO_ENABLED = "1" 8export CGO_ENABLED = "1"
7 9
8do_configure[noexec] = "1" 10do_configure[noexec] = "1"
@@ -31,18 +33,18 @@ END
31} 33}
32 34
33do_install() { 35do_install() {
34 install -d ${D}${libdir}/go 36 install -d ${D}${libdir}/go${BOOTSTRAP}
35 cp -a ${B}/pkg ${D}${libdir}/go/ 37 cp -a ${B}/pkg ${D}${libdir}/go${BOOTSTRAP}/
36 install -d ${D}${libdir}/go/src 38 install -d ${D}${libdir}/go${BOOTSTRAP}/src
37 (cd ${S}/src; for d in *; do \ 39 (cd ${S}/src; for d in *; do \
38 [ -d $d ] && cp -a ${S}/src/$d ${D}${libdir}/go/src/; \ 40 [ -d $d ] && cp -a ${S}/src/$d ${D}${libdir}/go${BOOTSTRAP}/src/; \
39 done) 41 done)
40 42
41 install -d ${D}${bindir} ${D}${libdir}/go/bin 43 install -d ${D}${bindir} ${D}${libdir}/go${BOOTSTRAP}/bin
42 for f in ${B}/bin/* 44 for f in ${B}/bin/*
43 do 45 do
44 base=`basename $f` 46 base=`basename $f`
45 install -m755 $f ${D}${libdir}/go/bin 47 install -m755 $f ${D}${libdir}/go${BOOTSTRAP}/bin
46 make_wrapper $base $base 48 make_wrapper $base $base
47 done 49 done
48} 50}
diff --git a/meta/recipes-devtools/go/go-native_1.4.bb b/meta/recipes-devtools/go/go-native_1.8.bb
index bbf3c0dd73..182fca27a0 100644
--- a/meta/recipes-devtools/go/go-native_1.4.bb
+++ b/meta/recipes-devtools/go/go-native_1.8.bb
@@ -1,2 +1,3 @@
1require ${PN}.inc 1require ${PN}.inc
2require go-${PV}.inc 2require go-${PV}.inc
3DEPENDS += "go-bootstrap-native"
diff --git a/meta/recipes-devtools/go/go.inc b/meta/recipes-devtools/go/go.inc
index 1c94fc9c34..0b0cbf19ad 100644
--- a/meta/recipes-devtools/go/go.inc
+++ b/meta/recipes-devtools/go/go.inc
@@ -1,6 +1,6 @@
1inherit goarch 1inherit goarch
2# libgcc is required for the target specific libraries to build properly 2# libgcc is required for the target specific libraries to build properly
3DEPENDS += " go-native libgcc" 3DEPENDS += "go-bootstrap-native libgcc"
4# Prevent runstrip from running because you get errors when the host arch != target arch 4# Prevent runstrip from running because you get errors when the host arch != target arch
5INHIBIT_PACKAGE_STRIP = "1" 5INHIBIT_PACKAGE_STRIP = "1"
6INHIBIT_SYSROOT_STRIP = "1" 6INHIBIT_SYSROOT_STRIP = "1"
@@ -15,7 +15,7 @@ export GOHOSTARCH = "${BUILD_GOARCH}"
15export GOOS = "${TARGET_GOOS}" 15export GOOS = "${TARGET_GOOS}"
16export GOARCH = "${TARGET_GOARCH}" 16export GOARCH = "${TARGET_GOARCH}"
17export GOARM = "${TARGET_GOARM}" 17export GOARM = "${TARGET_GOARM}"
18export GOROOT_BOOTSTRAP = "${STAGING_LIBDIR_NATIVE}/go" 18export GOROOT_BOOTSTRAP = "${STAGING_LIBDIR_NATIVE}/go1.4"
19export GOROOT_FINAL = "${libdir}/go" 19export GOROOT_FINAL = "${libdir}/go"
20export CGO_ENABLED = "1" 20export CGO_ENABLED = "1"
21export CC_FOR_TARGET = "${CC}" 21export CC_FOR_TARGET = "${CC}"