Skip to contentSkip to conversation

go1.10 update and misc improvements

PATCH In review Matt Madison 3 participants 22 messages Mar 4, 2018 – Jun 28, 2019

lore
Share & tools
lore
#0 lore raw

v5 cover go1.10 update and misc improvements

New in v5:
* Fixed build problem introduced in v3 when *not* using security flags
* Added in a backported go source patch fixing a an aarch64 issue (via Khem)
* Updated the recipe changes to keep the 1.9 recipes in place
* Added a GOVERSION setting to tcmode-default.inc to allow choosing 1.9 instead of 1.10
* Collapsed the '-v' removal patch, since it was really a fixup for an earlier patch in the series.

New in v4:
* updated the go source patch to protect GOROOT to defer generating an error
until a build action would try to update something in GOROOT
* updated go.bbclass to compile for both static and dynamic linking, similar to go-runtime
* fixed missing sign-off

New in v3:
* reduced one of the go source patches, eliminating an unneeded change (thanks Otavio)
* Added bbclass and recipe patches to
handle SECURITY_CFLAGS settings if
they're enabled
* Added go-runtime-staticdev to target-side SDK, needed for go static builds (fixes test case failure in oe-selftest)
* two more minor cleanups

New in v2:
* Fixed Upstream-Status line in go patches
* Added GOTMPDIR to do_configure[dirs]

Updates to the go recipes and bbclasses for go1.10, which moves the bulk of the toolchain bootstrap and build out of the 'make.bash' script and to the 'dist' tool. This required a rework of the patches to the go source.

go1.10 introduces significant changes to the go build tool as well, requiring some further patches to make it work for OE builds.

See https://golang.org/doc/go1.10 for a complete list of new features and changes.

Following the update are some cleanup/improvement patches.

Matt Madison (13):
go: update go 1.9 -> go 1.10
go: set GOMIPS envrionment variable
go.bbclass: rename GO_TMPDIR -> GOTMPDIR
go.bbclass: remove debug-related commands
go.bbclass: don't stage test data with sources go.bbclass: ptest cleanup and improvements goarch.bbclass: disable shared runtime for nativesdk builds
go: move common settings to go-common.inc
go.bbclass, goarch.bbclass: update SECURITY_CFLAGS
go: disable PIE CFLAGS for nativesdk and cross-canadian builds packagegroup-go-sdk-target: add go-runtime-staticdev
go-runtime: remove unneeded nativesdk override, rename variable tcmode-default.inc: add settings for go

 meta/classes/go.bbclass                            | 114 +++++----
 meta/classes/goarch.bbclass                        |  14 ++
 meta/conf/distro/include/tcmode-default.inc        |  10 +
 .../packagegroups/packagegroup-go-sdk-target.bb    |   1 +
 meta/recipes-devtools/go/go-1.10.inc               |  22 ++
 ...1-allow-CC-and-CXX-to-have-multiple-words.patch |  33 +++
 ...-content-based-hash-generation-less-pedan.patch | 220 ++++++++++++++++
 ...OLDIR-to-be-overridden-in-the-environment.patch |  64 +++++
 .../0004-ld-add-soname-to-shareable-objects.patch  |  47 ++++
 ...verride-CC-when-building-dist-and-go_boot.patch |  40 +++
 ...-cmd-dist-separate-host-and-target-builds.patch | 277 +++++++++++++++++++++
 ...07-cmd-go-make-GOROOT-precious-by-default.patch | 108 ++++++++
 ...l-obj-arm64-fix-branch-too-far-with-TBZ-l.patch |  58 +++++
 ...ld-replace-glibc-dynamic-linker-with-musl.patch | 130 ++++++++++
 meta/recipes-devtools/go/go-common.inc             |   6 +
 meta/recipes-devtools/go/go-cross-canadian.inc     |  26 +-
 meta/recipes-devtools/go/go-cross-canadian_1.10.bb |   2 +
 meta/recipes-devtools/go/go-cross-canadian_1.9.bb  |  10 +
 meta/recipes-devtools/go/go-cross.inc              |  56 ++---
 meta/recipes-devtools/go/go-cross_1.10.bb          |   2 +
 meta/recipes-devtools/go/go-cross_1.9.bb           |   8 +
 meta/recipes-devtools/go/go-crosssdk.inc           |  14 +-
 meta/recipes-devtools/go/go-crosssdk_1.10.bb       |   2 +
 meta/recipes-devtools/go/go-crosssdk_1.9.bb        |   9 +
 meta/recipes-devtools/go/go-native.inc             |  25 +-
 meta/recipes-devtools/go/go-native_1.10.bb         |   2 +
 meta/recipes-devtools/go/go-native_1.9.bb          |   2 +
 meta/recipes-devtools/go/go-runtime.inc            |  56 ++---
 meta/recipes-devtools/go/go-runtime_1.10.bb        |   2 +
 meta/recipes-devtools/go/go-runtime_1.9.bb         |  21 ++
 meta/recipes-devtools/go/go-target.inc             |  24 +-
 meta/recipes-devtools/go/go_1.10.bb                |   2 +
 meta/recipes-devtools/go/go_1.9.bb                 |  15 ++
 33 files changed, 1260 insertions(+), 162 deletions(-)
 create mode 100644 meta/recipes-devtools/go/go-1.10.inc
 create mode 100644 meta/recipes-devtools/go/go-1.10/0001-allow-CC-and-CXX-to-have-multiple-words.patch
 create mode 100644 meta/recipes-devtools/go/go-1.10/0002-cmd-go-make-content-based-hash-generation-less-pedan.patch
 create mode 100644 meta/recipes-devtools/go/go-1.10/0003-allow-GOTOOLDIR-to-be-overridden-in-the-environment.patch
 create mode 100644 meta/recipes-devtools/go/go-1.10/0004-ld-add-soname-to-shareable-objects.patch
 create mode 100644 meta/recipes-devtools/go/go-1.10/0005-make.bash-override-CC-when-building-dist-and-go_boot.patch
 create mode 100644 meta/recipes-devtools/go/go-1.10/0006-cmd-dist-separate-host-and-target-builds.patch
 create mode 100644 meta/recipes-devtools/go/go-1.10/0007-cmd-go-make-GOROOT-precious-by-default.patch
 create mode 100644 meta/recipes-devtools/go/go-1.10/0008-cmd-internal-obj-arm64-fix-branch-too-far-with-TBZ-l.patch
 create mode 100644 meta/recipes-devtools/go/go-1.10/0009-ld-replace-glibc-dynamic-linker-with-musl.patch
 create mode 100644 meta/recipes-devtools/go/go-cross-canadian_1.10.bb
 create mode 100644 meta/recipes-devtools/go/go-cross_1.10.bb
 create mode 100644 meta/recipes-devtools/go/go-crosssdk_1.10.bb
 create mode 100644 meta/recipes-devtools/go/go-native_1.10.bb
 create mode 100644 meta/recipes-devtools/go/go-runtime_1.10.bb
 create mode 100644 meta/recipes-devtools/go/go_1.10.bb
Signature · 1 line
2.14.1
#1 lore raw

PATCH v5 1/13 go: update go 1.9 -> go 1.10

* Patches and recipes reworked for go 1.10's significant changes to its bootstrap and build steps.

* Update go1.4 source tarball used for go-native
bootstrapping to the version recommended
in the current go documentation

* Remove test data from installed sources to eliminate some packaging QA warnings

* Set GOCACHE to 'off' to disable 1.10's build caching in the go recipes and bbclass

* Update go_do_compile to compile both static and dynamic objects dynamic linking is in use, since go1.10's build tool is pickier about this

---
 meta/classes/go.bbclass                            |   6 +
 meta/recipes-devtools/go/go-1.10.inc               |  22 ++
 ...1-allow-CC-and-CXX-to-have-multiple-words.patch |  33 +++
 ...-content-based-hash-generation-less-pedan.patch | 220 ++++++++++++++++
 ...OLDIR-to-be-overridden-in-the-environment.patch |  64 +++++
 .../0004-ld-add-soname-to-shareable-objects.patch  |  47 ++++
 ...verride-CC-when-building-dist-and-go_boot.patch |  40 +++
 ...-cmd-dist-separate-host-and-target-builds.patch | 277 +++++++++++++++++++++
 ...07-cmd-go-make-GOROOT-precious-by-default.patch | 108 ++++++++
 ...l-obj-arm64-fix-branch-too-far-with-TBZ-l.patch |  58 +++++
 ...ld-replace-glibc-dynamic-linker-with-musl.patch | 130 ++++++++++
 meta/recipes-devtools/go/go-common.inc             |   2 +
 meta/recipes-devtools/go/go-cross-canadian.inc     |  27 +-
 meta/recipes-devtools/go/go-cross-canadian_1.10.bb |   2 +
 meta/recipes-devtools/go/go-cross-canadian_1.9.bb  |  10 +
 meta/recipes-devtools/go/go-cross.inc              |  55 ++--
 meta/recipes-devtools/go/go-cross_1.10.bb          |   2 +
 meta/recipes-devtools/go/go-cross_1.9.bb           |   8 +
 meta/recipes-devtools/go/go-crosssdk.inc           |  16 +-
 meta/recipes-devtools/go/go-crosssdk_1.10.bb       |   2 +
 meta/recipes-devtools/go/go-crosssdk_1.9.bb        |   9 +
 meta/recipes-devtools/go/go-native.inc             |  26 +-
 meta/recipes-devtools/go/go-native_1.10.bb         |   2 +
 meta/recipes-devtools/go/go-native_1.9.bb          |   2 +
 meta/recipes-devtools/go/go-runtime.inc            |  58 +++--
 meta/recipes-devtools/go/go-runtime_1.10.bb        |   2 +
 meta/recipes-devtools/go/go-runtime_1.9.bb         |  21 ++
 meta/recipes-devtools/go/go-target.inc             |  21 +-
 meta/recipes-devtools/go/go_1.10.bb                |   2 +
 meta/recipes-devtools/go/go_1.9.bb                 |  15 ++
 30 files changed, 1183 insertions(+), 104 deletions(-)
 create mode 100644 meta/recipes-devtools/go/go-1.10.inc
 create mode 100644 meta/recipes-devtools/go/go-1.10/0001-allow-CC-and-CXX-to-have-multiple-words.patch
 create mode 100644 meta/recipes-devtools/go/go-1.10/0002-cmd-go-make-content-based-hash-generation-less-pedan.patch
 create mode 100644 meta/recipes-devtools/go/go-1.10/0003-allow-GOTOOLDIR-to-be-overridden-in-the-environment.patch
 create mode 100644 meta/recipes-devtools/go/go-1.10/0004-ld-add-soname-to-shareable-objects.patch
 create mode 100644 meta/recipes-devtools/go/go-1.10/0005-make.bash-override-CC-when-building-dist-and-go_boot.patch
 create mode 100644 meta/recipes-devtools/go/go-1.10/0006-cmd-dist-separate-host-and-target-builds.patch
 create mode 100644 meta/recipes-devtools/go/go-1.10/0007-cmd-go-make-GOROOT-precious-by-default.patch
 create mode 100644 meta/recipes-devtools/go/go-1.10/0008-cmd-internal-obj-arm64-fix-branch-too-far-with-TBZ-l.patch
 create mode 100644 meta/recipes-devtools/go/go-1.10/0009-ld-replace-glibc-dynamic-linker-with-musl.patch
 create mode 100644 meta/recipes-devtools/go/go-cross-canadian_1.10.bb
 create mode 100644 meta/recipes-devtools/go/go-cross_1.10.bb
 create mode 100644 meta/recipes-devtools/go/go-crosssdk_1.10.bb
 create mode 100644 meta/recipes-devtools/go/go-native_1.10.bb
 create mode 100644 meta/recipes-devtools/go/go-runtime_1.10.bb
 create mode 100644 meta/recipes-devtools/go/go_1.10.bb
meta/classes/go.bbclass +6 -0
index 7ecd8c9254..a01b28bccd 100644
@@ -24,6 +24,7 @@ GO_LINKMODE ?= ""
 GO_LINKMODE_class-nativesdk = "--linkmode=external"
 GO_LDFLAGS ?= '-ldflags="${GO_RPATH} ${GO_LINKMODE} -extldflags '${GO_EXTLDFLAGS}'"'
 export GOBUILDFLAGS ?= "-v ${GO_LDFLAGS}"
+export GOPATH_OMIT_IN_ACTIONID ?= "1"
 export GOPTESTBUILDFLAGS ?= "${GOBUILDFLAGS} -c"
 export GOPTESTFLAGS ?= "-test.v"
 GOBUILDFLAGS_prepend_task-compile = "${GO_PARALLEL_BUILD} "
@@ -47,6 +48,7 @@ GO_INSTALL_FILTEROUT ?= "${GO_IMPORT}/vendor/"
 
 B = "${WORKDIR}/build"
 export GOPATH = "${B}"
+export GOCACHE = "off"
 GO_TMPDIR ?= "${WORKDIR}/go-tmp"
 GO_TMPDIR[vardepvalue] = ""
 
@@ -88,6 +90,10 @@ go_do_compile() {
 	export TMPDIR="${GO_TMPDIR}"
 	${GO} env
 	if [ -n "${GO_INSTALL}" ]; then
+		if [ -n "${GO_LINKSHARED}" ]; then
+			${GO} install ${GOBUILDFLAGS} `go_list_packages`
+			rm -rf ${B}/bin
+		fi
 		${GO} install ${GO_LINKSHARED} ${GOBUILDFLAGS} `go_list_packages`
 	fi
 }
meta/recipes-devtools/go/go-1.10.inc new file +22 -0
new file mode 100644
index 0000000000..08d1ba6551
@@ -0,0 +1,22 @@
+require go-common.inc
+
+GO_BASEVERSION = "1.10"
+FILESEXTRAPATHS_prepend := "${FILE_DIRNAME}/go-${GO_BASEVERSION}:"
+
+LIC_FILES_CHKSUM = "file://LICENSE;md5=5d4950ecb7b26d2c5e4e7b4e0dd74707"
+
+SRC_URI += "\
+    file://0001-allow-CC-and-CXX-to-have-multiple-words.patch \
+    file://0002-cmd-go-make-content-based-hash-generation-less-pedan.patch \
+    file://0003-allow-GOTOOLDIR-to-be-overridden-in-the-environment.patch \
+    file://0004-ld-add-soname-to-shareable-objects.patch \
+    file://0005-make.bash-override-CC-when-building-dist-and-go_boot.patch \
+    file://0006-cmd-dist-separate-host-and-target-builds.patch \
+    file://0007-cmd-go-make-GOROOT-precious-by-default.patch \
+    file://0008-cmd-internal-obj-arm64-fix-branch-too-far-with-TBZ-l.patch \
+"
+
+SRC_URI_append_libc-musl = " file://0009-ld-replace-glibc-dynamic-linker-with-musl.patch"
+
+SRC_URI[main.md5sum] = "07cbb9d0091b846c6aea40bf5bc0cea7"
+SRC_URI[main.sha256sum] = "f3de49289405fda5fd1483a8fe6bd2fa5469e005fd567df64485c4fa000c7f24"
meta/recipes-devtools/go/go-1.10/0001-allow-CC-and-CXX-to-have-multiple-words.patch new file +33 -0
new file mode 100644
index 0000000000..3bb33b0146
@@ -0,0 +1,33 @@
+From 7a7de46129fa6859fb6311096eb9f54c53c7fe2f Mon Sep 17 00:00:00 2001
+From: Matt Madison <[email protected]>
+Date: Mon, 19 Feb 2018 08:49:33 -0800
+Subject: [PATCH 1/9] allow CC and CXX to have multiple words
+
+Upstream-Status: Inappropriate [OE specific]
+
+Signed-off-by: Matt Madison <[email protected]>
+---
+ src/cmd/go/internal/envcmd/env.go | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/src/cmd/go/internal/envcmd/env.go b/src/cmd/go/internal/envcmd/env.go
+index 603f7b5060..f891123f9c 100644
+--- a/src/cmd/go/internal/envcmd/env.go
++++ b/src/cmd/go/internal/envcmd/env.go
+@@ -82,11 +82,11 @@ func MkEnv() []cfg.EnvVar {
+ 
+ 	cc := cfg.DefaultCC(cfg.Goos, cfg.Goarch)
+ 	if env := strings.Fields(os.Getenv("CC")); len(env) > 0 {
+-		cc = env[0]
++		cc = strings.Join(env, " ")
+ 	}
+ 	cxx := cfg.DefaultCXX(cfg.Goos, cfg.Goarch)
+ 	if env := strings.Fields(os.Getenv("CXX")); len(env) > 0 {
+-		cxx = env[0]
++		cxx = strings.Join(env, " ")
+ 	}
+ 	env = append(env, cfg.EnvVar{Name: "CC", Value: cc})
+ 	env = append(env, cfg.EnvVar{Name: "CXX", Value: cxx})
+-- 
+2.14.1
+
meta/recipes-devtools/go/go-1.10/0002-cmd-go-make-content-based-hash-generation-less-pedan.patch new file +220 -0

220 lines not on this page · raw message

meta/recipes-devtools/go/go-1.10/0003-allow-GOTOOLDIR-to-be-overridden-in-the-environment.patch new file +64 -0

64 lines not on this page · raw message

meta/recipes-devtools/go/go-1.10/0004-ld-add-soname-to-shareable-objects.patch new file +47 -0

47 lines not on this page · raw message

meta/recipes-devtools/go/go-1.10/0005-make.bash-override-CC-when-building-dist-and-go_boot.patch new file +40 -0
new file mode 100644
index 0000000000..67a93939f5
@@ -0,0 +1,40 @@
+From 16124d84648f4dfdfa4738c5660b5400b30bf9da Mon Sep 17 00:00:00 2001
+From: Matt Madison <[email protected]>
+Date: Sat, 17 Feb 2018 06:32:45 -0800
+Subject: [PATCH 5/9] make.bash: override CC when building dist and
+ go_bootstrap
+
+for handling OE cross-canadian builds.
+
+Upstream-Status: Inappropriate [OE specific]
+
+Signed-off-by: Matt Madison <[email protected]>
+---
+ src/make.bash | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/src/make.bash b/src/make.bash
+index 93a5c43d11..3a63682bc4 100755
+--- a/src/make.bash
++++ b/src/make.bash
+@@ -162,7 +162,7 @@ if [ "$GOROOT_BOOTSTRAP" = "$GOROOT" ]; then
+ 	exit 1
+ fi
+ rm -f cmd/dist/dist
+-GOROOT="$GOROOT_BOOTSTRAP" GOOS="" GOARCH="" "$GOROOT_BOOTSTRAP/bin/go" build -o cmd/dist/dist ./cmd/dist
++CC="${BUILD_CC:-${CC}}" GOROOT="$GOROOT_BOOTSTRAP" GOOS="" GOARCH="" "$GOROOT_BOOTSTRAP/bin/go" build -o cmd/dist/dist ./cmd/dist
+ 
+ # -e doesn't propagate out of eval, so check success by hand.
+ eval $(./cmd/dist/dist env -p || echo FAIL=true)
+@@ -193,7 +193,7 @@ fi
+ # Run dist bootstrap to complete make.bash.
+ # Bootstrap installs a proper cmd/dist, built with the new toolchain.
+ # Throw ours, built with Go 1.4, away after bootstrap.
+-./cmd/dist/dist bootstrap $buildall $vflag $GO_DISTFLAGS "$@"
++CC="${BUILD_CC:-${CC}}" ./cmd/dist/dist bootstrap $buildall $vflag $GO_DISTFLAGS "$@"
+ rm -f ./cmd/dist/dist
+ 
+ # DO NOT ADD ANY NEW CODE HERE.
+-- 
+2.14.1
+
meta/recipes-devtools/go/go-1.10/0006-cmd-dist-separate-host-and-target-builds.patch new file +277 -0

277 lines not on this page · raw message

meta/recipes-devtools/go/go-1.10/0007-cmd-go-make-GOROOT-precious-by-default.patch new file +108 -0

108 lines not on this page · raw message

meta/recipes-devtools/go/go-1.10/0008-cmd-internal-obj-arm64-fix-branch-too-far-with-TBZ-l.patch new file +58 -0

58 lines not on this page · raw message

meta/recipes-devtools/go/go-1.10/0009-ld-replace-glibc-dynamic-linker-with-musl.patch new file +130 -0

130 lines not on this page · raw message

meta/recipes-devtools/go/go-common.inc +2 -0
index 37138b51ed..611775b2cc 100644
@@ -22,6 +22,8 @@ UPSTREAM_CHECK_REGEX = "(?P<pver>\d+(\.\d+)+)\.src\.tar"
 INHIBIT_PACKAGE_DEBUG_SPLIT = "1"
 SSTATE_SCAN_CMD = "true"
 
+export GOROOT_OVERRIDE = "1"
+
 do_compile_prepend() {
 	BUILD_CC=${BUILD_CC}
 }
meta/recipes-devtools/go/go-cross-canadian.inc +13 -14
index 8afda6b2ce..e22914e7aa 100644
@@ -7,34 +7,33 @@ PN = "go-cross-canadian-${TRANSLATED_TARGET_ARCH}"
 
 export GOHOSTOS = "${BUILD_GOOS}"
 export GOHOSTARCH = "${BUILD_GOARCH}"
-export GOHOSTOS_CROSS = "${HOST_GOOS}"
-export GOHOSTARCH_CROSS = "${HOST_GOARCH}"
 export GOROOT_BOOTSTRAP = "${STAGING_LIBDIR_NATIVE}/go"
 export GOTOOLDIR_BOOTSTRAP = "${STAGING_LIBDIR_NATIVE}/${HOST_SYS}/go/pkg/tool/${BUILD_GOTUPLE}"
 export GOROOT_FINAL = "${libdir}/go"
 export CGO_ENABLED = "1"
-export CC_FOR_TARGET = "${TARGET_PREFIX}gcc"
-export CXX_FOR_TARGET = "${TARGET_PREFIX}g++"
-CC = "${HOST_PREFIX}gcc"
-export CGO_CFLAGS = "--sysroot=${STAGING_DIR_TARGET} ${HOST_CC_ARCH} ${CFLAGS}"
-export CGO_LDFLAGS = "--sysroot=${STAGING_DIR_TARGET} ${HOST_CC_ARCH} ${LDFLAGS}"
-export GO_LDFLAGS = '-linkmode external -extld ${HOST_PREFIX}gcc -extldflags "--sysroot=${STAGING_DIR_TARGET} ${HOST_CC_ARCH} ${LDFLAGS}"'
+export GOCACHE = "off"
+export GOTMPDIR ?= "${WORKDIR}/go-tmp"
+GOTMPDIR[vardepvalue] = ""
+export CGO_CFLAGS = "${CFLAGS}"
+export CGO_LDFLAGS = "${LDFLAGS}"
+export GO_LDFLAGS = '-linkmode external -extld ${HOST_PREFIX}gcc -extldflags "--sysroot=${STAGING_DIR_HOST} ${HOST_CC_ARCH} ${LDFLAGS}"'
 
 do_configure[noexec] = "1"
 
 do_compile() {
-	export GOBIN="${B}/bin"
-	rm -rf ${GOBIN} ${B}/pkg
-	mkdir ${GOBIN}
+	export CC_FOR_${HOST_GOOS}_${HOST_GOARCH}="${HOST_PREFIX}gcc --sysroot=${STAGING_DIR_HOST}${SDKPATHNATIVE}"
+	export CXX_FOR_${HOST_GOOS}_${HOST_GOARCH}="${HOST_PREFIX}gxx --sysroot=${STAGING_DIR_HOST}${SDKPATHNATIVE}"
 	cd src
 	./make.bash --host-only --no-banner
 	cd ${B}
 }
+do_compile[dirs] =+ "${GOTMPDIR} ${B}/bin ${B}/pkg"
+do_compile[cleandirs] += "${GOTMPDIR} ${B}/bin ${B}/pkg"
 
 
 make_wrapper() {
-    rm -f ${D}${bindir}/$2
-    cat <<END >${D}${bindir}/$2
+	rm -f ${D}${bindir}/$2
+	cat <<END >${D}${bindir}/$2
 #!/bin/sh
 here=\`dirname \$0\`
 native_goroot=\`readlink -f \$here/../../lib/${TARGET_SYS}/go\`
@@ -46,7 +45,7 @@ export GOTOOLDIR="\$native_goroot/pkg/tool/${HOST_GOTUPLE}"
 test -n "\$GOROOT" || export GOROOT="\$OECORE_TARGET_SYSROOT/${target_libdir}/go"
 \$here/../../lib/${TARGET_SYS}/go/bin/$1 "\$@"
 END
-    chmod +x ${D}${bindir}/$2
+	chmod +x ${D}${bindir}/$2
 }
 
 do_install() {
meta/recipes-devtools/go/go-cross-canadian_1.10.bb new file +2 -0
new file mode 100644
index 0000000000..7ac9449e47
@@ -0,0 +1,2 @@
+require go-cross-canadian.inc
+require go-${PV}.inc
meta/recipes-devtools/go/go-cross-canadian_1.9.bb +10 -0
index 7ac9449e47..0306fdf684 100644
@@ -1,2 +1,12 @@
 require go-cross-canadian.inc
 require go-${PV}.inc
+
+export GOHOSTOS_CROSS = "${HOST_GOOS}"
+export GOHOSTARCH_CROSS = "${HOST_GOARCH}"
+export CC_FOR_TARGET = "${HOST_PREFIX}gcc --sysroot=${STAGING_DIR_HOST}${SDKPATHNATIVE}"
+export CXX_FOR_TARGET = "${HOST_PREFIX}g++ --sysroot=${STAGING_DIR_HOST}${SDKPATHNATIVE}"
+
+do_compile_prepend() {
+	export GOBIN="${B}/bin"
+	export TMPDIR="$GOTMPDIR"
+}
meta/recipes-devtools/go/go-cross.inc +28 -27

83 lines not on this page · raw message

meta/recipes-devtools/go/go-cross_1.10.bb new file +2 -0
new file mode 100644
index 0000000000..80b5a03f6c
@@ -0,0 +1,2 @@
+require go-cross.inc
+require go-${PV}.inc
meta/recipes-devtools/go/go-cross_1.9.bb +8 -0
index 80b5a03f6c..4739c7d5c4 100644
@@ -1,2 +1,10 @@
 require go-cross.inc
 require go-${PV}.inc
+
+export CC_FOR_TARGET = "${TARGET_PREFIX}gcc ${TARGET_CC_ARCH} --sysroot=${STAGING_DIR_TARGET}"
+export CXX_FOR_TARGET = "${TARGET_PREFIX}g++ ${TARGET_CC_ARCH} --sysroot=${STAGING_DIR_TARGET}"
+
+do_compile_prepend() {
+	export GOBIN="${B}/bin"
+	export TMPDIR="$GOTMPDIR"
+}
meta/recipes-devtools/go/go-crosssdk.inc +8 -8
index f67e4b92a0..05ca62eba8 100644
@@ -11,21 +11,21 @@ export GOARCH = "${TARGET_GOARCH}"
 export GOROOT_BOOTSTRAP = "${STAGING_LIBDIR_NATIVE}/go"
 export GOROOT_FINAL = "${libdir}/go"
 export CGO_ENABLED = "1"
-export CC_FOR_TARGET="${TARGET_PREFIX}gcc ${TARGET_CC_ARCH} --sysroot=${STAGING_DIR_TARGET}${SDKPATHNATIVE}"
-export CXX_FOR_TARGET="${TARGET_PREFIX}g++ ${TARGET_CC_ARCH} --sysroot=${STAGING_DIR_TARGET}${SDKPATHNATIVE}"
-export GO_INSTALL = "cmd"
-CC = "${@d.getVar('BUILD_CC').strip()}"
+export GOCACHE = "off"
+export GOTMPDIR ?= "${WORKDIR}/go-tmp"
+GOTMPDIR[vardepvalue] = ""
 
 do_configure[noexec] = "1"
 
 do_compile() {
-	export GOBIN="${B}/bin"
-	rm -rf ${GOBIN} ${B}/pkg
-	mkdir ${GOBIN}
+	export CC_FOR_${TARGET_GOOS}_${TARGET_GOARCH}="${TARGET_PREFIX}gcc ${TARGET_CC_ARCH} --sysroot=${STAGING_DIR_TARGET}${SDKPATHNATIVE}"
+	export CXX_FOR_${TARGET_GOOS}_${TARGET_GOARCH}="${TARGET_PREFIX}g++ ${TARGET_CC_ARCH} --sysroot=${STAGING_DIR_TARGET}${SDKPATHNATIVE}"
 	cd src
-	./make.bash --host-only
+	./make.bash --host-only --no-banner
 	cd ${B}
 }
+do_compile[dirs] =+ "${GOTMPDIR} ${B}/bin ${B}/pkg"
+do_compile[cleandirs] += "${GOTMPDIR} ${B}/bin ${B}/pkg"
 
 make_wrapper() {
     rm -f ${D}${bindir}/$2
meta/recipes-devtools/go/go-crosssdk_1.10.bb new file +2 -0
new file mode 100644
index 0000000000..1857c8a577
@@ -0,0 +1,2 @@
+require go-crosssdk.inc
+require go-${PV}.inc
meta/recipes-devtools/go/go-crosssdk_1.9.bb +9 -0
index 1857c8a577..3ac629bd41 100644
@@ -1,2 +1,11 @@
 require go-crosssdk.inc
 require go-${PV}.inc
+
+export CC_FOR_TARGET = "${TARGET_PREFIX}gcc ${TARGET_CC_ARCH} --sysroot=${STAGING_DIR_TARGET}"
+export CXX_FOR_TARGET = "${TARGET_PREFIX}g++ ${TARGET_CC_ARCH} --sysroot=${STAGING_DIR_TARGET}"
+export GO_INSTALL = "cmd"
+
+do_compile_prepend() {
+	export GOBIN="${B}/bin"
+	export TMPDIR="$GOTMPDIR"
+}
meta/recipes-devtools/go/go-native.inc +13 -13
index 95db1c2b7c..35561768df 100644
@@ -4,34 +4,34 @@ nonstaging_libdir := "${libdir}"
 
 inherit native
 
-SRC_URI_append = " http://golang.org/dl/go1.4.3.src.tar.gz;name=bootstrap;subdir=go1.4"
-SRC_URI[bootstrap.md5sum] = "dfb604511115dd402a77a553a5923a04"
-SRC_URI[bootstrap.sha256sum] = "9947fc705b0b841b5938c48b22dc33e9647ec0752bae66e50278df4f23f64959"
+SRC_URI_append = " https://dl.google.com/go/go1.4-bootstrap-20171003.tar.gz;name=bootstrap;subdir=go1.4"
+SRC_URI[bootstrap.md5sum] = "dbf727a4b0e365bf88d97cbfde590016"
+SRC_URI[bootstrap.sha256sum] = "f4ff5b5eb3a3cae1c993723f3eab519c5bae18866b5e5f96fe1102f0cb5c3e52"
 
 export GOOS = "${BUILD_GOOS}"
 export GOARCH = "${BUILD_GOARCH}"
+export GOTMPDIR ?= "${WORKDIR}/go-tmp"
+GOTMPDIR[vardepvalue] = ""
 CC = "${@d.getVar('BUILD_CC').strip()}"
 
 export CGO_ENABLED = "1"
+GOMAKEARGS ?= "--no-banner"
 
 do_configure() {
-    cd ${WORKDIR}/go1.4/go/src
-    CGO_ENABLED=0 GOROOT=${WORKDIR}/go1.4/go ./make.bash
+	cd ${WORKDIR}/go1.4/go/src
+	CGO_ENABLED=0 GOROOT=${WORKDIR}/go1.4/go ./make.bash
 }
 
 do_compile() {
-	export GOBIN="${B}/bin"
 	export GOROOT_FINAL="${nonstaging_libdir}/go"
 	export GOROOT_BOOTSTRAP="${WORKDIR}/go1.4/go"
-	rm -rf ${GOBIN}
-	mkdir ${GOBIN}
-
-	export TMPDIR=${WORKDIR}/build-tmp
-	mkdir -p ${WORKDIR}/build-tmp
 
 	cd src
-	./make.bash --host-only
+	./make.bash ${GOMAKEARGS}
+	cd ${B}
 }
+do_compile[dirs] =+ "${GOTMPDIR} ${B}/bin"
+do_compile[cleandirs] += "${GOTMPDIR} ${B}/bin"
 
 make_wrapper() {
 	rm -f ${D}${bindir}/$2$3
@@ -51,7 +51,7 @@ do_install() {
 	(cd ${S}/src; for d in *; do \
 		[ -d $d ] && cp -a ${S}/src/$d ${D}${libdir}/go/src/; \
 	done)
-	rm -rf ${D}${libdir}/go/src/runtime/pprof/testdata
+	find ${D}${libdir}/go/src -depth -type d -name testdata -exec rm -rf {} \;
 	install -d ${D}${bindir} ${D}${libdir}/go/bin
 	for f in ${B}/bin/*
 	do
meta/recipes-devtools/go/go-native_1.10.bb new file +2 -0
new file mode 100644
index 0000000000..bbf3c0dd73
@@ -0,0 +1,2 @@
+require ${PN}.inc
+require go-${PV}.inc
meta/recipes-devtools/go/go-native_1.9.bb +2 -0
index bbf3c0dd73..8621e1df32 100644
@@ -1,2 +1,4 @@
 require ${PN}.inc
 require go-${PV}.inc
+
+GOMAKEARGS = "--host-only --no-banner"
meta/recipes-devtools/go/go-runtime.inc +28 -30

99 lines not on this page · raw message

meta/recipes-devtools/go/go-runtime_1.10.bb new file +2 -0
new file mode 100644
index 0000000000..43b68b4e46
@@ -0,0 +1,2 @@
+require go-${PV}.inc
+require go-runtime.inc
meta/recipes-devtools/go/go-runtime_1.9.bb +21 -0
index 43b68b4e46..a99cc30f63 100644
@@ -1,2 +1,23 @@
 require go-${PV}.inc
 require go-runtime.inc
+
+export GO_TARGET_INSTALL = "std"
+export CC_FOR_TARGET = "${CC}"
+export CXX_FOR_TARGET = "${CXX}"
+
+do_compile() {
+	export GOBIN="${B}/bin"
+	export TMPDIR="$GOTMPDIR"
+	export CC=$BUILD_CC
+
+	cd src
+	./make.bash --host-only
+	cp ${B}/pkg/tool/${BUILD_GOTUPLE}/go_bootstrap ${B}
+	rm -rf ${B}/pkg/${TARGET_GOTUPLE}
+	./make.bash --target-only
+	if [ -n "${GO_DYNLINK}" ]; then
+		cp ${B}/go_bootstrap ${B}/pkg/tool/${BUILD_GOTUPLE}
+		GO_FLAGS="-buildmode=shared" GO_LDFLAGS="-extldflags \"${LDFLAGS}\"" ./make.bash --target-only
+	fi
+	cd ${B}
+}
meta/recipes-devtools/go/go-target.inc +9 -12
index cac5d78227..a53a314c78 100644
@@ -11,10 +11,9 @@ export GO386 = "${TARGET_GO386}"
 export GOROOT_BOOTSTRAP = "${STAGING_LIBDIR_NATIVE}/go"
 export GOROOT_FINAL = "${libdir}/go"
 export CGO_ENABLED = "1"
-export CC_FOR_TARGET = "${CC}"
-export CXX_FOR_TARGET = "${CXX}"
-export GO_TARGET_INSTALL = "cmd"
-export GO_FLAGS = "-a"
+export GOCACHE = "off"
+export GOTMPDIR ?= "${WORKDIR}/go-tmp"
+GOTMPDIR[vardepvalue] = ""
 GO_LDFLAGS = ""
 GO_LDFLAGS_class-nativesdk = "-linkmode external"
 export GO_LDFLAGS
@@ -25,24 +24,22 @@ SECURITY_LDFLAGS = ""
 do_configure[noexec] = "1"
 
 do_compile() {
-	export GOBIN="${B}/bin"
-	export CC="${@d.getVar('BUILD_CC').strip()}"
-	rm -rf ${GOBIN} ${B}/pkg
-	mkdir ${GOBIN}
-
-	export TMPDIR=${WORKDIR}/build-tmp
-	mkdir -p ${WORKDIR}/build-tmp
+	export CC_FOR_${TARGET_GOOS}_${TARGET_GOARCH}="${CC}"
+	export CXX_FOR_${TARGET_GOOS}_${TARGET_GOARCH}="${CXX}"
 
 	cd src
-	./make.bash
+	./make.bash --target-only --no-banner
 	cd ${B}
 }
+do_compile[dirs] =+ "${GOTMPDIR} ${B}/bin ${B}/pkg"
+do_compile[cleandirs] += "${GOTMPDIR} ${B}/bin ${B}/pkg"
 
 do_install() {
 	install -d ${D}${libdir}/go/pkg/tool
 	cp --preserve=mode,timestamps -R ${B}/pkg/tool/${TARGET_GOTUPLE} ${D}${libdir}/go/pkg/tool/
 	install -d ${D}${libdir}/go/src
 	cp --preserve=mode,timestamps -R ${S}/src/cmd ${D}${libdir}/go/src/
+	find ${D}${libdir}/go/src -depth -type d -name testdata -exec rm -rf {} \;
 	install -d ${D}${libdir}/go/bin
 	install -d ${D}${bindir}
 	for f in ${B}/${GO_BUILD_BINDIR}/*; do
meta/recipes-devtools/go/go_1.10.bb new file +2 -0
new file mode 100644
index 0000000000..c67e2cb050
@@ -0,0 +1,2 @@
+require go-${PV}.inc
+require go-target.inc
meta/recipes-devtools/go/go_1.9.bb +15 -0
index c67e2cb050..ec5a314e7d 100644
@@ -1,2 +1,17 @@
 require go-${PV}.inc
 require go-target.inc
+
+export GO_TARGET_INSTALL = "cmd"
+export GO_FLAGS = "-a"
+export CC_FOR_TARGET = "${CC}"
+export CXX_FOR_TARGET = "${CXX}"
+
+do_compile() {
+	export GOBIN="${B}/bin"
+	export TMPDIR="$GOTMPDIR"
+	export CC=$BUILD_CC
+
+	cd src
+	./make.bash
+	cd ${B}
+}
Signature · 1 line
2.14.1
#2 lore raw

PATCH v5 2/13 go: set GOMIPS envrionment variable

In reply to Matt Madison

Go 1.10 adds support for selecting hard/soft float object code through the GOMIPS environment variable.

---
 meta/classes/goarch.bbclass                    | 11 +++++++++++
 meta/recipes-devtools/go/go-cross-canadian.inc |  1 +
 meta/recipes-devtools/go/go-cross.inc          |  2 ++
 meta/recipes-devtools/go/go-runtime.inc        |  1 +
 meta/recipes-devtools/go/go-target.inc         |  1 +
 5 files changed, 16 insertions(+)
meta/classes/goarch.bbclass +11 -0
index 922c0cc8f3..1021b94d4c 100644
@@ -5,11 +5,13 @@ HOST_GOOS = "${@go_map_os(d.getVar('HOST_OS'), d)}"
 HOST_GOARCH = "${@go_map_arch(d.getVar('HOST_ARCH'), d)}"
 HOST_GOARM = "${@go_map_arm(d.getVar('HOST_ARCH'), d.getVar('TUNE_FEATURES'), d)}"
 HOST_GO386 = "${@go_map_386(d.getVar('HOST_ARCH'), d.getVar('TUNE_FEATURES'), d)}"
+HOST_GOMIPS = "${@go_map_mips(d.getVar('HOST_ARCH'), d.getVar('TUNE_FEATURES'), d)}"
 HOST_GOTUPLE = "${HOST_GOOS}_${HOST_GOARCH}"
 TARGET_GOOS = "${@go_map_os(d.getVar('TARGET_OS'), d)}"
 TARGET_GOARCH = "${@go_map_arch(d.getVar('TARGET_ARCH'), d)}"
 TARGET_GOARM = "${@go_map_arm(d.getVar('TARGET_ARCH'), d.getVar('TUNE_FEATURES'), d)}"
 TARGET_GO386 = "${@go_map_386(d.getVar('TARGET_ARCH'), d.getVar('TUNE_FEATURES'), d)}"
+TARGET_GOMIPS = "${@go_map_mips(d.getVar('TARGET_ARCH'), d.getVar('TUNE_FEATURES'), d)}"
 TARGET_GOTUPLE = "${TARGET_GOOS}_${TARGET_GOARCH}"
 GO_BUILD_BINDIR = "${@['bin/${HOST_GOTUPLE}','bin'][d.getVar('BUILD_GOTUPLE') == d.getVar('HOST_GOTUPLE')]}"
 
@@ -78,6 +80,15 @@ def go_map_386(a, f, d):
             return '387'
     return ''
 
+def go_map_mips(a, f, d):
+    import re
+    if a == 'mips' or a == 'mipsel':
+        if 'fpu-hard' in f:
+            return 'hardfloat'
+        else:
+            return 'softfloat'
+    return ''
+
 def go_map_os(o, d):
     if o.startswith('linux'):
         return 'linux'
meta/recipes-devtools/go/go-cross-canadian.inc +1 -0
index e22914e7aa..4a43d831fa 100644
@@ -41,6 +41,7 @@ export GOARCH="${TARGET_GOARCH}"
 export GOOS="${TARGET_GOOS}"
 test -n "\$GOARM" || export GOARM="${TARGET_GOARM}"
 test -n "\$GO386" || export GO386="${TARGET_GO386}"
+test -n "\$GOMIPS" || export GOMIPS="${TARGET_GOMIPS}"
 export GOTOOLDIR="\$native_goroot/pkg/tool/${HOST_GOTUPLE}"
 test -n "\$GOROOT" || export GOROOT="\$OECORE_TARGET_SYSROOT/${target_libdir}/go"
 \$here/../../lib/${TARGET_SYS}/go/bin/$1 "\$@"
meta/recipes-devtools/go/go-cross.inc +2 -0
index fe92651581..289ae77104 100644
@@ -11,6 +11,7 @@ export GOOS = "${TARGET_GOOS}"
 export GOARCH = "${TARGET_GOARCH}"
 export GOARM = "${TARGET_GOARM}"
 export GO386 = "${TARGET_GO386}"
+export GOMIPS = "${TARGET_GOMIPS}"
 export GOROOT_BOOTSTRAP = "${STAGING_LIBDIR_NATIVE}/go"
 export GOROOT_FINAL = "${libdir}/go"
 export GOCACHE = "off"
@@ -40,6 +41,7 @@ export GOARCH="${TARGET_GOARCH}"
 export GOOS="${TARGET_GOOS}"
 export GOARM="\${GOARM:-${TARGET_GOARM}}"
 export GO386="\${GO386:-${TARGET_GO386}}"
+export GOMIPS="\${GOMIPS:-${TARGET_GOMIPS}}"
 \$here/../../lib/${CROSS_TARGET_SYS_DIR}/go/bin/$1 "\$@"
 END
 	chmod +x ${D}${bindir}/$2
meta/recipes-devtools/go/go-runtime.inc +1 -0
index 7a3b415b3f..0fe4566360 100644
@@ -8,6 +8,7 @@ export GOOS = "${TARGET_GOOS}"
 export GOARCH = "${TARGET_GOARCH}"
 export GOARM = "${TARGET_GOARM}"
 export GO386 = "${TARGET_GO386}"
+export GOMIPS = "${TARGET_GOMIPS}"
 export GOROOT_BOOTSTRAP = "${STAGING_LIBDIR_NATIVE}/go"
 export GOROOT_FINAL = "${libdir}/go"
 export CGO_ENABLED = "1"
meta/recipes-devtools/go/go-target.inc +1 -0
index a53a314c78..141a456cca 100644
@@ -8,6 +8,7 @@ export GOOS = "${TARGET_GOOS}"
 export GOARCH = "${TARGET_GOARCH}"
 export GOARM = "${TARGET_GOARM}"
 export GO386 = "${TARGET_GO386}"
+export GOMIPS = "${TARGET_GOMIPS}"
 export GOROOT_BOOTSTRAP = "${STAGING_LIBDIR_NATIVE}/go"
 export GOROOT_FINAL = "${libdir}/go"
 export CGO_ENABLED = "1"
Signature · 1 line
2.14.1
#3 lore raw

PATCH v5 3/13 go.bbclass: rename GO_TMPDIR -> GOTMPDIR

In reply to Matt Madison

and export it. Go 1.10 now supports using this
separate variable locating its temporary files.

TMPDIR is still set, for compatibility with go1.9; that can be dropped once 1.9 is retired.

---
 meta/classes/go.bbclass | 13 +++++++------
 1 file changed, 7 insertions(+), 6 deletions(-)
meta/classes/go.bbclass +7 -6
index a01b28bccd..96302a187c 100644
@@ -49,8 +49,8 @@ GO_INSTALL_FILTEROUT ?= "${GO_IMPORT}/vendor/"
 B = "${WORKDIR}/build"
 export GOPATH = "${B}"
 export GOCACHE = "off"
-GO_TMPDIR ?= "${WORKDIR}/go-tmp"
-GO_TMPDIR[vardepvalue] = ""
+export GOTMPDIR ?= "${WORKDIR}/go-tmp"
+GOTMPDIR[vardepvalue] = ""
 
 python go_do_unpack() {
     src_uri = (d.getVar('SRC_URI') or "").split()
@@ -85,9 +85,10 @@ go_list_package_tests() {
 go_do_configure() {
 	ln -snf ${S}/src ${B}/
 }
+do_configure[dirs] =+ "${GOTMPDIR}"
 
 go_do_compile() {
-	export TMPDIR="${GO_TMPDIR}"
+	export TMPDIR="${GOTMPDIR}"
 	${GO} env
 	if [ -n "${GO_INSTALL}" ]; then
 		if [ -n "${GO_LINKSHARED}" ]; then
@@ -97,11 +98,11 @@ go_do_compile() {
 		${GO} install ${GO_LINKSHARED} ${GOBUILDFLAGS} `go_list_packages`
 	fi
 }
-do_compile[dirs] =+ "${GO_TMPDIR}"
+do_compile[dirs] =+ "${GOTMPDIR}"
 do_compile[cleandirs] = "${B}/bin ${B}/pkg"
 
 do_compile_ptest() {
-    export TMPDIR="${GO_TMPDIR}"
+	export TMPDIR="${GOTMPDIR}"
     rm -f ${B}/.go_compiled_tests.list
 	go_list_package_tests | while read pkg; do
 		cd ${B}/src/$pkg
@@ -110,7 +111,7 @@ do_compile_ptest() {
 			sed -e's,/\./,/,'>> ${B}/.go_compiled_tests.list
 	done
 }
-do_compile_ptest_base[dirs] =+ "${GO_TMPDIR}"
+do_compile_ptest_base[dirs] =+ "${GOTMPDIR}"
 
 go_do_install() {
 	install -d ${D}${libdir}/go/src/${GO_IMPORT}
Signature · 1 line
2.14.1
#4 lore raw

PATCH v5 4/13 go.bbclass: remove debug-related commands

In reply to Matt Madison

The 'go env' in the do_compile function and
the set -x/+x in the do_install_ptest function
were used for debugging the bbclass, and aren't
really needed.

---
 meta/classes/go.bbclass | 3 ---
 1 file changed, 3 deletions(-)
meta/classes/go.bbclass +0 -3
index 96302a187c..21ac2276c5 100644
@@ -89,7 +89,6 @@ do_configure[dirs] =+ "${GOTMPDIR}"
 
 go_do_compile() {
 	export TMPDIR="${GOTMPDIR}"
-	${GO} env
 	if [ -n "${GO_INSTALL}" ]; then
 		if [ -n "${GO_LINKSHARED}" ]; then
 			${GO} install ${GOBUILDFLAGS} `go_list_packages`
@@ -126,7 +125,6 @@ go_do_install() {
 }
 
 do_install_ptest_base() {
-set -x
     test -f "${B}/.go_compiled_tests.list" || exit 0
     tests=""
     while read test; do
@@ -160,7 +158,6 @@ EOF
     else
         rm -rf ${D}${PTEST_PATH}
     fi
-set +x
 }
 
 EXPORT_FUNCTIONS do_unpack do_configure do_compile do_install
Signature · 1 line
2.14.1
#5 lore raw

PATCH v5 5/13 go.bbclass: don't stage test data with sources

In reply to Matt Madison

Any directory in a Go package's source tree called 'testdata' contains test data, and isn't necessary for building.

Some packages include ELF files and other binaries as test data, and staging them in the sysroot and -dev package leads to unnecessary QA warnings.

---
 meta/classes/go.bbclass | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
meta/classes/go.bbclass +1 -1
index 21ac2276c5..afd68b5951 100644
@@ -114,7 +114,7 @@ do_compile_ptest_base[dirs] =+ "${GOTMPDIR}"
 
 go_do_install() {
 	install -d ${D}${libdir}/go/src/${GO_IMPORT}
-	tar -C ${S}/src/${GO_IMPORT} -cf - --exclude-vcs --exclude '*.test' . | \
+	tar -C ${S}/src/${GO_IMPORT} -cf - --exclude-vcs --exclude '*.test' --exclude 'testdata' . | \
 		tar -C ${D}${libdir}/go/src/${GO_IMPORT} --no-same-owner -xf -
 	tar -C ${B} -cf - pkg | tar -C ${D}${libdir}/go --no-same-owner -xf -
 
Signature · 1 line
2.14.1
#6 lore raw

PATCH v5 6/13 go.bbclass: ptest cleanup and improvements

In reply to Matt Madison

* Don't enable verbose test output (-test.v)
by default, as it generates too much noise
for automated results parsing

* Override do_install_ptest_base in the bbclass,
so recipes can provide their own modifications
with do_install_ptest.

* Improve the generated run-ptest script to better handle large numbers of tests, and to generate 'status: test name' output similar to Automake tests.

* Install all non-vendored 'testdata' directories
from the source into the ptest package, as some
packages share test data among multiple tests.

---
 meta/classes/go.bbclass | 87 +++++++++++++++++++++++++++++--------------------
 1 file changed, 51 insertions(+), 36 deletions(-)
meta/classes/go.bbclass +51 -36
index afd68b5951..a51ba3e9f0 100644
@@ -26,7 +26,7 @@ GO_LDFLAGS ?= '-ldflags="${GO_RPATH} ${GO_LINKMODE} -extldflags '${GO_EXTLDFLAGS
 export GOBUILDFLAGS ?= "-v ${GO_LDFLAGS}"
 export GOPATH_OMIT_IN_ACTIONID ?= "1"
 export GOPTESTBUILDFLAGS ?= "${GOBUILDFLAGS} -c"
-export GOPTESTFLAGS ?= "-test.v"
+export GOPTESTFLAGS ?= ""
 GOBUILDFLAGS_prepend_task-compile = "${GO_PARALLEL_BUILD} "
 
 export GO = "${HOST_PREFIX}go"
@@ -76,7 +76,7 @@ go_list_packages() {
 }
 
 go_list_package_tests() {
-    ${GO} list -f '{{.ImportPath}} {{.TestGoFiles}}' ${GOBUILDFLAGS} ${GO_INSTALL} | \
+	${GO} list -f '{{.ImportPath}} {{.TestGoFiles}}' ${GOBUILDFLAGS} ${GO_INSTALL} | \
 		grep -v '\[\]$' | \
 		egrep -v '${GO_INSTALL_FILTEROUT}' | \
 		awk '{ print $1 }'
@@ -100,15 +100,16 @@ go_do_compile() {
 do_compile[dirs] =+ "${GOTMPDIR}"
 do_compile[cleandirs] = "${B}/bin ${B}/pkg"
 
-do_compile_ptest() {
+do_compile_ptest_base() {
 	export TMPDIR="${GOTMPDIR}"
-    rm -f ${B}/.go_compiled_tests.list
+	rm -f ${B}/.go_compiled_tests.list
 	go_list_package_tests | while read pkg; do
 		cd ${B}/src/$pkg
 		${GO} test ${GOPTESTBUILDFLAGS} $pkg
 		find . -mindepth 1 -maxdepth 1 -type f -name '*.test' -exec echo $pkg/{} \; | \
 			sed -e's,/\./,/,'>> ${B}/.go_compiled_tests.list
 	done
+	do_compile_ptest
 }
 do_compile_ptest_base[dirs] =+ "${GOTMPDIR}"
 
@@ -124,40 +125,54 @@ go_do_install() {
 	fi
 }
 
-do_install_ptest_base() {
-    test -f "${B}/.go_compiled_tests.list" || exit 0
-    tests=""
-    while read test; do
-        tests="$tests${tests:+ }${test%.test}"
-        testdir=`dirname $test`
-        install -d ${D}${PTEST_PATH}/$testdir
-        install -m 0755 ${B}/src/$test ${D}${PTEST_PATH}/$test
-        if [ -d "${B}/src/$testdir/testdata" ]; then
-            cp --preserve=mode,timestamps -R "${B}/src/$testdir/testdata" ${D}${PTEST_PATH}/$testdir
-        fi
-    done < ${B}/.go_compiled_tests.list
-    if [ -n "$tests" ]; then
-        install -d ${D}${PTEST_PATH}
-        cat >${D}${PTEST_PATH}/run-ptest <<EOF
+go_make_ptest_wrapper() {
+	cat >${D}${PTEST_PATH}/run-ptest <<EOF
 #!/bin/sh
-ANYFAILED=0
-for t in $tests; do
-    testdir=\`dirname \$t.test\`
-    if ( cd "${PTEST_PATH}/\$testdir"; "${PTEST_PATH}/\$t.test" ${GOPTESTFLAGS} | tee /dev/fd/9 | grep -q "^FAIL" ) 9>&1; then
-        ANYFAILED=1
-    fi
-done
-if [ \$ANYFAILED -ne 0 ]; then
-    echo "FAIL: ${PN}"
-    exit 1
-fi
-echo "PASS: ${PN}"
-exit 0
+RC=0
+run_test() (
+    cd "\$1"
+    ((((./\$2 ${GOPTESTFLAGS}; echo \$? >&3) | sed -r -e"s,^(PASS|SKIP|FAIL)\$,\\1: \$1/\$2," >&4) 3>&1) | (read rc; exit \$rc)) 4>&1
+    exit \$?)
 EOF
-        chmod +x ${D}${PTEST_PATH}/run-ptest
-    else
-        rm -rf ${D}${PTEST_PATH}
-    fi
+
+}
+
+go_stage_testdata() {
+	oldwd="$PWD"
+	cd ${S}/src
+	find ${GO_IMPORT} -depth -type d -name testdata | while read d; do
+		if echo "$d" | grep -q '/vendor/'; then
+			continue
+		fi
+		parent=`dirname $d`
+		install -d ${D}${PTEST_PATH}/$parent
+		cp --preserve=mode,timestamps -R $d ${D}${PTEST_PATH}/$parent/
+	done
+	cd "$oldwd"
+}
+
+do_install_ptest_base() {
+	test -f "${B}/.go_compiled_tests.list" || exit 0
+	install -d ${D}${PTEST_PATH}
+	go_stage_testdata
+	go_make_ptest_wrapper
+	havetests=""
+	while read test; do
+		testdir=`dirname $test`
+		testprog=`basename $test`
+		install -d ${D}${PTEST_PATH}/$testdir
+		install -m 0755 ${B}/src/$test ${D}${PTEST_PATH}/$test
+	echo "run_test $testdir $testprog || RC=1" >> ${D}${PTEST_PATH}/run-ptest
+		havetests="yes"
+	done < ${B}/.go_compiled_tests.list
+	if [ -n "$havetests" ]; then
+		echo "exit \$RC" >> ${D}${PTEST_PATH}/run-ptest
+		chmod +x ${D}${PTEST_PATH}/run-ptest
+	else
+		rm -rf ${D}${PTEST_PATH}
+	fi
+	do_install_ptest
+	chown -R root:root ${D}${PTEST_PATH}
 }
 
 EXPORT_FUNCTIONS do_unpack do_configure do_compile do_install
Signature · 1 line
2.14.1
#7 lore raw

Re: [PATCH v5 06/13] go.bbclass: ptest cleanup and improvements

Hi Matt,

I noticed your commit is the latest update for go-dep ptest. But the go-dep ptest doesn't work in my environment. I'm trying to figure out what's wrong is here though I didn't know much about go.

BTW, Could you help to check?

root@qemux86-64:~# cd /usr/lib64/go-dep/ptest/
root@qemux86-64:/usr/lib64/go-dep/ptest# cat run-ptest
#!/bin/sh
RC=0
run_test() (
    cd "$1"
    ((((./$2 ; echo $? >&3) | sed -r -e"s,^(PASS|SKIP|FAIL)$,\1: 
$1/$2," >&4) 3>&1) | (read rc; exit $rc)) 4>&1
    exit $?)
run_test github.com/golang/dep/cmd/dep dep.test || RC=1
exit $RC
root@qemux86-64:/usr/lib64/go-dep/ptest# ./run-ptest
building testdep failed: exit status 1
can't load package: package .: no Go files in /usr/lib64/go-dep/ptest/github.com/golang/dep/cmd/dep
root@qemux86-64:/usr/lib64/go-dep/ptest#

Thanks,

Quoted 151 lines · Matt Madison

* Don't enable verbose test output (-test.v)
by default, as it generates too much noise
for automated results parsing

* Override do_install_ptest_base in the bbclass,
so recipes can provide their own modifications
with do_install_ptest.

* Improve the generated run-ptest script to better handle large numbers of tests, and to generate 'status: test name' output similar to Automake tests.

* Install all non-vendored 'testdata' directories from the source into the ptest package, as some packages share test data among multiple tests.

---
  meta/classes/go.bbclass | 87 +++++++++++++++++++++++++++++--------------------
  1 file changed, 51 insertions(+), 36 deletions(-)
meta/classes/go.bbclass +51 -36
index afd68b5951..a51ba3e9f0 100644
@@ -26,7 +26,7 @@ GO_LDFLAGS ?= '-ldflags="${GO_RPATH} ${GO_LINKMODE} -extldflags '${GO_EXTLDFLAGS
  export GOBUILDFLAGS ?= "-v ${GO_LDFLAGS}"
  export GOPATH_OMIT_IN_ACTIONID ?= "1"
  export GOPTESTBUILDFLAGS ?= "${GOBUILDFLAGS} -c"
-export GOPTESTFLAGS ?= "-test.v"
+export GOPTESTFLAGS ?= ""
  GOBUILDFLAGS_prepend_task-compile = "${GO_PARALLEL_BUILD} "
 
  export GO = "${HOST_PREFIX}go"
@@ -76,7 +76,7 @@ go_list_packages() {
  }
 
  go_list_package_tests() {
-    ${GO} list -f '{{.ImportPath}} {{.TestGoFiles}}' ${GOBUILDFLAGS} ${GO_INSTALL} | \
+	${GO} list -f '{{.ImportPath}} {{.TestGoFiles}}' ${GOBUILDFLAGS} ${GO_INSTALL} | \
  		grep -v '\[\]$' | \
  		egrep -v '${GO_INSTALL_FILTEROUT}' | \
  		awk '{ print $1 }'
@@ -100,15 +100,16 @@ go_do_compile() {
  do_compile[dirs] =+ "${GOTMPDIR}"
  do_compile[cleandirs] = "${B}/bin ${B}/pkg"
 
-do_compile_ptest() {
+do_compile_ptest_base() {
  	export TMPDIR="${GOTMPDIR}"
-    rm -f ${B}/.go_compiled_tests.list
+	rm -f ${B}/.go_compiled_tests.list
  	go_list_package_tests | while read pkg; do
  		cd ${B}/src/$pkg
  		${GO} test ${GOPTESTBUILDFLAGS} $pkg
  		find . -mindepth 1 -maxdepth 1 -type f -name '*.test' -exec echo $pkg/{} \; | \
  			sed -e's,/\./,/,'>> ${B}/.go_compiled_tests.list
  	done
+	do_compile_ptest
  }
  do_compile_ptest_base[dirs] =+ "${GOTMPDIR}"
 
@@ -124,40 +125,54 @@ go_do_install() {
  	fi
  }
 
-do_install_ptest_base() {
-    test -f "${B}/.go_compiled_tests.list" || exit 0
-    tests=""
-    while read test; do
-        tests="$tests${tests:+ }${test%.test}"
-        testdir=`dirname $test`
-        install -d ${D}${PTEST_PATH}/$testdir
-        install -m 0755 ${B}/src/$test ${D}${PTEST_PATH}/$test
-        if [ -d "${B}/src/$testdir/testdata" ]; then
-            cp --preserve=mode,timestamps -R "${B}/src/$testdir/testdata" ${D}${PTEST_PATH}/$testdir
-        fi
-    done < ${B}/.go_compiled_tests.list
-    if [ -n "$tests" ]; then
-        install -d ${D}${PTEST_PATH}
-        cat >${D}${PTEST_PATH}/run-ptest <<EOF
+go_make_ptest_wrapper() {
+	cat >${D}${PTEST_PATH}/run-ptest <<EOF
  #!/bin/sh
-ANYFAILED=0
-for t in $tests; do
-    testdir=\`dirname \$t.test\`
-    if ( cd "${PTEST_PATH}/\$testdir"; "${PTEST_PATH}/\$t.test" ${GOPTESTFLAGS} | tee /dev/fd/9 | grep -q "^FAIL" ) 9>&1; then
-        ANYFAILED=1
-    fi
-done
-if [ \$ANYFAILED -ne 0 ]; then
-    echo "FAIL: ${PN}"
-    exit 1
-fi
-echo "PASS: ${PN}"
-exit 0
+RC=0
+run_test() (
+    cd "\$1"
+    ((((./\$2 ${GOPTESTFLAGS}; echo \$? >&3) | sed -r -e"s,^(PASS|SKIP|FAIL)\$,\\1: \$1/\$2," >&4) 3>&1) | (read rc; exit \$rc)) 4>&1
+    exit \$?)
  EOF
-        chmod +x ${D}${PTEST_PATH}/run-ptest
-    else
-        rm -rf ${D}${PTEST_PATH}
-    fi
+
+}
+
+go_stage_testdata() {
+	oldwd="$PWD"
+	cd ${S}/src
+	find ${GO_IMPORT} -depth -type d -name testdata | while read d; do
+		if echo "$d" | grep -q '/vendor/'; then
+			continue
+		fi
+		parent=`dirname $d`
+		install -d ${D}${PTEST_PATH}/$parent
+		cp --preserve=mode,timestamps -R $d ${D}${PTEST_PATH}/$parent/
+	done
+	cd "$oldwd"
+}
+
+do_install_ptest_base() {
+	test -f "${B}/.go_compiled_tests.list" || exit 0
+	install -d ${D}${PTEST_PATH}
+	go_stage_testdata
+	go_make_ptest_wrapper
+	havetests=""
+	while read test; do
+		testdir=`dirname $test`
+		testprog=`basename $test`
+		install -d ${D}${PTEST_PATH}/$testdir
+		install -m 0755 ${B}/src/$test ${D}${PTEST_PATH}/$test
+	echo "run_test $testdir $testprog || RC=1" >> ${D}${PTEST_PATH}/run-ptest
+		havetests="yes"
+	done < ${B}/.go_compiled_tests.list
+	if [ -n "$havetests" ]; then
+		echo "exit \$RC" >> ${D}${PTEST_PATH}/run-ptest
+		chmod +x ${D}${PTEST_PATH}/run-ptest
+	else
+		rm -rf ${D}${PTEST_PATH}
+	fi
+	do_install_ptest
+	chown -R root:root ${D}${PTEST_PATH}
  }
 
  EXPORT_FUNCTIONS do_unpack do_configure do_compile do_install
#8 lore raw

Re: [PATCH v5 06/13] go.bbclass: ptest cleanup and improvements

Quoted 6 lines · Mingli

Hi Matt,

I noticed your commit is the latest update for go-dep ptest. But the go-dep ptest doesn't work in my environment. I'm trying to figure out what's wrong is here though I didn't know much about go.

I went back over the commits, and I don't think I did anything with go-dep specifically. I can see that the tests are failing for it, and it looks like it's because go-dep's test programs make some assumptions about the environment. For one thing, it needs the go compiler installed. It also looks like it's expecting some source files to be present... in other words, it's not really designed for a cross-build setup, with tests run on the cross-built target. It could be messy to work around that, and I'm not sure how useful it would be anyway, seeing as how go-dep is more of a build tool. Might be better to just disable ptests for it completely.

BTW, you can have the test programs generate verbose output by setting GOPTESTFLAGS = "-test.v" in the recipe, which will add that flag to their invocation in the wrapper script, or by manually running the test program on the target and passing that flag (cd into the directory where the test program is located, then run it with -test.v).

Regards,
-Matt

Quoted 174 lines

BTW, Could you help to check?

root@qemux86-64:~# cd /usr/lib64/go-dep/ptest/
root@qemux86-64:/usr/lib64/go-dep/ptest# cat run-ptest
#!/bin/sh
RC=0
run_test() (
     cd "$1"
     ((((./$2 ; echo $? >&3) | sed -r -e"s,^(PASS|SKIP|FAIL)$,\1:
$1/$2," >&4) 3>&1) | (read rc; exit $rc)) 4>&1
     exit $?)
run_test github.com/golang/dep/cmd/dep dep.test || RC=1
exit $RC
root@qemux86-64:/usr/lib64/go-dep/ptest# ./run-ptest
building testdep failed: exit status 1
can't load package: package .: no Go files in
/usr/lib64/go-dep/ptest/github.com/golang/dep/cmd/dep
root@qemux86-64:/usr/lib64/go-dep/ptest#

Thanks,

Quoted 151 lines · Matt Madison

* Don't enable verbose test output (-test.v)
by default, as it generates too much noise
for automated results parsing

* Override do_install_ptest_base in the bbclass,
so recipes can provide their own modifications
with do_install_ptest.

* Improve the generated run-ptest script to better handle large numbers of tests, and to generate 'status: test name' output similar to Automake tests.

* Install all non-vendored 'testdata' directories from the source into the ptest package, as some packages share test data among multiple tests.

---
  meta/classes/go.bbclass | 87 +++++++++++++++++++++++++++++--------------------
  1 file changed, 51 insertions(+), 36 deletions(-)
meta/classes/go.bbclass +51 -36
index afd68b5951..a51ba3e9f0 100644
@@ -26,7 +26,7 @@ GO_LDFLAGS ?= '-ldflags="${GO_RPATH} ${GO_LINKMODE} -extldflags '${GO_EXTLDFLAGS
  export GOBUILDFLAGS ?= "-v ${GO_LDFLAGS}"
  export GOPATH_OMIT_IN_ACTIONID ?= "1"
  export GOPTESTBUILDFLAGS ?= "${GOBUILDFLAGS} -c"
-export GOPTESTFLAGS ?= "-test.v"
+export GOPTESTFLAGS ?= ""
  GOBUILDFLAGS_prepend_task-compile = "${GO_PARALLEL_BUILD} "
 
  export GO = "${HOST_PREFIX}go"
@@ -76,7 +76,7 @@ go_list_packages() {
  }
 
  go_list_package_tests() {
-    ${GO} list -f '{{.ImportPath}} {{.TestGoFiles}}' ${GOBUILDFLAGS} ${GO_INSTALL} | \
+     ${GO} list -f '{{.ImportPath}} {{.TestGoFiles}}' ${GOBUILDFLAGS} ${GO_INSTALL} | \
              grep -v '\[\]$' | \
              egrep -v '${GO_INSTALL_FILTEROUT}' | \
              awk '{ print $1 }'
@@ -100,15 +100,16 @@ go_do_compile() {
  do_compile[dirs] =+ "${GOTMPDIR}"
  do_compile[cleandirs] = "${B}/bin ${B}/pkg"
 
-do_compile_ptest() {
+do_compile_ptest_base() {
      export TMPDIR="${GOTMPDIR}"
-    rm -f ${B}/.go_compiled_tests.list
+     rm -f ${B}/.go_compiled_tests.list
      go_list_package_tests | while read pkg; do
              cd ${B}/src/$pkg
              ${GO} test ${GOPTESTBUILDFLAGS} $pkg
              find . -mindepth 1 -maxdepth 1 -type f -name '*.test' -exec echo $pkg/{} \; | \
                      sed -e's,/\./,/,'>> ${B}/.go_compiled_tests.list
      done
+     do_compile_ptest
  }
  do_compile_ptest_base[dirs] =+ "${GOTMPDIR}"
 
@@ -124,40 +125,54 @@ go_do_install() {
      fi
  }
 
-do_install_ptest_base() {
-    test -f "${B}/.go_compiled_tests.list" || exit 0
-    tests=""
-    while read test; do
-        tests="$tests${tests:+ }${test%.test}"
-        testdir=`dirname $test`
-        install -d ${D}${PTEST_PATH}/$testdir
-        install -m 0755 ${B}/src/$test ${D}${PTEST_PATH}/$test
-        if [ -d "${B}/src/$testdir/testdata" ]; then
-            cp --preserve=mode,timestamps -R "${B}/src/$testdir/testdata" ${D}${PTEST_PATH}/$testdir
-        fi
-    done < ${B}/.go_compiled_tests.list
-    if [ -n "$tests" ]; then
-        install -d ${D}${PTEST_PATH}
-        cat >${D}${PTEST_PATH}/run-ptest <<EOF
+go_make_ptest_wrapper() {
+     cat >${D}${PTEST_PATH}/run-ptest <<EOF
  #!/bin/sh
-ANYFAILED=0
-for t in $tests; do
-    testdir=\`dirname \$t.test\`
-    if ( cd "${PTEST_PATH}/\$testdir"; "${PTEST_PATH}/\$t.test" ${GOPTESTFLAGS} | tee /dev/fd/9 | grep -q "^FAIL" ) 9>&1; then
-        ANYFAILED=1
-    fi
-done
-if [ \$ANYFAILED -ne 0 ]; then
-    echo "FAIL: ${PN}"
-    exit 1
-fi
-echo "PASS: ${PN}"
-exit 0
+RC=0
+run_test() (
+    cd "\$1"
+    ((((./\$2 ${GOPTESTFLAGS}; echo \$? >&3) | sed -r -e"s,^(PASS|SKIP|FAIL)\$,\\1: \$1/\$2," >&4) 3>&1) | (read rc; exit \$rc)) 4>&1
+    exit \$?)
  EOF
-        chmod +x ${D}${PTEST_PATH}/run-ptest
-    else
-        rm -rf ${D}${PTEST_PATH}
-    fi
+
+}
+
+go_stage_testdata() {
+     oldwd="$PWD"
+     cd ${S}/src
+     find ${GO_IMPORT} -depth -type d -name testdata | while read d; do
+             if echo "$d" | grep -q '/vendor/'; then
+                     continue
+             fi
+             parent=`dirname $d`
+             install -d ${D}${PTEST_PATH}/$parent
+             cp --preserve=mode,timestamps -R $d ${D}${PTEST_PATH}/$parent/
+     done
+     cd "$oldwd"
+}
+
+do_install_ptest_base() {
+     test -f "${B}/.go_compiled_tests.list" || exit 0
+     install -d ${D}${PTEST_PATH}
+     go_stage_testdata
+     go_make_ptest_wrapper
+     havetests=""
+     while read test; do
+             testdir=`dirname $test`
+             testprog=`basename $test`
+             install -d ${D}${PTEST_PATH}/$testdir
+             install -m 0755 ${B}/src/$test ${D}${PTEST_PATH}/$test
+     echo "run_test $testdir $testprog || RC=1" >> ${D}${PTEST_PATH}/run-ptest
+             havetests="yes"
+     done < ${B}/.go_compiled_tests.list
+     if [ -n "$havetests" ]; then
+             echo "exit \$RC" >> ${D}${PTEST_PATH}/run-ptest
+             chmod +x ${D}${PTEST_PATH}/run-ptest
+     else
+             rm -rf ${D}${PTEST_PATH}
+     fi
+     do_install_ptest
+     chown -R root:root ${D}${PTEST_PATH}
  }
 
  EXPORT_FUNCTIONS do_unpack do_configure do_compile do_install
#9 lore raw

Re: [PATCH v5 06/13] go.bbclass: ptest cleanup and improvements

Quoted 8 lines · Matt Madison
Quoted 6 lines · Mingli

Hi Matt,

I noticed your commit is the latest update for go-dep ptest. But the go-dep ptest doesn't work in my environment. I'm trying to figure out what's wrong is here though I didn't know much about go.

Quoted 10 lines

I went back over the commits, and I don't think I did anything with go-dep specifically. I can see that the tests are failing for it, and it looks like it's because go-dep's test programs make some assumptions about the environment. For one thing, it needs the go compiler installed. It also looks like it's expecting some source files to be present... in other words, it's not really designed for a cross-build setup, with tests run on the cross-built target. It could be messy to work around that, and I'm not sure how useful it would be anyway, seeing as how go-dep is more of a build tool. Might be better to just disable ptests for it completely.

Many thanks Matt for your information!
Did you ever run go-dep ptest?
Go through the run-ptest script for go-dep, it actually runs the /usr/lib64/go-dep/ptest/github.com/golang/dep/cmd/dep/dep.test whose source file is https://github.com/golang/dep/blob/master/cmd/dep/dep_test.go.

# pwd
/usr/lib64/go-dep/ptest/github.com/golang/dep/cmd/dep
# ./dep.test
building testdep failed: exit status 1
can't load package: package .: no Go files in /usr/lib64/go-dep/ptest/github.com/golang/dep/cmd/dep

Check the logic for https://github.com/golang/dep/blob/master/cmd/dep/dep_test.go, it try to run "go build -o testdep" at its start. And the go compiler exist on our target, but I don't know what go files the dep_test.go expects.

Hi Khem,

Do you have any suggestion?

Thanks,

Quoted 186 lines

BTW, you can have the test programs generate verbose output by setting GOPTESTFLAGS = "-test.v" in the recipe, which will add that flag to their invocation in the wrapper script, or by manually running the test program on the target and passing that flag (cd into the directory where the test program is located, then run it with -test.v).

Regards,
-Matt

Quoted 174 lines

BTW, Could you help to check?

root@qemux86-64:~# cd /usr/lib64/go-dep/ptest/
root@qemux86-64:/usr/lib64/go-dep/ptest# cat run-ptest
#!/bin/sh
RC=0
run_test() (
      cd "$1"
      ((((./$2 ; echo $? >&3) | sed -r -e"s,^(PASS|SKIP|FAIL)$,\1:
$1/$2," >&4) 3>&1) | (read rc; exit $rc)) 4>&1
      exit $?)
run_test github.com/golang/dep/cmd/dep dep.test || RC=1
exit $RC
root@qemux86-64:/usr/lib64/go-dep/ptest# ./run-ptest
building testdep failed: exit status 1
can't load package: package .: no Go files in
/usr/lib64/go-dep/ptest/github.com/golang/dep/cmd/dep
root@qemux86-64:/usr/lib64/go-dep/ptest#

Thanks,

Quoted 151 lines · Matt Madison

* Don't enable verbose test output (-test.v)
by default, as it generates too much noise
for automated results parsing

* Override do_install_ptest_base in the bbclass, so recipes can provide their own modifications with do_install_ptest.

* Improve the generated run-ptest script to better handle large numbers of tests, and to generate 'status: test name' output similar to Automake tests.

* Install all non-vendored 'testdata' directories from the source into the ptest package, as some packages share test data among multiple tests.

---
   meta/classes/go.bbclass | 87 +++++++++++++++++++++++++++++--------------------
   1 file changed, 51 insertions(+), 36 deletions(-)
meta/classes/go.bbclass +51 -36
index afd68b5951..a51ba3e9f0 100644
@@ -26,7 +26,7 @@ GO_LDFLAGS ?= '-ldflags="${GO_RPATH} ${GO_LINKMODE} -extldflags '${GO_EXTLDFLAGS
   export GOBUILDFLAGS ?= "-v ${GO_LDFLAGS}"
   export GOPATH_OMIT_IN_ACTIONID ?= "1"
   export GOPTESTBUILDFLAGS ?= "${GOBUILDFLAGS} -c"
-export GOPTESTFLAGS ?= "-test.v"
+export GOPTESTFLAGS ?= ""
   GOBUILDFLAGS_prepend_task-compile = "${GO_PARALLEL_BUILD} "
 
   export GO = "${HOST_PREFIX}go"
@@ -76,7 +76,7 @@ go_list_packages() {
   }
 
   go_list_package_tests() {
-    ${GO} list -f '{{.ImportPath}} {{.TestGoFiles}}' ${GOBUILDFLAGS} ${GO_INSTALL} | \
+     ${GO} list -f '{{.ImportPath}} {{.TestGoFiles}}' ${GOBUILDFLAGS} ${GO_INSTALL} | \
               grep -v '\[\]$' | \
               egrep -v '${GO_INSTALL_FILTEROUT}' | \
               awk '{ print $1 }'
@@ -100,15 +100,16 @@ go_do_compile() {
   do_compile[dirs] =+ "${GOTMPDIR}"
   do_compile[cleandirs] = "${B}/bin ${B}/pkg"
 
-do_compile_ptest() {
+do_compile_ptest_base() {
       export TMPDIR="${GOTMPDIR}"
-    rm -f ${B}/.go_compiled_tests.list
+     rm -f ${B}/.go_compiled_tests.list
       go_list_package_tests | while read pkg; do
               cd ${B}/src/$pkg
               ${GO} test ${GOPTESTBUILDFLAGS} $pkg
               find . -mindepth 1 -maxdepth 1 -type f -name '*.test' -exec echo $pkg/{} \; | \
                       sed -e's,/\./,/,'>> ${B}/.go_compiled_tests.list
       done
+     do_compile_ptest
   }
   do_compile_ptest_base[dirs] =+ "${GOTMPDIR}"
 
@@ -124,40 +125,54 @@ go_do_install() {
       fi
   }
 
-do_install_ptest_base() {
-    test -f "${B}/.go_compiled_tests.list" || exit 0
-    tests=""
-    while read test; do
-        tests="$tests${tests:+ }${test%.test}"
-        testdir=`dirname $test`
-        install -d ${D}${PTEST_PATH}/$testdir
-        install -m 0755 ${B}/src/$test ${D}${PTEST_PATH}/$test
-        if [ -d "${B}/src/$testdir/testdata" ]; then
-            cp --preserve=mode,timestamps -R "${B}/src/$testdir/testdata" ${D}${PTEST_PATH}/$testdir
-        fi
-    done < ${B}/.go_compiled_tests.list
-    if [ -n "$tests" ]; then
-        install -d ${D}${PTEST_PATH}
-        cat >${D}${PTEST_PATH}/run-ptest <<EOF
+go_make_ptest_wrapper() {
+     cat >${D}${PTEST_PATH}/run-ptest <<EOF
   #!/bin/sh
-ANYFAILED=0
-for t in $tests; do
-    testdir=\`dirname \$t.test\`
-    if ( cd "${PTEST_PATH}/\$testdir"; "${PTEST_PATH}/\$t.test" ${GOPTESTFLAGS} | tee /dev/fd/9 | grep -q "^FAIL" ) 9>&1; then
-        ANYFAILED=1
-    fi
-done
-if [ \$ANYFAILED -ne 0 ]; then
-    echo "FAIL: ${PN}"
-    exit 1
-fi
-echo "PASS: ${PN}"
-exit 0
+RC=0
+run_test() (
+    cd "\$1"
+    ((((./\$2 ${GOPTESTFLAGS}; echo \$? >&3) | sed -r -e"s,^(PASS|SKIP|FAIL)\$,\\1: \$1/\$2," >&4) 3>&1) | (read rc; exit \$rc)) 4>&1
+    exit \$?)
   EOF
-        chmod +x ${D}${PTEST_PATH}/run-ptest
-    else
-        rm -rf ${D}${PTEST_PATH}
-    fi
+
+}
+
+go_stage_testdata() {
+     oldwd="$PWD"
+     cd ${S}/src
+     find ${GO_IMPORT} -depth -type d -name testdata | while read d; do
+             if echo "$d" | grep -q '/vendor/'; then
+                     continue
+             fi
+             parent=`dirname $d`
+             install -d ${D}${PTEST_PATH}/$parent
+             cp --preserve=mode,timestamps -R $d ${D}${PTEST_PATH}/$parent/
+     done
+     cd "$oldwd"
+}
+
+do_install_ptest_base() {
+     test -f "${B}/.go_compiled_tests.list" || exit 0
+     install -d ${D}${PTEST_PATH}
+     go_stage_testdata
+     go_make_ptest_wrapper
+     havetests=""
+     while read test; do
+             testdir=`dirname $test`
+             testprog=`basename $test`
+             install -d ${D}${PTEST_PATH}/$testdir
+             install -m 0755 ${B}/src/$test ${D}${PTEST_PATH}/$test
+     echo "run_test $testdir $testprog || RC=1" >> ${D}${PTEST_PATH}/run-ptest
+             havetests="yes"
+     done < ${B}/.go_compiled_tests.list
+     if [ -n "$havetests" ]; then
+             echo "exit \$RC" >> ${D}${PTEST_PATH}/run-ptest
+             chmod +x ${D}${PTEST_PATH}/run-ptest
+     else
+             rm -rf ${D}${PTEST_PATH}
+     fi
+     do_install_ptest
+     chown -R root:root ${D}${PTEST_PATH}
   }
 
   EXPORT_FUNCTIONS do_unpack do_configure do_compile do_install
#10 lore raw

Re: [PATCH v5 06/13] go.bbclass: ptest cleanup and improvements

Quoted 23 lines · Mingli
Quoted 8 lines · Matt Madison
Quoted 6 lines · Mingli

Hi Matt,

I noticed your commit is the latest update for go-dep ptest. But the go-dep ptest doesn't work in my environment. I'm trying to figure out what's wrong is here though I didn't know much about go.

Quoted 10 lines

I went back over the commits, and I don't think I did anything with go-dep specifically. I can see that the tests are failing for it, and it looks like it's because go-dep's test programs make some assumptions about the environment. For one thing, it needs the go compiler installed. It also looks like it's expecting some source files to be present... in other words, it's not really designed for a cross-build setup, with tests run on the cross-built target. It could be messy to work around that, and I'm not sure how useful it would be anyway, seeing as how go-dep is more of a build tool. Might be better to just disable ptests for it completely.

Quoted 6 lines

Many thanks Matt for your information!
Did you ever run go-dep ptest?
Go through the run-ptest script for go-dep, it actually runs the /usr/lib64/go-dep/ptest/github.com/golang/dep/cmd/dep/dep.test whose source file is
https://github.com/golang/dep/blob/master/cmd/dep/dep_test.go.

Yes, I see that. That main program starts by rebuilding the dep program from source, then runs the tests using that copy of the program, so it's assuming that you're still in a development environment where you can run a full go build. That's what I meant by it not being designed for a cross-build setup.

I've patched the test program to create a symlink to the installed dep program instead of rebuilding, and got further. You'll need to include 'go', 'git', and 'git-perltools' in the image to get the tests to run. Some of the test cases failed until I set GOCACHE in the environment to point to a valid path; I'm not sure why. The tests took a long time to run on my qemux86 build, though - at least 30 minutes.

Here's the patch I applied to use the already-built dep binary. An alternative approach would be to put everything in place to allow the test program to rebuild the dep binary itself, but that would drive up the time for the test run even further.

Regards,
-Matt

---
 cmd/dep/dep_test.go | 13 +++++++++----
 1 file changed, 9 insertions(+), 4 deletions(-)
(quoted diff) +0 -0

b/src/github.com/golang/dep/cmd/dep/dep_test.go
index 687eef3a..535ca56d 100644

src/github.com/golang/dep/cmd/dep/dep_test.go +0 -0
@@ -18,13 +18,18 @@ import (
 // deletes it after the tests have been run.
 // Most of this is taken from

https://github.com/golang/go/blob/master/src/cmd/go/go_test.go and reused here.
func TestMain(m *testing.M) {
- args := []string{"build", "-o", "testdep" + test.ExeSuffix}
- out, err := exec.Command("go", args...).CombinedOutput()
+ args := []string{"dep"}
+ out, err := exec.Command("which", args...).CombinedOutput()
if err != nil {
- fmt.Fprintf(os.Stderr, "building testdep failed: %v\n%s", err, out)
+ fmt.Fprintf(os.Stderr, "finding dep failed: %v\n%s", err, out)
+ os.Exit(2)
+ }
+ args = []string{"-s", string(out[:len(out)-1]), "testdep" + test.ExeSuffix}
+ out, err = exec.Command("ln", args...).CombinedOutput()
+ if err != nil {
+ fmt.Fprintf(os.Stderr, "symlinking dep failed: %v\n%s", err, out) os.Exit(2)
}
-
// Don't let these environment variables confuse the test. os.Unsetenv("GOPATH")
os.Unsetenv("GIT_ALLOW_PROTOCOL")

Signature · 1 line
2.20.1
Quoted 205 lines
# pwd
/usr/lib64/go-dep/ptest/github.com/golang/dep/cmd/dep
# ./dep.test
building testdep failed: exit status 1
can't load package: package .: no Go files in
/usr/lib64/go-dep/ptest/github.com/golang/dep/cmd/dep

Check the logic for
https://github.com/golang/dep/blob/master/cmd/dep/dep_test.go, it try to run "go build -o testdep" at its start. And the go compiler exist on our target, but I don't know what go files the dep_test.go expects.

Hi Khem,

Do you have any suggestion?

Thanks,

Quoted 186 lines

BTW, you can have the test programs generate verbose output by setting GOPTESTFLAGS = "-test.v" in the recipe, which will add that flag to their invocation in the wrapper script, or by manually running the test program on the target and passing that flag (cd into the directory where the test program is located, then run it with -test.v).

Regards,
-Matt

Quoted 174 lines

BTW, Could you help to check?

root@qemux86-64:~# cd /usr/lib64/go-dep/ptest/
root@qemux86-64:/usr/lib64/go-dep/ptest# cat run-ptest
#!/bin/sh
RC=0
run_test() (
      cd "$1"
      ((((./$2 ; echo $? >&3) | sed -r -e"s,^(PASS|SKIP|FAIL)$,\1:
$1/$2," >&4) 3>&1) | (read rc; exit $rc)) 4>&1
      exit $?)
run_test github.com/golang/dep/cmd/dep dep.test || RC=1
exit $RC
root@qemux86-64:/usr/lib64/go-dep/ptest# ./run-ptest
building testdep failed: exit status 1
can't load package: package .: no Go files in
/usr/lib64/go-dep/ptest/github.com/golang/dep/cmd/dep
root@qemux86-64:/usr/lib64/go-dep/ptest#

Thanks,

Quoted 151 lines · Matt Madison

* Don't enable verbose test output (-test.v)
by default, as it generates too much noise
for automated results parsing

* Override do_install_ptest_base in the bbclass, so recipes can provide their own modifications with do_install_ptest.

* Improve the generated run-ptest script to better handle large numbers of tests, and to generate 'status: test name' output similar to Automake tests.

* Install all non-vendored 'testdata' directories from the source into the ptest package, as some packages share test data among multiple tests.

---
   meta/classes/go.bbclass | 87 +++++++++++++++++++++++++++++--------------------
   1 file changed, 51 insertions(+), 36 deletions(-)
meta/classes/go.bbclass +51 -36
index afd68b5951..a51ba3e9f0 100644
@@ -26,7 +26,7 @@ GO_LDFLAGS ?= '-ldflags="${GO_RPATH} ${GO_LINKMODE} -extldflags '${GO_EXTLDFLAGS
   export GOBUILDFLAGS ?= "-v ${GO_LDFLAGS}"
   export GOPATH_OMIT_IN_ACTIONID ?= "1"
   export GOPTESTBUILDFLAGS ?= "${GOBUILDFLAGS} -c"
-export GOPTESTFLAGS ?= "-test.v"
+export GOPTESTFLAGS ?= ""
   GOBUILDFLAGS_prepend_task-compile = "${GO_PARALLEL_BUILD} "
 
   export GO = "${HOST_PREFIX}go"
@@ -76,7 +76,7 @@ go_list_packages() {
   }
 
   go_list_package_tests() {
-    ${GO} list -f '{{.ImportPath}} {{.TestGoFiles}}' ${GOBUILDFLAGS} ${GO_INSTALL} | \
+     ${GO} list -f '{{.ImportPath}} {{.TestGoFiles}}' ${GOBUILDFLAGS} ${GO_INSTALL} | \
               grep -v '\[\]$' | \
               egrep -v '${GO_INSTALL_FILTEROUT}' | \
               awk '{ print $1 }'
@@ -100,15 +100,16 @@ go_do_compile() {
   do_compile[dirs] =+ "${GOTMPDIR}"
   do_compile[cleandirs] = "${B}/bin ${B}/pkg"
 
-do_compile_ptest() {
+do_compile_ptest_base() {
       export TMPDIR="${GOTMPDIR}"
-    rm -f ${B}/.go_compiled_tests.list
+     rm -f ${B}/.go_compiled_tests.list
       go_list_package_tests | while read pkg; do
               cd ${B}/src/$pkg
               ${GO} test ${GOPTESTBUILDFLAGS} $pkg
               find . -mindepth 1 -maxdepth 1 -type f -name '*.test' -exec echo $pkg/{} \; | \
                       sed -e's,/\./,/,'>> ${B}/.go_compiled_tests.list
       done
+     do_compile_ptest
   }
   do_compile_ptest_base[dirs] =+ "${GOTMPDIR}"
 
@@ -124,40 +125,54 @@ go_do_install() {
       fi
   }
 
-do_install_ptest_base() {
-    test -f "${B}/.go_compiled_tests.list" || exit 0
-    tests=""
-    while read test; do
-        tests="$tests${tests:+ }${test%.test}"
-        testdir=`dirname $test`
-        install -d ${D}${PTEST_PATH}/$testdir
-        install -m 0755 ${B}/src/$test ${D}${PTEST_PATH}/$test
-        if [ -d "${B}/src/$testdir/testdata" ]; then
-            cp --preserve=mode,timestamps -R "${B}/src/$testdir/testdata" ${D}${PTEST_PATH}/$testdir
-        fi
-    done < ${B}/.go_compiled_tests.list
-    if [ -n "$tests" ]; then
-        install -d ${D}${PTEST_PATH}
-        cat >${D}${PTEST_PATH}/run-ptest <<EOF
+go_make_ptest_wrapper() {
+     cat >${D}${PTEST_PATH}/run-ptest <<EOF
   #!/bin/sh
-ANYFAILED=0
-for t in $tests; do
-    testdir=\`dirname \$t.test\`
-    if ( cd "${PTEST_PATH}/\$testdir"; "${PTEST_PATH}/\$t.test" ${GOPTESTFLAGS} | tee /dev/fd/9 | grep -q "^FAIL" ) 9>&1; then
-        ANYFAILED=1
-    fi
-done
-if [ \$ANYFAILED -ne 0 ]; then
-    echo "FAIL: ${PN}"
-    exit 1
-fi
-echo "PASS: ${PN}"
-exit 0
+RC=0
+run_test() (
+    cd "\$1"
+    ((((./\$2 ${GOPTESTFLAGS}; echo \$? >&3) | sed -r -e"s,^(PASS|SKIP|FAIL)\$,\\1: \$1/\$2," >&4) 3>&1) | (read rc; exit \$rc)) 4>&1
+    exit \$?)
   EOF
-        chmod +x ${D}${PTEST_PATH}/run-ptest
-    else
-        rm -rf ${D}${PTEST_PATH}
-    fi
+
+}
+
+go_stage_testdata() {
+     oldwd="$PWD"
+     cd ${S}/src
+     find ${GO_IMPORT} -depth -type d -name testdata | while read d; do
+             if echo "$d" | grep -q '/vendor/'; then
+                     continue
+             fi
+             parent=`dirname $d`
+             install -d ${D}${PTEST_PATH}/$parent
+             cp --preserve=mode,timestamps -R $d ${D}${PTEST_PATH}/$parent/
+     done
+     cd "$oldwd"
+}
+
+do_install_ptest_base() {
+     test -f "${B}/.go_compiled_tests.list" || exit 0
+     install -d ${D}${PTEST_PATH}
+     go_stage_testdata
+     go_make_ptest_wrapper
+     havetests=""
+     while read test; do
+             testdir=`dirname $test`
+             testprog=`basename $test`
+             install -d ${D}${PTEST_PATH}/$testdir
+             install -m 0755 ${B}/src/$test ${D}${PTEST_PATH}/$test
+     echo "run_test $testdir $testprog || RC=1" >> ${D}${PTEST_PATH}/run-ptest
+             havetests="yes"
+     done < ${B}/.go_compiled_tests.list
+     if [ -n "$havetests" ]; then
+             echo "exit \$RC" >> ${D}${PTEST_PATH}/run-ptest
+             chmod +x ${D}${PTEST_PATH}/run-ptest
+     else
+             rm -rf ${D}${PTEST_PATH}
+     fi
+     do_install_ptest
+     chown -R root:root ${D}${PTEST_PATH}
   }
 
   EXPORT_FUNCTIONS do_unpack do_configure do_compile do_install
#11 lore raw

Re: [PATCH v5 06/13] go.bbclass: ptest cleanup and improvements

Quoted 37 lines · Matt Madison
Quoted 23 lines · Mingli
Quoted 8 lines · Matt Madison
Quoted 6 lines · Mingli

Hi Matt,

I noticed your commit is the latest update for go-dep ptest. But the go-dep ptest doesn't work in my environment. I'm trying to figure out what's wrong is here though I didn't know much about go.

Quoted 10 lines

I went back over the commits, and I don't think I did anything with go-dep specifically. I can see that the tests are failing for it, and it looks like it's because go-dep's test programs make some assumptions about the environment. For one thing, it needs the go compiler installed. It also looks like it's expecting some source files to be present... in other words, it's not really designed for a cross-build setup, with tests run on the cross-built target. It could be messy to work around that, and I'm not sure how useful it would be anyway, seeing as how go-dep is more of a build tool. Might be better to just disable ptests for it completely.

Quoted 6 lines

Many thanks Matt for your information!
Did you ever run go-dep ptest?
Go through the run-ptest script for go-dep, it actually runs the /usr/lib64/go-dep/ptest/github.com/golang/dep/cmd/dep/dep.test whose source file is
https://github.com/golang/dep/blob/master/cmd/dep/dep_test.go.

Yes, I see that. That main program starts by rebuilding the dep program from source, then runs the tests using that copy of the program, so it's assuming that you're still in a development environment where you can run a full go build. That's what I meant by it not being designed for a cross-build setup.

Quoted 7 lines

I've patched the test program to create a symlink to the installed dep program instead of rebuilding, and got further. You'll need to include 'go', 'git', and 'git-perltools' in the image to get the tests to run. Some of the test cases failed until I set GOCACHE in the environment to point to a valid path; I'm not sure why. The tests took a long time to run on my qemux86 build, though - at least 30 minutes.

Thanks very much for Matt's guide!

I have applied the patch you provide to create a symlink to the installed dep program instead of rebuilding and also add go', 'git', and 'git-perltools' into the image, but there is no PASS case, all failed as attached go-dep_ptest.log.

BTW, you said you set GOCACHE, what's the valid path do you mean?

Thanks,

Quoted 35 lines

Here's the patch I applied to use the already-built dep binary. An alternative approach would be to put everything in place to allow the test program to rebuild the dep binary itself, but that would drive up the time for the test run even further.

Regards,

(quoted diff) +0 -2
-Matt
 
---
  cmd/dep/dep_test.go | 13 +++++++++----
  1 file changed, 9 insertions(+), 4 deletions(-)
src/github.com/golang/dep/cmd/dep/dep_test.go +0 -0
index 687eef3a..535ca56d 100644
@@ -18,13 +18,18 @@ import (
  // deletes it after the tests have been run.
  // Most of this is taken from

https://github.com/golang/go/blob/master/src/cmd/go/go_test.go and reused here.
func TestMain(m *testing.M) {
- args := []string{"build", "-o", "testdep" + test.ExeSuffix}
- out, err := exec.Command("go", args...).CombinedOutput()
+ args := []string{"dep"}
+ out, err := exec.Command("which", args...).CombinedOutput()
if err != nil {
- fmt.Fprintf(os.Stderr, "building testdep failed: %v\n%s", err, out)
+ fmt.Fprintf(os.Stderr, "finding dep failed: %v\n%s", err, out)
+ os.Exit(2)
+ }
+ args = []string{"-s", string(out[:len(out)-1]), "testdep" + test.ExeSuffix}
+ out, err = exec.Command("ln", args...).CombinedOutput()

Quoted 9 lines

+ if err != nil {
+ fmt.Fprintf(os.Stderr, "symlinking dep failed: %v\n%s", err, out) os.Exit(2)
}
-
// Don't let these environment variables confuse the test. os.Unsetenv("GOPATH") os.Unsetenv("GIT_ALLOW_PROTOCOL")

--- FAIL: TestIntegration (0.46s)

    --- FAIL: TestIntegration/status/revision_constraint (0.00s)
        --- FAIL: TestIntegration/status/revision_constraint/external (0.53s)
            integration_test.go:194: cmd ensure raised an unexpected error: exit status 2
    --- FAIL: TestIntegration/status/override_constraint (0.00s)
        --- FAIL: TestIntegration/status/override_constraint/external (0.52s)
            integration_test.go:194: cmd ensure raised an unexpected error: exit status 2
    --- FAIL: TestIntegration/status/old_constraints (0.00s)
        --- FAIL: TestIntegration/status/old_constraints/external (0.80s)
            integration_test.go:194: cmd ensure raised an unexpected error: exit status 2
    --- FAIL: TestIntegration/status/missing_pkgs_lock_mismatch (0.00s)
        --- FAIL: TestIntegration/status/missing_pkgs_lock_mismatch/external (0.60s)
            integration_test.go:199: exit status 1
            testcase.go:165: error did not contain expected string:
                	(GOT): The following errors occurred while deducing packages:
                  * "github.com/sdboyer/deptestdos": github.com/sdboyer/deptestdos is not a valid path for a source on github.com
                
                validateParams: could not deduce external imports' project roots
                
                	(WNT): is out of sync with imports
    --- FAIL: TestIntegration/status/case1/template (0.00s)
        --- FAIL: TestIntegration/status/case1/template/external (0.59s)
            integration_test.go:194: cmd ensure raised an unexpected error: exit status 2
    --- FAIL: TestIntegration/status/case1/table (0.00s)
        --- FAIL: TestIntegration/status/case1/table/external (0.54s)
            integration_test.go:194: cmd ensure raised an unexpected error: exit status 2
    --- FAIL: TestIntegration/status/case1/json (0.00s)
        --- FAIL: TestIntegration/status/case1/json/external (0.56s)
            integration_test.go:194: cmd ensure raised an unexpected error: exit status 2
    --- FAIL: TestIntegration/status/case1/dot (0.00s)
        --- FAIL: TestIntegration/status/case1/dot/external (0.60s)
            integration_test.go:194: cmd ensure raised an unexpected error: exit status 2
    --- FAIL: TestIntegration/init/vndr/case1 (0.00s)
        --- FAIL: TestIntegration/init/vndr/case1/external (5.66s)
            testproj.go:119: go standard error:
            testproj.go:120: build cache is disabled by GOCACHE=off, but required as of Go 1.12
                
            testproj.go:123: go [get github.com/sdboyer/deptest] failed unexpectedly: exit status 1
        --- FAIL: TestIntegration/init/vndr/case1/internal (5.33s)
            testproj.go:119: go standard error:
            testproj.go:120: build cache is disabled by GOCACHE=off, but required as of Go 1.12
                
            testproj.go:123: go [get github.com/sdboyer/deptest] failed unexpectedly: exit status 1
    --- FAIL: TestIntegration/init/skip-hidden (0.00s)
        --- FAIL: TestIntegration/init/skip-hidden/external (0.54s)
            integration_test.go:199: exit status 2
            testcase.go:187: expected command not to fail, but it did
            testcase.go:171: error raised where none was expected: 
                panic: runtime error: invalid memory address or nil pointer dereference
                [signal SIGSEGV: segmentation violation code=0x1 addr=0x3d pc=0x7f56cc475840]
                
                goroutine 1 [running]:
                regexp.(*Regexp).FindStringSubmatch(0xc0003a4900, 0xc000446de1, 0x1a, 0x56145830f980, 0xc0003a4900, 0x5614582e4e80)
                	/usr/lib64/go/src/regexp/regexp.go:982 +0x50
                github.com/golang/dep/gps.githubDeducer.deduceRoot(0xc0003a4900, 0xc000446de1, 0x1a, 0x561458210add, 0xb, 0x56145830f980, 0xc0003a4900)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/gps/deduce.go:115 +0x45
                github.com/golang/dep/gps.(*deductionCoordinator).deduceKnownPaths(0xc00045ae10, 0xc000446de1, 0x1a, 0x0, 0x0, 0x0, 0x0, 0x0, 0xc0003671a0, 0xc0003671b8)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/gps/deduce.go:668 +0x107
                github.com/golang/dep/gps.(*deductionCoordinator).deduceRootPath(0xc00045ae10, 0x561458311f00, 0xc0003280f8, 0xc000446de1, 0x1a, 0x0, 0x0, 0x0, 0x0, 0x0, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/gps/deduce.go:608 +0x35b
                github.com/golang/dep/gps.(*SourceMgr).DeduceProjectRoot(0xc0003662a0, 0xc000446de1, 0x1a, 0x561458311f40, 0x0, 0xc0000126c0, 0x1)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/gps/source_manager.go:595 +0xf4
                github.com/golang/dep.(*Project).GetDirectDependencyNames(0xc0003a5200, 0x561458315760, 0xc0003662a0, 0x1, 0xc0003a5200, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/project.go:238 +0xae
                main.(*initCommand).Run(0xc00043373a, 0xc0003a8980, 0xc000324e00, 0x0, 0x0, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/init.go:105 +0x15c
                main.(*Config).Run(0xc000366f00, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:212 +0x115d
                main.main()
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:84 +0x69a
    --- FAIL: TestIntegration/init/relative_path (0.00s)
        --- FAIL: TestIntegration/init/relative_path/external (0.50s)
            integration_test.go:199: exit status 1
            testcase.go:187: expected command not to fail, but it did
            testcase.go:171: error raised where none was expected: 
                init failed: unable to determine direct dependencies: github.com/sdboyer/deptest is not a valid path for a source on github.com
    --- FAIL: TestIntegration/init/gvt/case1 (0.00s)
        --- FAIL: TestIntegration/init/gvt/case1/external (5.81s)
            testproj.go:119: go standard error:
            testproj.go:120: build cache is disabled by GOCACHE=off, but required as of Go 1.12
                
            testproj.go:123: go [get github.com/sdboyer/deptest] failed unexpectedly: exit status 1
        --- FAIL: TestIntegration/init/gvt/case1/internal (7.97s)
            testproj.go:119: go standard error:
            testproj.go:120: build cache is disabled by GOCACHE=off, but required as of Go 1.12
                
            testproj.go:123: go [get github.com/sdboyer/deptest] failed unexpectedly: exit status 1
    --- FAIL: TestIntegration/init/govendor/case1 (0.00s)
        --- FAIL: TestIntegration/init/govendor/case1/external (8.10s)
            testproj.go:119: go standard error:
            testproj.go:120: build cache is disabled by GOCACHE=off, but required as of Go 1.12
                
            testproj.go:123: go [get github.com/sdboyer/deptest] failed unexpectedly: exit status 1
        --- FAIL: TestIntegration/init/govendor/case1/internal (7.69s)
            testproj.go:119: go standard error:
            testproj.go:120: build cache is disabled by GOCACHE=off, but required as of Go 1.12
                
            testproj.go:123: go [get github.com/sdboyer/deptest] failed unexpectedly: exit status 1
    --- FAIL: TestIntegration/init/govend/case1 (0.00s)
        --- FAIL: TestIntegration/init/govend/case1/external (8.34s)
            testproj.go:119: go standard error:
            testproj.go:120: build cache is disabled by GOCACHE=off, but required as of Go 1.12
                
            testproj.go:123: go [get github.com/sdboyer/deptest] failed unexpectedly: exit status 1
        --- FAIL: TestIntegration/init/govend/case1/internal (5.19s)
            testproj.go:119: go standard error:
            testproj.go:120: build cache is disabled by GOCACHE=off, but required as of Go 1.12
                
            testproj.go:123: go [get github.com/sdboyer/deptest] failed unexpectedly: exit status 1
    --- FAIL: TestIntegration/init/godep/case1 (0.00s)
        --- FAIL: TestIntegration/init/godep/case1/external (5.81s)
            testproj.go:119: go standard error:
            testproj.go:120: build cache is disabled by GOCACHE=off, but required as of Go 1.12
                
            testproj.go:123: go [get github.com/sdboyer/deptest] failed unexpectedly: exit status 1
        --- FAIL: TestIntegration/init/godep/case1/internal (5.11s)
            testproj.go:119: go standard error:
            testproj.go:120: build cache is disabled by GOCACHE=off, but required as of Go 1.12
                
            testproj.go:123: go [get github.com/sdboyer/deptest] failed unexpectedly: exit status 1
    --- FAIL: TestIntegration/init/glock/case1 (0.00s)
        --- FAIL: TestIntegration/init/glock/case1/external (5.51s)
            testproj.go:119: go standard error:
            testproj.go:120: build cache is disabled by GOCACHE=off, but required as of Go 1.12
                
            testproj.go:123: go [get github.com/sdboyer/deptest] failed unexpectedly: exit status 1
        --- FAIL: TestIntegration/init/glock/case1/internal (7.87s)
            testproj.go:119: go standard error:
            testproj.go:120: build cache is disabled by GOCACHE=off, but required as of Go 1.12
                
            testproj.go:123: go [get github.com/sdboyer/deptest] failed unexpectedly: exit status 1
    --- FAIL: TestIntegration/init/glide/trans-trans-unspecified (0.00s)
        --- FAIL: TestIntegration/init/glide/trans-trans-unspecified/external (0.54s)
            integration_test.go:199: exit status 1
            testcase.go:187: expected command not to fail, but it did
            testcase.go:171: error raised where none was expected: 
                init failed: unable to determine direct dependencies: github.com/ChinmayR/deptestglideA is not a valid path for a source on github.com
    --- FAIL: TestIntegration/init/glide/trans-trans (0.00s)
        --- FAIL: TestIntegration/init/glide/trans-trans/external (0.81s)
            integration_test.go:199: exit status 1
            testcase.go:187: expected command not to fail, but it did
            testcase.go:171: error raised where none was expected: 
                init failed: unable to determine direct dependencies: github.com/ChinmayR/deptestglideA is not a valid path for a source on github.com
    --- FAIL: TestIntegration/init/glide/direct-trans-no-conflict (0.00s)
        --- FAIL: TestIntegration/init/glide/direct-trans-no-conflict/external (0.84s)
            integration_test.go:199: exit status 2
            testcase.go:187: expected command not to fail, but it did
            testcase.go:171: error raised where none was expected: 
                panic: runtime error: invalid memory address or nil pointer dereference
                [signal SIGSEGV: segmentation violation code=0x1 addr=0x20 pc=0x7f07193cb840]
                
                goroutine 1 [running]:
                regexp.(*Regexp).FindStringSubmatch(0xc0003a4900, 0xc00032ef01, 0x21, 0x55963b61b980, 0xc0003a4900, 0x55963b5f0e80)
                	/usr/lib64/go/src/regexp/regexp.go:982 +0x50
                github.com/golang/dep/gps.githubDeducer.deduceRoot(0xc0003a4900, 0xc00032ef01, 0x21, 0x55963b51cadd, 0xb, 0x55963b61b980, 0xc0003a4900)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/gps/deduce.go:115 +0x45
                github.com/golang/dep/gps.(*deductionCoordinator).deduceKnownPaths(0xc00045ae10, 0xc00032ef01, 0x21, 0x0, 0x0, 0x0, 0x0, 0x0, 0xc000366a80, 0xc000366a98)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/gps/deduce.go:668 +0x107
                github.com/golang/dep/gps.(*deductionCoordinator).deduceRootPath(0xc00045ae10, 0x55963b61df00, 0xc0003280f8, 0xc00032ef01, 0x21, 0x0, 0x0, 0x0, 0x0, 0x0, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/gps/deduce.go:608 +0x35b
                github.com/golang/dep/gps.(*SourceMgr).DeduceProjectRoot(0xc000366660, 0xc00032ef01, 0x21, 0x55963b61df40, 0x0, 0xc00000f980, 0x2)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/gps/source_manager.go:595 +0xf4
                github.com/golang/dep.(*Project).GetDirectDependencyNames(0xc0003a43f0, 0x55963b621760, 0xc000366660, 0x1, 0xc0003a43f0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/project.go:238 +0xae
                main.(*initCommand).Run(0xc0004322d2, 0xc0003a8200, 0xc0003244a0, 0x0, 0x0, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/init.go:105 +0x15c
                main.(*Config).Run(0xc000366480, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:212 +0x115d
                main.main()
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:84 +0x69a
    --- FAIL: TestIntegration/init/glide/direct-trans-conflict (0.00s)
        --- FAIL: TestIntegration/init/glide/direct-trans-conflict/external (0.55s)
            integration_test.go:199: exit status 1
            testcase.go:165: error did not contain expected string:
                	(GOT): init failed: unable to determine direct dependencies: github.com/ChinmayR/deptestglideA is not a valid path for a source on github.com
                
                	(WNT): master: Could not introduce github.com/ChinmayR/deptestglideA@master, as it is not allowed by constraint ^0.1.0 from project github.com/golang/notexist.
    --- FAIL: TestIntegration/init/glide/corrupt-glide (0.00s)
        --- FAIL: TestIntegration/init/glide/corrupt-glide/external (0.52s)
            integration_test.go:199: exit status 1
            testcase.go:187: expected command not to fail, but it did
            testcase.go:171: error raised where none was expected: 
                init failed: unable to determine direct dependencies: github.com/ChinmayR/deptestglideA is not a valid path for a source on github.com
    --- FAIL: TestIntegration/init/glide/case4 (0.00s)
        --- FAIL: TestIntegration/init/glide/case4/external (5.48s)
            testproj.go:119: go standard error:
            testproj.go:120: build cache is disabled by GOCACHE=off, but required as of Go 1.12
                
            testproj.go:123: go [get github.com/sdboyer/deptest] failed unexpectedly: exit status 1
        --- FAIL: TestIntegration/init/glide/case4/internal (5.42s)
            testproj.go:119: go standard error:
            testproj.go:120: build cache is disabled by GOCACHE=off, but required as of Go 1.12
                
            testproj.go:123: go [get github.com/sdboyer/deptest] failed unexpectedly: exit status 1
    --- FAIL: TestIntegration/init/glide/case3 (0.00s)
        --- FAIL: TestIntegration/init/glide/case3/external (0.55s)
            integration_test.go:199: exit status 1
            testcase.go:187: expected command not to fail, but it did
            testcase.go:171: error raised where none was expected: 
                init failed: unable to determine direct dependencies: github.com/carolynvs/deptestglide is not a valid path for a source on github.com
    --- FAIL: TestIntegration/init/glide/case2 (0.00s)
        --- FAIL: TestIntegration/init/glide/case2/external (5.33s)
            testproj.go:119: go standard error:
            testproj.go:120: build cache is disabled by GOCACHE=off, but required as of Go 1.12
                
            testproj.go:123: go [get github.com/sdboyer/deptest] failed unexpectedly: exit status 1
        --- FAIL: TestIntegration/init/glide/case2/internal (5.24s)
            testproj.go:119: go standard error:
            testproj.go:120: build cache is disabled by GOCACHE=off, but required as of Go 1.12
                
            testproj.go:123: go [get github.com/sdboyer/deptest] failed unexpectedly: exit status 1
    --- FAIL: TestIntegration/init/glide/case1 (0.00s)
        --- FAIL: TestIntegration/init/glide/case1/external (5.46s)
            testproj.go:119: go standard error:
            testproj.go:120: build cache is disabled by GOCACHE=off, but required as of Go 1.12
                
            testproj.go:123: go [get github.com/sdboyer/deptest] failed unexpectedly: exit status 1
        --- FAIL: TestIntegration/init/glide/case1/internal (5.22s)
            testproj.go:119: go standard error:
            testproj.go:120: build cache is disabled by GOCACHE=off, but required as of Go 1.12
                
            testproj.go:123: go [get github.com/sdboyer/deptest] failed unexpectedly: exit status 1
    --- FAIL: TestIntegration/init/case4 (0.00s)
        --- FAIL: TestIntegration/init/case4/external (10.57s)
            testproj.go:119: go standard error:
            testproj.go:120: build cache is disabled by GOCACHE=off, but required as of Go 1.12
                
            testproj.go:123: go [get github.com/sdboyer/deptestdos] failed unexpectedly: exit status 1
        --- FAIL: TestIntegration/init/case4/internal (10.06s)
            testproj.go:119: go standard error:
            testproj.go:120: build cache is disabled by GOCACHE=off, but required as of Go 1.12
                
            testproj.go:123: go [get github.com/sdboyer/deptestdos] failed unexpectedly: exit status 1
    --- FAIL: TestIntegration/init/case3 (0.00s)
        --- FAIL: TestIntegration/init/case3/external (9.79s)
            testproj.go:119: go standard error:
            testproj.go:120: build cache is disabled by GOCACHE=off, but required as of Go 1.12
                
            testproj.go:123: go [get github.com/sdboyer/deptestdos] failed unexpectedly: exit status 1
        --- FAIL: TestIntegration/init/case3/internal (10.28s)
            testproj.go:119: go standard error:
            testproj.go:120: build cache is disabled by GOCACHE=off, but required as of Go 1.12
                
            testproj.go:123: go [get github.com/sdboyer/deptestdos] failed unexpectedly: exit status 1
    --- FAIL: TestIntegration/init/case2 (0.00s)
        --- FAIL: TestIntegration/init/case2/external (5.32s)
            testproj.go:119: go standard error:
            testproj.go:120: build cache is disabled by GOCACHE=off, but required as of Go 1.12
                
            testproj.go:123: go [get github.com/sdboyer/deptest] failed unexpectedly: exit status 1
        --- FAIL: TestIntegration/init/case2/internal (5.19s)
            testproj.go:119: go standard error:
            testproj.go:120: build cache is disabled by GOCACHE=off, but required as of Go 1.12
                
            testproj.go:123: go [get github.com/sdboyer/deptest] failed unexpectedly: exit status 1
    --- FAIL: TestIntegration/init/case1 (0.00s)
        --- FAIL: TestIntegration/init/case1/external (5.72s)
            testproj.go:119: go standard error:
            testproj.go:120: build cache is disabled by GOCACHE=off, but required as of Go 1.12
                
            testproj.go:123: go [get github.com/sdboyer/deptest] failed unexpectedly: exit status 1
        --- FAIL: TestIntegration/init/case1/internal (5.09s)
            testproj.go:119: go standard error:
            testproj.go:120: build cache is disabled by GOCACHE=off, but required as of Go 1.12
                
            testproj.go:123: go [get github.com/sdboyer/deptest] failed unexpectedly: exit status 1
    --- FAIL: TestIntegration/ensure/update/novendor (0.00s)
        --- FAIL: TestIntegration/ensure/update/novendor/external (0.53s)
            integration_test.go:199: exit status 2
            testcase.go:187: expected command not to fail, but it did
            testcase.go:171: error raised where none was expected: 
                panic: runtime error: makeslice: len out of range
                
                goroutine 1 [running]:
                regexp.(*Regexp).doOnePass(0xc0003a4120, 0x0, 0x0, 0x0, 0x0, 0x0, 0xc000432648, 0x5, 0x0, 0x616c6f672f6d6f63, ...)
                	/usr/lib64/go/src/regexp/exec.go:405 +0x9a8
                regexp.(*Regexp).doExecute(0xc0003a4120, 0x0, 0x0, 0x0, 0x0, 0x0, 0xc000432648, 0x5, 0x0, 0x616c6f672f6d6f63, ...)
                	/usr/lib64/go/src/regexp/exec.go:528 +0x51d
                regexp.(*Regexp).FindStringSubmatch(0xc0003a4120, 0xc000432648, 0x5, 0xc000464500, 0x7fd7c111d760, 0xc000012700)
                	/usr/lib64/go/src/regexp/regexp.go:982 +0xb7
                github.com/golang/dep/vendor/github.com/Masterminds/semver.parseConstraint(0xc000432648, 0x5, 0x1, 0xc0000131f0, 0x0, 0x0, 0xc0000131e0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/vendor/github.com/Masterminds/semver/parse.go:24 +0x61
                github.com/golang/dep/vendor/github.com/Masterminds/semver.newConstraint(0xc000432648, 0x5, 0x7fd7c064f301, 0xc000214600, 0x10, 0x10, 0x7fd7c111d760, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/vendor/github.com/Masterminds/semver/constraints.go:145 +0x3ff
                github.com/golang/dep/vendor/github.com/Masterminds/semver.NewConstraintIC(...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/vendor/github.com/Masterminds/semver/constraints.go:123
                github.com/golang/dep/gps.NewSemverConstraintIC(0xc000432648, 0x5, 0x203000, 0xc0000131a0, 0x1, 0x203000)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/gps/constraint.go:136 +0x67
                github.com/golang/dep.toProject(0xc000446f00, 0x1a, 0x0, 0x0, 0x0, 0x0, 0xc000432648, 0x5, 0x0, 0x0, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/manifest.go:509 +0x274
                github.com/golang/dep.fromRawManifest(0xc000324230, 0x1, 0x1, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/manifest.go:381 +0x288
                github.com/golang/dep.readManifest(0x55614d400c20, 0xc000212000, 0xc000212000, 0xc000000000, 0xc000212000, 0x0, 0x0, 0x7fd7c06756ef)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/manifest.go:362 +0x262
                github.com/golang/dep.(*Ctx).LoadProject(0xc0003a8980, 0x0, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/context.go:170 +0x293
                main.(*ensureCommand).Run(0xc000433740, 0xc0003a8980, 0xc000324e00, 0x0, 0x0, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/ensure.go:162 +0x7d
                main.(*Config).Run(0xc000366f00, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:212 +0x115d
                main.main()
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:84 +0x69a
    --- FAIL: TestIntegration/ensure/update/errs/spec-with-source (0.00s)
        --- FAIL: TestIntegration/ensure/update/errs/spec-with-source/external (0.53s)
            integration_test.go:199: exit status 2
            testcase.go:165: error did not contain expected string:
                	(GOT): panic: runtime error: makeslice: len out of range
                
                goroutine 1 [running]:
                regexp.(*Regexp).doOnePass(0xc0003a4120, 0x0, 0x0, 0x0, 0x0, 0x0, 0xc000432638, 0x5, 0x0, 0x616c6f672f6d6f63, ...)
                	/usr/lib64/go/src/regexp/exec.go:405 +0x9a8
                regexp.(*Regexp).doExecute(0xc0003a4120, 0x0, 0x0, 0x0, 0x0, 0x0, 0xc000432638, 0x5, 0x0, 0x616c6f672f6d6f63, ...)
                	/usr/lib64/go/src/regexp/exec.go:528 +0x51d
                regexp.(*Regexp).FindStringSubmatch(0xc0003a4120, 0xc000432638, 0x5, 0xc000466500, 0x7f3c0692c760, 0xc000012700)
                	/usr/lib64/go/src/regexp/regexp.go:982 +0xb7
                github.com/golang/dep/vendor/github.com/Masterminds/semver.parseConstraint(0xc000432638, 0x5, 0x1, 0xc0000131f0, 0x0, 0x0, 0xc0000131e0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/vendor/github.com/Masterminds/semver/parse.go:24 +0x61
                github.com/golang/dep/vendor/github.com/Masterminds/semver.newConstraint(0xc000432638, 0x5, 0x7f3c05e5e301, 0xc000214600, 0x10, 0x10, 0x7f3c0692c760, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/vendor/github.com/Masterminds/semver/constraints.go:145 +0x3ff
                github.com/golang/dep/vendor/github.com/Masterminds/semver.NewConstraintIC(...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/vendor/github.com/Masterminds/semver/constraints.go:123
                github.com/golang/dep/gps.NewSemverConstraintIC(0xc000432638, 0x5, 0x203000, 0xc0000131a0, 0x1, 0x203000)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/gps/constraint.go:136 +0x67
                github.com/golang/dep.toProject(0xc000446f00, 0x1a, 0x0, 0x0, 0x0, 0x0, 0xc000432638, 0x5, 0x0, 0x0, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/manifest.go:509 +0x274
                github.com/golang/dep.fromRawManifest(0xc000324230, 0x1, 0x1, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/manifest.go:381 +0x288
                github.com/golang/dep.readManifest(0x55ca00adec20, 0xc000212000, 0xc000212000, 0xc000000000, 0xc000212000, 0x0, 0x0, 0x7f3c05e846ef)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/manifest.go:362 +0x262
                github.com/golang/dep.(*Ctx).LoadProject(0xc0003a8980, 0x0, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/context.go:170 +0x293
                main.(*ensureCommand).Run(0xc000433740, 0xc0003a8980, 0xc000324e00, 0x1, 0x1, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/ensure.go:162 +0x7d
                main.(*Config).Run(0xc000366f00, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:212 +0x115d
                main.main()
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:84 +0x69a
                
                	(WNT): version constraint ^1.0.0 passed for github.com/sdboyer/deptest, but -update follows constraints declared in
    --- FAIL: TestIntegration/ensure/update/errs/spec-with-constraint (0.00s)
        --- FAIL: TestIntegration/ensure/update/errs/spec-with-constraint/external (1.06s)
            integration_test.go:199: exit status 1
            testcase.go:165: error did not contain expected string:
                	(GOT): The following issues were found in Gopkg.toml:
                
                  ✗ github.com/sdboyer/deptest is not a valid path for a source on github.com
                
                ProjectRoot name validation failed
                
                	(WNT): cannot specify alternate sources on -update (github.com/other/deptest)
    --- FAIL: TestIntegration/ensure/update/errs/not-in-lock (0.00s)
        --- FAIL: TestIntegration/ensure/update/errs/not-in-lock/external (1.19s)
            integration_test.go:199: exit status 2
            testcase.go:165: error did not contain expected string:
                	(GOT): panic: runtime error: makeslice: len out of range
                
                goroutine 1 [running]:
                regexp.(*Regexp).doOnePass(0xc0003ac120, 0x0, 0x0, 0x0, 0x0, 0x0, 0xc00043c668, 0x5, 0x0, 0x616c6f672f6d6f63, ...)
                	/usr/lib64/go/src/regexp/exec.go:405 +0x9a8
                regexp.(*Regexp).doExecute(0xc0003ac120, 0x0, 0x0, 0x0, 0x0, 0x0, 0xc00043c668, 0x5, 0x0, 0x616c6f672f6d6f63, ...)
                	/usr/lib64/go/src/regexp/exec.go:528 +0x51d
                regexp.(*Regexp).FindStringSubmatch(0xc0003ac120, 0xc00043c668, 0x5, 0xc000464500, 0x7f5003c15760, 0xc0000130e0)
                	/usr/lib64/go/src/regexp/regexp.go:982 +0xb7
                github.com/golang/dep/vendor/github.com/Masterminds/semver.parseConstraint(0xc00043c668, 0x5, 0x1, 0xc000013330, 0x0, 0x0, 0xc000013320)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/vendor/github.com/Masterminds/semver/parse.go:24 +0x61
                github.com/golang/dep/vendor/github.com/Masterminds/semver.newConstraint(0xc00043c668, 0x5, 0x7f5003147301, 0xc000214600, 0x10, 0x10, 0x7f5003c15760, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/vendor/github.com/Masterminds/semver/constraints.go:145 +0x3ff
                github.com/golang/dep/vendor/github.com/Masterminds/semver.NewConstraintIC(...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/vendor/github.com/Masterminds/semver/constraints.go:123
                github.com/golang/dep/gps.NewSemverConstraintIC(0xc00043c668, 0x5, 0x203000, 0xc0000132e0, 0x1, 0x203000)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/gps/constraint.go:136 +0x67
                github.com/golang/dep.toProject(0xc00044ef00, 0x1a, 0x0, 0x0, 0x0, 0x0, 0xc00043c668, 0x5, 0x0, 0x0, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/manifest.go:509 +0x274
                github.com/golang/dep.fromRawManifest(0xc000324280, 0x1, 0x1, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/manifest.go:381 +0x288
                github.com/golang/dep.readManifest(0x5609125c1c20, 0xc000212000, 0xc000212000, 0xc000000000, 0xc000212000, 0x0, 0x0, 0x7f500316d6ef)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/manifest.go:362 +0x262
                github.com/golang/dep.(*Ctx).LoadProject(0xc0003b0000, 0x0, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/context.go:170 +0x293
                main.(*ensureCommand).Run(0xc00043d740, 0xc0003b0000, 0xc000324e00, 0x1, 0x1, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/ensure.go:162 +0x7d
                main.(*Config).Run(0xc000366f00, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:212 +0x115d
                main.main()
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:84 +0x69a
                
                	(WNT): github.com/sdboyer/deptesttres is not present in Gopkg.lock, cannot -update it
    --- FAIL: TestIntegration/ensure/update/errs/nonroot-arg (0.00s)
        --- FAIL: TestIntegration/ensure/update/errs/nonroot-arg/external (1.14s)
            integration_test.go:199: exit status 2
            testcase.go:165: error did not contain expected string:
                	(GOT): panic: runtime error: makeslice: len out of range
                
                goroutine 1 [running]:
                regexp.(*Regexp).doOnePass(0xc0003a4240, 0x0, 0x0, 0x0, 0x0, 0x0, 0xc0004328d8, 0x5, 0x0, 0x616c6f672f6d6f63, ...)
                	/usr/lib64/go/src/regexp/exec.go:405 +0x9a8
                regexp.(*Regexp).doExecute(0xc0003a4240, 0x0, 0x0, 0x0, 0x0, 0x0, 0xc0004328d8, 0x5, 0x0, 0x616c6f672f6d6f63, ...)
                	/usr/lib64/go/src/regexp/exec.go:528 +0x51d
                regexp.(*Regexp).FindStringSubmatch(0xc0003a4240, 0xc0004328d8, 0x5, 0x5, 0x7f2b6e616460, 0xc000013400)
                	/usr/lib64/go/src/regexp/regexp.go:982 +0xb7
                github.com/golang/dep/vendor/github.com/Masterminds/semver.NewVersion(0xc0004328d8, 0x5, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/vendor/github.com/Masterminds/semver/version.go:81 +0x165
                github.com/golang/dep/gps.NewVersion(...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/gps/version.go:107
                github.com/golang/dep.toProject(0xc000446f00, 0x1a, 0x0, 0x0, 0x0, 0x0, 0xc0004328d8, 0x5, 0x0, 0x0, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/manifest.go:512 +0x2d6
                github.com/golang/dep.fromRawManifest(0xc0003245f0, 0x1, 0x1, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/manifest.go:381 +0x288
                github.com/golang/dep.readManifest(0x55e107176c20, 0xc000212010, 0xc000212010, 0xc000000000, 0xc000212010, 0x0, 0x0, 0x7f2b6ca2a6ef)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/manifest.go:362 +0x262
                github.com/golang/dep.(*Ctx).LoadProject(0xc0003a8080, 0x0, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/context.go:170 +0x293
                main.(*ensureCommand).Run(0xc000432256, 0xc0003a8080, 0xc0003243b0, 0x1, 0x1, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/ensure.go:162 +0x7d
                main.(*Config).Run(0xc0003662a0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:212 +0x115d
                main.main()
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:84 +0x69a
                
                	(WNT): github.com/sdboyer/deptest/subpkg is not a project root, try github.com/sdboyer/deptest instead
    --- FAIL: TestIntegration/ensure/update/errs/lockless (0.00s)
        --- FAIL: TestIntegration/ensure/update/errs/lockless/external (1.11s)
            integration_test.go:199: exit status 2
            testcase.go:165: error did not contain expected string:
                	(GOT): panic: runtime error: makeslice: len out of range
                
                goroutine 1 [running]:
                regexp.(*Regexp).doOnePass(0xc0003a4120, 0x0, 0x0, 0x0, 0x0, 0x0, 0xc000432688, 0x5, 0x0, 0x616c6f672f6d6f63, ...)
                	/usr/lib64/go/src/regexp/exec.go:405 +0x9a8
                regexp.(*Regexp).doExecute(0xc0003a4120, 0x0, 0x0, 0x0, 0x0, 0x0, 0xc000432688, 0x5, 0x0, 0x616c6f672f6d6f63, ...)
                	/usr/lib64/go/src/regexp/exec.go:528 +0x51d
                regexp.(*Regexp).FindStringSubmatch(0xc0003a4120, 0xc000432688, 0x5, 0xc000464500, 0x7f7874b9f760, 0x7f7873302248)
                	/usr/lib64/go/src/regexp/regexp.go:982 +0xb7
                github.com/golang/dep/vendor/github.com/Masterminds/semver.parseConstraint(0xc000432688, 0x5, 0x1, 0xc000013380, 0x0, 0x0, 0xc000013370)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/vendor/github.com/Masterminds/semver/parse.go:24 +0x61
                github.com/golang/dep/vendor/github.com/Masterminds/semver.newConstraint(0xc000432688, 0x5, 0x7f78740d1301, 0xc000214600, 0x10, 0x10, 0x7f7874b9f760, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/vendor/github.com/Masterminds/semver/constraints.go:145 +0x3ff
                github.com/golang/dep/vendor/github.com/Masterminds/semver.NewConstraintIC(...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/vendor/github.com/Masterminds/semver/constraints.go:123
                github.com/golang/dep/gps.NewSemverConstraintIC(0xc000432688, 0x5, 0x203000, 0xc000013330, 0x1, 0x203000)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/gps/constraint.go:136 +0x67
                github.com/golang/dep.toProject(0xc000446f00, 0x1a, 0x0, 0x0, 0x0, 0x0, 0xc000432688, 0x5, 0x0, 0x0, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/manifest.go:509 +0x274
                github.com/golang/dep.fromRawManifest(0xc000382320, 0x1, 0x1, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/manifest.go:381 +0x288
                github.com/golang/dep.readManifest(0x55cb5be8cc20, 0xc000212000, 0xc000212000, 0xc000000000, 0xc000212000, 0x0, 0x0, 0x7f78740f76ef)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/manifest.go:362 +0x262
                github.com/golang/dep.(*Ctx).LoadProject(0xc0003a8000, 0x0, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/context.go:170 +0x293
                main.(*ensureCommand).Run(0xc000432006, 0xc0003a8000, 0xc0003243f0, 0x0, 0x0, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/ensure.go:162 +0x7d
                main.(*Config).Run(0xc0003641e0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:212 +0x115d
                main.main()
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:84 +0x69a
                
                	(WNT): -update works by updating the versions recorded in Gopkg.lock, but Gopkg.lock does not exist
    --- FAIL: TestIntegration/ensure/update/desync (0.00s)
        --- FAIL: TestIntegration/ensure/update/desync/external (1.19s)
            integration_test.go:199: exit status 2
            testcase.go:187: expected command not to fail, but it did
            testcase.go:171: error raised where none was expected: 
                panic: runtime error: makeslice: len out of range
                
                goroutine 1 [running]:
                regexp.(*Regexp).doOnePass(0xc0003a4120, 0x0, 0x0, 0x0, 0x0, 0x0, 0xc0004326a0, 0x6, 0x0, 0x616c6f672f6d6f63, ...)
                	/usr/lib64/go/src/regexp/exec.go:405 +0x9a8
                regexp.(*Regexp).doExecute(0xc0003a4120, 0x0, 0x0, 0x0, 0x0, 0x0, 0xc0004326a0, 0x6, 0x0, 0x616c6f672f6d6f63, ...)
                	/usr/lib64/go/src/regexp/exec.go:528 +0x51d
                regexp.(*Regexp).FindStringSubmatch(0xc0003a4120, 0xc0004326a0, 0x6, 0xc000466500, 0x7f36c7c56760, 0x7f36c63b9248)
                	/usr/lib64/go/src/regexp/regexp.go:982 +0xb7
                github.com/golang/dep/vendor/github.com/Masterminds/semver.parseConstraint(0xc0004326a0, 0x6, 0x1, 0xc000013360, 0x0, 0x0, 0xc000013350)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/vendor/github.com/Masterminds/semver/parse.go:24 +0x61
                github.com/golang/dep/vendor/github.com/Masterminds/semver.newConstraint(0xc0004326a0, 0x6, 0x7f36c7188301, 0xc000214600, 0x10, 0x10, 0x7f36c7c56760, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/vendor/github.com/Masterminds/semver/constraints.go:145 +0x3ff
                github.com/golang/dep/vendor/github.com/Masterminds/semver.NewConstraintIC(...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/vendor/github.com/Masterminds/semver/constraints.go:123
                github.com/golang/dep/gps.NewSemverConstraintIC(0xc0004326a0, 0x6, 0x203000, 0xc000013310, 0x1, 0x203000)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/gps/constraint.go:136 +0x67
                github.com/golang/dep.toProject(0xc00044ef00, 0x1a, 0x0, 0x0, 0x0, 0x0, 0xc0004326a0, 0x6, 0x0, 0x0, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/manifest.go:509 +0x274
                github.com/golang/dep.fromRawManifest(0xc0003822d0, 0x1, 0x1, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/manifest.go:381 +0x288
                github.com/golang/dep.readManifest(0x5600aa9e9c20, 0xc000212000, 0xc000212000, 0xc000000000, 0xc000212000, 0x0, 0x0, 0x7f36c71ae6ef)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/manifest.go:362 +0x262
                github.com/golang/dep.(*Ctx).LoadProject(0xc0003a8000, 0x0, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/context.go:170 +0x293
                main.(*ensureCommand).Run(0xc000432006, 0xc0003a8000, 0xc000324130, 0x0, 0x0, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/ensure.go:162 +0x7d
                main.(*Config).Run(0xc0003641e0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:212 +0x115d
                main.main()
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:84 +0x69a
    --- FAIL: TestIntegration/ensure/update/case1 (0.00s)
        --- FAIL: TestIntegration/ensure/update/case1/external (1.11s)
            integration_test.go:199: exit status 2
            testcase.go:187: expected command not to fail, but it did
            testcase.go:171: error raised where none was expected: 
                panic: runtime error: makeslice: len out of range
                
                goroutine 1 [running]:
                regexp.(*Regexp).doOnePass(0xc0003a4120, 0x0, 0x0, 0x0, 0x0, 0x0, 0xc000432680, 0x6, 0x0, 0x616c6f672f6d6f63, ...)
                	/usr/lib64/go/src/regexp/exec.go:405 +0x9a8
                regexp.(*Regexp).doExecute(0xc0003a4120, 0x0, 0x0, 0x0, 0x0, 0x0, 0xc000432680, 0x6, 0x0, 0x616c6f672f6d6f63, ...)
                	/usr/lib64/go/src/regexp/exec.go:528 +0x51d
                regexp.(*Regexp).FindStringSubmatch(0xc0003a4120, 0xc000432680, 0x6, 0xc00046e500, 0x7fab13ab3760, 0xc0000130f0)
                	/usr/lib64/go/src/regexp/regexp.go:982 +0xb7
                github.com/golang/dep/vendor/github.com/Masterminds/semver.parseConstraint(0xc000432680, 0x6, 0x1, 0xc000013340, 0x0, 0x0, 0xc000013330)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/vendor/github.com/Masterminds/semver/parse.go:24 +0x61
                github.com/golang/dep/vendor/github.com/Masterminds/semver.newConstraint(0xc000432680, 0x6, 0x7fab12fe5301, 0xc000214600, 0x10, 0x10, 0x7fab13ab3760, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/vendor/github.com/Masterminds/semver/constraints.go:145 +0x3ff
                github.com/golang/dep/vendor/github.com/Masterminds/semver.NewConstraintIC(...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/vendor/github.com/Masterminds/semver/constraints.go:123
                github.com/golang/dep/gps.NewSemverConstraintIC(0xc000432680, 0x6, 0x203000, 0xc0000132f0, 0x1, 0x203000)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/gps/constraint.go:136 +0x67
                github.com/golang/dep.toProject(0xc00044ef00, 0x1a, 0x0, 0x0, 0x0, 0x0, 0xc000432680, 0x6, 0x0, 0x0, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/manifest.go:509 +0x274
                github.com/golang/dep.fromRawManifest(0xc000324280, 0x1, 0x1, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/manifest.go:381 +0x288
                github.com/golang/dep.readManifest(0x55da1d474c20, 0xc000212000, 0xc000212000, 0xc000000000, 0xc000212000, 0x0, 0x0, 0x7fab1300b6ef)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/manifest.go:362 +0x262
                github.com/golang/dep.(*Ctx).LoadProject(0xc0003a8000, 0x0, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/context.go:170 +0x293
                main.(*ensureCommand).Run(0xc000433740, 0xc0003a8000, 0xc000324e00, 0x1, 0x1, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/ensure.go:162 +0x7d
                main.(*Config).Run(0xc000366f00, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:212 +0x115d
                main.main()
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:84 +0x69a
    --- FAIL: TestIntegration/ensure/pkg-ignored/wildcard-ignore (0.00s)
        --- FAIL: TestIntegration/ensure/pkg-ignored/wildcard-ignore/external (1.06s)
            integration_test.go:199: exit status 1
            testcase.go:187: expected command not to fail, but it did
            testcase.go:171: error raised where none was expected: 
                The following issues were found in Gopkg.toml:
                
                  ✗ github.com/sdboyer/deptest is not a valid path for a source on github.com
                
                ProjectRoot name validation failed
    --- FAIL: TestIntegration/ensure/noverify/hash_mismatch (0.00s)
        --- FAIL: TestIntegration/ensure/noverify/hash_mismatch/external (1.00s)
            integration_test.go:194: cmd ensure raised an unexpected error: exit status 2
    --- FAIL: TestIntegration/ensure/empty/case3 (0.00s)
        --- FAIL: TestIntegration/ensure/empty/case3/external (1.07s)
            integration_test.go:199: exit status 2
            testcase.go:187: expected command not to fail, but it did
            testcase.go:171: error raised where none was expected: 
                panic: runtime error: makeslice: len out of range
                
                goroutine 9 [running]:
                regexp.(*Regexp).doOnePass(0xc0003a4900, 0x0, 0x0, 0x0, 0x0, 0x0, 0xc00044f240, 0x1a, 0x0, 0x75687469676874, ...)
                	/usr/lib64/go/src/regexp/exec.go:405 +0x9a8
                regexp.(*Regexp).doExecute(0xc0003a4900, 0x0, 0x0, 0x0, 0x0, 0x0, 0xc00044f240, 0x1a, 0x0, 0x75687469676874, ...)
                	/usr/lib64/go/src/regexp/exec.go:528 +0x51d
                regexp.(*Regexp).FindStringSubmatch(0xc0003a4900, 0xc00044f240, 0x1a, 0x55bd229b4980, 0xc0003a4900, 0x55bd22989e80)
                	/usr/lib64/go/src/regexp/regexp.go:982 +0xb7
                github.com/golang/dep/gps.githubDeducer.deduceRoot(0xc0003a4900, 0xc00044f240, 0x1a, 0x55bd228b5add, 0xb, 0x55bd229b4980, 0xc0003a4900)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/gps/deduce.go:115 +0x45
                github.com/golang/dep/gps.(*deductionCoordinator).deduceKnownPaths(0xc000461b00, 0xc00044f240, 0x1a, 0x0, 0x0, 0x0, 0x0, 0x0, 0xc000365320, 0xc000365338)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/gps/deduce.go:668 +0x107
                github.com/golang/dep/gps.(*deductionCoordinator).deduceRootPath(0xc000461b00, 0x55bd229b6f00, 0xc0003260f8, 0xc00044f240, 0x1a, 0x0, 0x0, 0x0, 0x0, 0x0, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/gps/deduce.go:608 +0x35b
                github.com/golang/dep/gps.(*SourceMgr).DeduceProjectRoot(0xc000365080, 0xc00044f240, 0x1a, 0x0, 0x0, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/gps/source_manager.go:595 +0xf4
                github.com/golang/dep.ValidateProjectRoots.func1(0xc00044f240, 0x1a)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/manifest.go:306 +0xab
                created by github.com/golang/dep.ValidateProjectRoots
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/manifest.go:316 +0x1b2
    --- FAIL: TestIntegration/ensure/empty/case2 (0.00s)
        --- FAIL: TestIntegration/ensure/empty/case2/external (0.95s)
            integration_test.go:199: exit status 1
            testcase.go:187: expected command not to fail, but it did
            testcase.go:171: error raised where none was expected: 
                The following issues were found in Gopkg.toml:
                
                  ✗ github.com/sdboyer/deptest is not a valid path for a source on github.com
                
                ProjectRoot name validation failed
    --- FAIL: TestIntegration/ensure/empty/case1 (0.00s)
        --- FAIL: TestIntegration/ensure/empty/case1/external (0.59s)
            integration_test.go:194: cmd init raised an unexpected error: exit status 1
    --- FAIL: TestIntegration/ensure/default/nocode-vendoronly (0.00s)
        --- FAIL: TestIntegration/ensure/default/nocode-vendoronly/external (0.69s)
            integration_test.go:199: exit status 2
            testcase.go:187: expected command not to fail, but it did
            testcase.go:171: error raised where none was expected: 
                panic: runtime error: invalid memory address or nil pointer dereference
                [signal SIGSEGV: segmentation violation code=0x1 addr=0x20 pc=0x7f617e2f6840]
                
                goroutine 9 [running]:
                regexp.(*Regexp).FindStringSubmatch(0xc0003a4900, 0xc000446f00, 0x1a, 0x55ff1442a980, 0xc0003a4900, 0x55ff143ffe80)
                	/usr/lib64/go/src/regexp/regexp.go:982 +0x50
                github.com/golang/dep/gps.githubDeducer.deduceRoot(0xc0003a4900, 0xc000446f00, 0x1a, 0x55ff1432badd, 0xb, 0x55ff1442a980, 0xc0003a4900)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/gps/deduce.go:115 +0x45
                github.com/golang/dep/gps.(*deductionCoordinator).deduceKnownPaths(0xc00045b560, 0xc000446f00, 0x1a, 0x0, 0x0, 0x0, 0x0, 0x0, 0xc000365080, 0xc000365098)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/gps/deduce.go:668 +0x107
                github.com/golang/dep/gps.(*deductionCoordinator).deduceRootPath(0xc00045b560, 0x55ff1442cf00, 0xc0003280f8, 0xc000446f00, 0x1a, 0x0, 0x0, 0x0, 0x0, 0x0, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/gps/deduce.go:608 +0x35b
                github.com/golang/dep/gps.(*SourceMgr).DeduceProjectRoot(0xc000364de0, 0xc000446f00, 0x1a, 0x0, 0x0, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/gps/source_manager.go:595 +0xf4
                github.com/golang/dep.ValidateProjectRoots.func1(0xc000446f00, 0x1a)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/manifest.go:306 +0xab
                created by github.com/golang/dep.ValidateProjectRoots
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/manifest.go:316 +0x1b2
    --- FAIL: TestIntegration/ensure/default/hashneq-vendoronly (0.00s)
        --- FAIL: TestIntegration/ensure/default/hashneq-vendoronly/external (0.54s)
            integration_test.go:199: exit status 2
            testcase.go:187: expected command not to fail, but it did
            testcase.go:171: error raised where none was expected: 
                panic: runtime error: makeslice: len out of range
                
                goroutine 1 [running]:
                regexp.(*Regexp).doOnePass(0xc0003a4120, 0x0, 0x0, 0x0, 0x0, 0x0, 0xc000432648, 0x5, 0x0, 0x616c6f672f6d6f63, ...)
                	/usr/lib64/go/src/regexp/exec.go:405 +0x9a8
                regexp.(*Regexp).doExecute(0xc0003a4120, 0x0, 0x0, 0x0, 0x0, 0x0, 0xc000432648, 0x5, 0x0, 0x616c6f672f6d6f63, ...)
                	/usr/lib64/go/src/regexp/exec.go:528 +0x51d
                regexp.(*Regexp).FindStringSubmatch(0xc0003a4120, 0xc000432648, 0x5, 0xc000464500, 0x7f05217ee760, 0xc000012700)
                	/usr/lib64/go/src/regexp/regexp.go:982 +0xb7
                github.com/golang/dep/vendor/github.com/Masterminds/semver.parseConstraint(0xc000432648, 0x5, 0x1, 0xc0000131f0, 0x0, 0x0, 0xc0000131e0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/vendor/github.com/Masterminds/semver/parse.go:24 +0x61
                github.com/golang/dep/vendor/github.com/Masterminds/semver.newConstraint(0xc000432648, 0x5, 0x7f0520d20301, 0xc000214600, 0x10, 0x10, 0x7f05217ee760, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/vendor/github.com/Masterminds/semver/constraints.go:145 +0x3ff
                github.com/golang/dep/vendor/github.com/Masterminds/semver.NewConstraintIC(...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/vendor/github.com/Masterminds/semver/constraints.go:123
                github.com/golang/dep/gps.NewSemverConstraintIC(0xc000432648, 0x5, 0x203000, 0xc0000131a0, 0x1, 0x203000)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/gps/constraint.go:136 +0x67
                github.com/golang/dep.toProject(0xc000446f00, 0x1a, 0x0, 0x0, 0x0, 0x0, 0xc000432648, 0x5, 0x0, 0x0, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/manifest.go:509 +0x274
                github.com/golang/dep.fromRawManifest(0xc000382190, 0x1, 0x1, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/manifest.go:381 +0x288
                github.com/golang/dep.readManifest(0x559c3c964c20, 0xc000212000, 0xc000212000, 0xc000000000, 0xc000212000, 0x0, 0x0, 0x7f0520d466ef)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/manifest.go:362 +0x262
                github.com/golang/dep.(*Ctx).LoadProject(0xc0003a8980, 0x0, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/context.go:170 +0x293
                main.(*ensureCommand).Run(0xc000433740, 0xc0003a8980, 0xc000325670, 0x0, 0x0, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/ensure.go:162 +0x7d
                main.(*Config).Run(0xc000364f00, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:212 +0x115d
                main.main()
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:84 +0x69a
    --- FAIL: TestIntegration/ensure/default/hasheq-novendor-dry (0.00s)
        --- FAIL: TestIntegration/ensure/default/hasheq-novendor-dry/external (0.53s)
            integration_test.go:199: exit status 2
            testcase.go:187: expected command not to fail, but it did
            testcase.go:171: error raised where none was expected: 
                panic: runtime error: makeslice: len out of range
                
                goroutine 1 [running]:
                regexp.(*Regexp).doOnePass(0xc0003a4120, 0x0, 0x0, 0x0, 0x0, 0x0, 0xc000432688, 0x5, 0x0, 0x616c6f672f6d6f63, ...)
                	/usr/lib64/go/src/regexp/exec.go:405 +0x9a8
                regexp.(*Regexp).doExecute(0xc0003a4120, 0x0, 0x0, 0x0, 0x0, 0x0, 0xc000432688, 0x5, 0x0, 0x616c6f672f6d6f63, ...)
                	/usr/lib64/go/src/regexp/exec.go:528 +0x51d
                regexp.(*Regexp).FindStringSubmatch(0xc0003a4120, 0xc000432688, 0x5, 0xc000464500, 0x7f8b6f4b4760, 0x7f8b6dc17248)
                	/usr/lib64/go/src/regexp/regexp.go:982 +0xb7
                github.com/golang/dep/vendor/github.com/Masterminds/semver.parseConstraint(0xc000432688, 0x5, 0x1, 0xc000013380, 0x0, 0x0, 0xc000013370)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/vendor/github.com/Masterminds/semver/parse.go:24 +0x61
                github.com/golang/dep/vendor/github.com/Masterminds/semver.newConstraint(0xc000432688, 0x5, 0x7f8b6e9e6301, 0xc000214600, 0x10, 0x10, 0x7f8b6f4b4760, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/vendor/github.com/Masterminds/semver/constraints.go:145 +0x3ff
                github.com/golang/dep/vendor/github.com/Masterminds/semver.NewConstraintIC(...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/vendor/github.com/Masterminds/semver/constraints.go:123
                github.com/golang/dep/gps.NewSemverConstraintIC(0xc000432688, 0x5, 0x203000, 0xc000013330, 0x1, 0x203000)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/gps/constraint.go:136 +0x67
                github.com/golang/dep.toProject(0xc000446f00, 0x1a, 0x0, 0x0, 0x0, 0x0, 0xc000432688, 0x5, 0x0, 0x0, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/manifest.go:509 +0x274
                github.com/golang/dep.fromRawManifest(0xc000324410, 0x1, 0x1, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/manifest.go:381 +0x288
                github.com/golang/dep.readManifest(0x564c359b5c20, 0xc000212000, 0xc000212000, 0xc000000000, 0xc000212000, 0x0, 0x0, 0x7f8b6ea0c6ef)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/manifest.go:362 +0x262
                github.com/golang/dep.(*Ctx).LoadProject(0xc0003a8000, 0x0, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/context.go:170 +0x293
                main.(*ensureCommand).Run(0xc000432006, 0xc0003a8000, 0xc0003241d0, 0x0, 0x0, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/ensure.go:162 +0x7d
                main.(*Config).Run(0xc0003661e0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:212 +0x115d
                main.main()
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:84 +0x69a
    --- FAIL: TestIntegration/ensure/default/hasheq-novendor (0.00s)
        --- FAIL: TestIntegration/ensure/default/hasheq-novendor/external (0.54s)
            integration_test.go:199: exit status 2
            testcase.go:187: expected command not to fail, but it did
            testcase.go:171: error raised where none was expected: 
                panic: runtime error: makeslice: len out of range
                
                goroutine 1 [running]:
                regexp.(*Regexp).doOnePass(0xc0003ac120, 0x0, 0x0, 0x0, 0x0, 0x0, 0xc00043c688, 0x5, 0x0, 0x616c6f672f6d6f63, ...)
                	/usr/lib64/go/src/regexp/exec.go:405 +0x9a8
                regexp.(*Regexp).doExecute(0xc0003ac120, 0x0, 0x0, 0x0, 0x0, 0x0, 0xc00043c688, 0x5, 0x0, 0x616c6f672f6d6f63, ...)
                	/usr/lib64/go/src/regexp/exec.go:528 +0x51d
                regexp.(*Regexp).FindStringSubmatch(0xc0003ac120, 0xc00043c688, 0x5, 0xc000464500, 0x7f24c7f17760, 0x7f24c667a248)
                	/usr/lib64/go/src/regexp/regexp.go:982 +0xb7
                github.com/golang/dep/vendor/github.com/Masterminds/semver.parseConstraint(0xc00043c688, 0x5, 0x1, 0xc000013380, 0x0, 0x0, 0xc000013370)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/vendor/github.com/Masterminds/semver/parse.go:24 +0x61
                github.com/golang/dep/vendor/github.com/Masterminds/semver.newConstraint(0xc00043c688, 0x5, 0x7f24c7449301, 0xc000214600, 0x10, 0x10, 0x7f24c7f17760, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/vendor/github.com/Masterminds/semver/constraints.go:145 +0x3ff
                github.com/golang/dep/vendor/github.com/Masterminds/semver.NewConstraintIC(...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/vendor/github.com/Masterminds/semver/constraints.go:123
                github.com/golang/dep/gps.NewSemverConstraintIC(0xc00043c688, 0x5, 0x203000, 0xc000013330, 0x1, 0x203000)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/gps/constraint.go:136 +0x67
                github.com/golang/dep.toProject(0xc00044ef00, 0x1a, 0x0, 0x0, 0x0, 0x0, 0xc00043c688, 0x5, 0x0, 0x0, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/manifest.go:509 +0x274
                github.com/golang/dep.fromRawManifest(0xc00038a2d0, 0x1, 0x1, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/manifest.go:381 +0x288
                github.com/golang/dep.readManifest(0x55974a8f4c20, 0xc000212000, 0xc000212000, 0xc000000000, 0xc000212000, 0x0, 0x0, 0x7f24c746f6ef)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/manifest.go:362 +0x262
                github.com/golang/dep.(*Ctx).LoadProject(0xc0003b0000, 0x0, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/context.go:170 +0x293
                main.(*ensureCommand).Run(0xc00043c006, 0xc0003b0000, 0xc000324370, 0x0, 0x0, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/ensure.go:162 +0x7d
                main.(*Config).Run(0xc0003641e0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:212 +0x115d
                main.main()
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:84 +0x69a
    --- FAIL: TestIntegration/ensure/default/hasheq-dry (0.00s)
        --- FAIL: TestIntegration/ensure/default/hasheq-dry/external (0.56s)
            integration_test.go:199: exit status 2
            testcase.go:187: expected command not to fail, but it did
            testcase.go:171: error raised where none was expected: 
                panic: runtime error: invalid memory address or nil pointer dereference
                [signal SIGSEGV: segmentation violation code=0x1 addr=0x20 pc=0x7f34c05bf840]
                
                goroutine 1 [running]:
                regexp.(*Regexp).FindStringSubmatch(0xc0003a4240, 0xc000432ac0, 0x6, 0x6, 0x7f34c1cce460, 0x7f34c01dca00)
                	/usr/lib64/go/src/regexp/regexp.go:982 +0x50
                github.com/golang/dep/vendor/github.com/Masterminds/semver.NewVersion(0xc000432ac0, 0x6, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/vendor/github.com/Masterminds/semver/version.go:81 +0x165
                github.com/golang/dep/gps.NewVersion(...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/gps/version.go:107
                github.com/golang/dep.fromRawLock(0xc000432ba2, 0x3, 0x1, 0xc000433a28, 0x8, 0x1, 0x0, 0x0, 0x0, 0xc0003a4240, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/lock.go:96 +0x2a3
                github.com/golang/dep.readLock(0x56153803ec20, 0xc000212078, 0xc000212078, 0xc000000000, 0xc000212078)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/lock.go:74 +0x1d2
                github.com/golang/dep.(*Ctx).LoadProject(0xc0003a8980, 0x0, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/context.go:189 +0x517
                main.(*ensureCommand).Run(0xc000433740, 0xc0003a8980, 0xc000325670, 0x0, 0x0, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/ensure.go:162 +0x7d
                main.(*Config).Run(0xc000364f00, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:212 +0x115d
                main.main()
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:84 +0x69a
    --- FAIL: TestIntegration/ensure/default/hasheq (0.00s)
        --- FAIL: TestIntegration/ensure/default/hasheq/external (0.53s)
            integration_test.go:199: exit status 2
            testcase.go:187: expected command not to fail, but it did
            testcase.go:171: error raised where none was expected: 
                panic: runtime error: makeslice: len out of range
                
                goroutine 1 [running]:
                regexp.(*Regexp).doOnePass(0xc0003a4120, 0x0, 0x0, 0x0, 0x0, 0x0, 0xc000432678, 0x5, 0x0, 0x616c6f672f6d6f63, ...)
                	/usr/lib64/go/src/regexp/exec.go:405 +0x9a8
                regexp.(*Regexp).doExecute(0xc0003a4120, 0x0, 0x0, 0x0, 0x0, 0x0, 0xc000432678, 0x5, 0x0, 0x616c6f672f6d6f63, ...)
                	/usr/lib64/go/src/regexp/exec.go:528 +0x51d
                regexp.(*Regexp).FindStringSubmatch(0xc0003a4120, 0xc000432678, 0x5, 0xc000464500, 0x7f076b5f0760, 0x7f0769d53248)
                	/usr/lib64/go/src/regexp/regexp.go:982 +0xb7
                github.com/golang/dep/vendor/github.com/Masterminds/semver.parseConstraint(0xc000432678, 0x5, 0x1, 0xc000013380, 0x0, 0x0, 0xc000013370)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/vendor/github.com/Masterminds/semver/parse.go:24 +0x61
                github.com/golang/dep/vendor/github.com/Masterminds/semver.newConstraint(0xc000432678, 0x5, 0x7f076ab22301, 0xc000214660, 0x10, 0x10, 0x7f076b5f0760, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/vendor/github.com/Masterminds/semver/constraints.go:145 +0x3ff
                github.com/golang/dep/vendor/github.com/Masterminds/semver.NewConstraintIC(...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/vendor/github.com/Masterminds/semver/constraints.go:123
                github.com/golang/dep/gps.NewSemverConstraintIC(0xc000432678, 0x5, 0x203000, 0xc000013330, 0x1, 0x203000)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/gps/constraint.go:136 +0x67
                github.com/golang/dep.toProject(0xc000446f00, 0x1a, 0x0, 0x0, 0x0, 0x0, 0xc000432678, 0x5, 0x0, 0x0, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/manifest.go:509 +0x274
                github.com/golang/dep.fromRawManifest(0xc0003822d0, 0x1, 0x1, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/manifest.go:381 +0x288
                github.com/golang/dep.readManifest(0x556e07693c20, 0xc000212000, 0xc000212000, 0xc000000000, 0xc000212000, 0x0, 0x0, 0x7f076ab486ef)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/manifest.go:362 +0x262
                github.com/golang/dep.(*Ctx).LoadProject(0xc0003a8000, 0x0, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/context.go:170 +0x293
                main.(*ensureCommand).Run(0xc000432004, 0xc0003a8000, 0xc000458680, 0x0, 0x0, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/ensure.go:162 +0x7d
                main.(*Config).Run(0xc0003641e0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:212 +0x115d
                main.main()
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:84 +0x69a
    --- FAIL: TestIntegration/ensure/default/errs/specargs (0.00s)
        --- FAIL: TestIntegration/ensure/default/errs/specargs/external (0.61s)
            integration_test.go:199: exit status 2
            testcase.go:165: error did not contain expected string:
                	(GOT): panic: runtime error: makeslice: len out of range
                
                goroutine 1 [running]:
                regexp.(*Regexp).doOnePass(0xc0003a4120, 0x0, 0x0, 0x0, 0x0, 0x0, 0xc0004326a8, 0x5, 0x0, 0x616c6f672f6d6f63, ...)
                	/usr/lib64/go/src/regexp/exec.go:405 +0x9a8
                regexp.(*Regexp).doExecute(0xc0003a4120, 0x0, 0x0, 0x0, 0x0, 0x0, 0xc0004326a8, 0x5, 0x0, 0x616c6f672f6d6f63, ...)
                	/usr/lib64/go/src/regexp/exec.go:528 +0x51d
                regexp.(*Regexp).FindStringSubmatch(0xc0003a4120, 0xc0004326a8, 0x5, 0xc00046e500, 0x7fbf4b8d8760, 0x7fbf4a03b248)
                	/usr/lib64/go/src/regexp/regexp.go:982 +0xb7
                github.com/golang/dep/vendor/github.com/Masterminds/semver.parseConstraint(0xc0004326a8, 0x5, 0x1, 0xc000013390, 0x0, 0x0, 0xc000013380)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/vendor/github.com/Masterminds/semver/parse.go:24 +0x61
                github.com/golang/dep/vendor/github.com/Masterminds/semver.newConstraint(0xc0004326a8, 0x5, 0x7fbf4ae0a301, 0xc000214600, 0x10, 0x10, 0x7fbf4b8d8760, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/vendor/github.com/Masterminds/semver/constraints.go:145 +0x3ff
                github.com/golang/dep/vendor/github.com/Masterminds/semver.NewConstraintIC(...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/vendor/github.com/Masterminds/semver/constraints.go:123
                github.com/golang/dep/gps.NewSemverConstraintIC(0xc0004326a8, 0x5, 0x203000, 0xc000013340, 0x1, 0x203000)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/gps/constraint.go:136 +0x67
                github.com/golang/dep.toProject(0xc00044ef00, 0x1a, 0x0, 0x0, 0x0, 0x0, 0xc0004326a8, 0x5, 0x0, 0x0, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/manifest.go:509 +0x274
                github.com/golang/dep.fromRawManifest(0xc0003823c0, 0x1, 0x1, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/manifest.go:381 +0x288
                github.com/golang/dep.readManifest(0x5575d0ee1c20, 0xc000212000, 0xc000212000, 0xc000000000, 0xc000212000, 0x0, 0x0, 0x7fbf4ae306ef)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/manifest.go:362 +0x262
                github.com/golang/dep.(*Ctx).LoadProject(0xc0003a8000, 0x0, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/context.go:170 +0x293
                main.(*ensureCommand).Run(0xc000432026, 0xc0003a8000, 0xc0003243f0, 0x1, 0x1, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/ensure.go:162 +0x7d
                main.(*Config).Run(0xc0003641e0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:212 +0x115d
                main.main()
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:84 +0x69a
                
                	(WNT): dep ensure only takes spec arguments with -add or -update
    --- FAIL: TestIntegration/ensure/default/errs/lockless-vendoronly (0.00s)
        --- FAIL: TestIntegration/ensure/default/errs/lockless-vendoronly/external (0.57s)
            integration_test.go:199: exit status 2
            testcase.go:165: error did not contain expected string:
                	(GOT): panic: runtime error: makeslice: len out of range
                
                goroutine 1 [running]:
                regexp.(*Regexp).doOnePass(0xc0003a6120, 0x0, 0x0, 0x0, 0x0, 0x0, 0xc000432688, 0x5, 0x0, 0x616c6f672f6d6f63, ...)
                	/usr/lib64/go/src/regexp/exec.go:405 +0x9a8
                regexp.(*Regexp).doExecute(0xc0003a6120, 0x0, 0x0, 0x0, 0x0, 0x0, 0xc000432688, 0x5, 0x0, 0x616c6f672f6d6f63, ...)
                	/usr/lib64/go/src/regexp/exec.go:528 +0x51d
                regexp.(*Regexp).FindStringSubmatch(0xc0003a6120, 0xc000432688, 0x5, 0xc000466500, 0x7f3adb8a2760, 0x7f3ada005248)
                	/usr/lib64/go/src/regexp/regexp.go:982 +0xb7
                github.com/golang/dep/vendor/github.com/Masterminds/semver.parseConstraint(0xc000432688, 0x5, 0x1, 0xc000013380, 0x0, 0x0, 0xc000013370)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/vendor/github.com/Masterminds/semver/parse.go:24 +0x61
                github.com/golang/dep/vendor/github.com/Masterminds/semver.newConstraint(0xc000432688, 0x5, 0x7f3adadd4301, 0xc000214600, 0x10, 0x10, 0x7f3adb8a2760, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/vendor/github.com/Masterminds/semver/constraints.go:145 +0x3ff
                github.com/golang/dep/vendor/github.com/Masterminds/semver.NewConstraintIC(...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/vendor/github.com/Masterminds/semver/constraints.go:123
                github.com/golang/dep/gps.NewSemverConstraintIC(0xc000432688, 0x5, 0x203000, 0xc000013330, 0x1, 0x203000)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/gps/constraint.go:136 +0x67
                github.com/golang/dep.toProject(0xc000446f00, 0x1a, 0x0, 0x0, 0x0, 0x0, 0xc000432688, 0x5, 0x0, 0x0, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/manifest.go:509 +0x274
                github.com/golang/dep.fromRawManifest(0xc000382320, 0x1, 0x1, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/manifest.go:381 +0x288
                github.com/golang/dep.readManifest(0x56056fbedc20, 0xc000212000, 0xc000212000, 0xc000000000, 0xc000212000, 0x0, 0x0, 0x7f3adadfa6ef)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/manifest.go:362 +0x262
                github.com/golang/dep.(*Ctx).LoadProject(0xc0003aa000, 0x0, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/context.go:170 +0x293
                main.(*ensureCommand).Run(0xc000432006, 0xc0003aa000, 0xc0003243f0, 0x0, 0x0, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/ensure.go:162 +0x7d
                main.(*Config).Run(0xc0003641e0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:212 +0x115d
                main.main()
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:84 +0x69a
                
                	(WNT): no Gopkg.lock exists from which to populate vendor/
    --- FAIL: TestIntegration/ensure/add/exists-manifest-constraint (0.00s)
        --- FAIL: TestIntegration/ensure/add/exists-manifest-constraint/external (0.51s)
            integration_test.go:199: exit status 1
            testcase.go:187: expected command not to fail, but it did
            testcase.go:171: error raised where none was expected: 
                The following issues were found in Gopkg.toml:
                
                  ✗ github.com/sdboyer/deptest is not a valid path for a source on github.com
                  ✗ github.com/sdboyer/deptesttres is not a valid path for a source on github.com
                
                ProjectRoot name validation failed
    --- FAIL: TestIntegration/ensure/add/errs/self-add/case2 (0.00s)
        --- FAIL: TestIntegration/ensure/add/errs/self-add/case2/external (1.05s)
            integration_test.go:199: exit status 1
            testcase.go:165: error did not contain expected string:
                	(GOT): (1/1) github.com/golang/notexist
                
                Failed to add the dependencies:
                
                  ✗ could not infer project root from dependency path: github.com/golang/notexist: github.com/golang/notexist is not a valid path for a source on github.com
                
                adding dependencies failed
                
                	(WNT): cannot add current project to itself
    --- FAIL: TestIntegration/ensure/add/errs/self-add/case1 (0.00s)
        --- FAIL: TestIntegration/ensure/add/errs/self-add/case1/external (0.56s)
            integration_test.go:199: exit status 2
            testcase.go:165: error did not contain expected string:
                	(GOT): panic: runtime error: makeslice: len out of range
                
                goroutine 1 [running]:
                regexp.(*Regexp).doOnePass(0xc0003a4120, 0x0, 0x0, 0x0, 0x0, 0x0, 0xc000432638, 0x5, 0x0, 0x616c6f672f6d6f63, ...)
                	/usr/lib64/go/src/regexp/exec.go:405 +0x9a8
                regexp.(*Regexp).doExecute(0xc0003a4120, 0x0, 0x0, 0x0, 0x0, 0x0, 0xc000432638, 0x5, 0x0, 0x616c6f672f6d6f63, ...)
                	/usr/lib64/go/src/regexp/exec.go:528 +0x51d
                regexp.(*Regexp).FindStringSubmatch(0xc0003a4120, 0xc000432638, 0x5, 0xc000464500, 0x7f29fc712760, 0xc000012700)
                	/usr/lib64/go/src/regexp/regexp.go:982 +0xb7
                github.com/golang/dep/vendor/github.com/Masterminds/semver.parseConstraint(0xc000432638, 0x5, 0x1, 0xc0000131f0, 0x0, 0x0, 0xc0000131e0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/vendor/github.com/Masterminds/semver/parse.go:24 +0x61
                github.com/golang/dep/vendor/github.com/Masterminds/semver.newConstraint(0xc000432638, 0x5, 0x7f29fbc44301, 0xc000214600, 0x10, 0x10, 0x7f29fc712760, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/vendor/github.com/Masterminds/semver/constraints.go:145 +0x3ff
                github.com/golang/dep/vendor/github.com/Masterminds/semver.NewConstraintIC(...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/vendor/github.com/Masterminds/semver/constraints.go:123
                github.com/golang/dep/gps.NewSemverConstraintIC(0xc000432638, 0x5, 0x203000, 0xc0000131a0, 0x1, 0x203000)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/gps/constraint.go:136 +0x67
                github.com/golang/dep.toProject(0xc000446f00, 0x1a, 0x0, 0x0, 0x0, 0x0, 0xc000432638, 0x5, 0x0, 0x0, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/manifest.go:509 +0x274
                github.com/golang/dep.fromRawManifest(0xc000324230, 0x1, 0x1, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/manifest.go:381 +0x288
                github.com/golang/dep.readManifest(0x55b80681ac20, 0xc000212000, 0xc000212000, 0xc000000000, 0xc000212000, 0x0, 0x0, 0x7f29fbc6a6ef)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/manifest.go:362 +0x262
                github.com/golang/dep.(*Ctx).LoadProject(0xc0003a8980, 0x0, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/context.go:170 +0x293
                main.(*ensureCommand).Run(0xc000433740, 0xc0003a8980, 0xc000324e00, 0x1, 0x1, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/ensure.go:162 +0x7d
                main.(*Config).Run(0xc000366f00, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:212 +0x115d
                main.main()
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:84 +0x69a
                
                	(WNT): cannot add current project to itself
    --- FAIL: TestIntegration/ensure/add/errs/noarg (0.00s)
        --- FAIL: TestIntegration/ensure/add/errs/noarg/external (0.53s)
            integration_test.go:199: exit status 2
            testcase.go:165: error did not contain expected string:
                	(GOT): panic: runtime error: invalid memory address or nil pointer dereference
                [signal SIGSEGV: segmentation violation code=0x1 addr=0x20 pc=0x7fbdec11c840]
                
                goroutine 1 [running]:
                regexp.(*Regexp).FindStringSubmatch(0xc0003a4240, 0xc00043c830, 0x6, 0x6, 0x7fbded82b460, 0x7fbdebd39a00)
                	/usr/lib64/go/src/regexp/regexp.go:982 +0x50
                github.com/golang/dep/vendor/github.com/Masterminds/semver.NewVersion(0xc00043c830, 0x6, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/vendor/github.com/Masterminds/semver/version.go:81 +0x165
                github.com/golang/dep/gps.NewVersion(...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/gps/version.go:107
                github.com/golang/dep.fromRawLock(0xc00043da02, 0x3, 0x1, 0xc00043dc58, 0x8, 0x1, 0x0, 0x0, 0x0, 0xc0003d7440, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/lock.go:96 +0x2a3
                github.com/golang/dep.readLock(0x55efc56dfc20, 0xc000212070, 0xc000212070, 0xc000000000, 0xc000212070)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/lock.go:74 +0x1d2
                github.com/golang/dep.(*Ctx).LoadProject(0xc0003a8980, 0x0, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/context.go:189 +0x517
                main.(*ensureCommand).Run(0xc00043d740, 0xc0003a8980, 0xc000325670, 0x0, 0x0, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/ensure.go:162 +0x7d
                main.(*Config).Run(0xc000364f00, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:212 +0x115d
                main.main()
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:84 +0x69a
                
                	(WNT): must specify at least one project or package to -add
    --- FAIL: TestIntegration/ensure/add/errs/exists-manifest (0.00s)
        --- FAIL: TestIntegration/ensure/add/errs/exists-manifest/external (0.57s)
            integration_test.go:199: exit status 1
            testcase.go:165: error did not contain expected string:
                	(GOT): The following issues were found in Gopkg.toml:
                
                  ✗ github.com/sdboyer/deptest is not a valid path for a source on github.com
                  ✗ github.com/sdboyer/deptesttres is not a valid path for a source on github.com
                
                ProjectRoot name validation failed
                
                	(WNT): Gopkg.toml already contains rules for github.com/sdboyer/deptest, cannot specify a version constraint
    --- FAIL: TestIntegration/ensure/add/errs/exists (0.00s)
        --- FAIL: TestIntegration/ensure/add/errs/exists/external (0.53s)
            integration_test.go:199: exit status 2
            testcase.go:165: error did not contain expected string:
                	(GOT): panic: runtime error: invalid memory address or nil pointer dereference
                [signal SIGSEGV: segmentation violation code=0x1 addr=0x20 pc=0x7fe73a4bf840]
                
                goroutine 1 [running]:
                regexp.(*Regexp).FindStringSubmatch(0xc0003a4240, 0xc00043c920, 0x6, 0x6, 0x7fe73bbce460, 0x7fe73a0dca00)
                	/usr/lib64/go/src/regexp/regexp.go:982 +0x50
                github.com/golang/dep/vendor/github.com/Masterminds/semver.NewVersion(0xc00043c920, 0x6, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/vendor/github.com/Masterminds/semver/version.go:81 +0x165
                github.com/golang/dep/gps.NewVersion(...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/gps/version.go:107
                github.com/golang/dep.fromRawLock(0xc00043c9c2, 0x3, 0x1, 0xc00043da38, 0x8, 0x1, 0x0, 0x0, 0x0, 0xc0003a4240, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/lock.go:96 +0x2a3
                github.com/golang/dep.readLock(0x55e711782c20, 0xc000212070, 0xc000212070, 0xc000000000, 0xc000212070)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/lock.go:74 +0x1d2
                github.com/golang/dep.(*Ctx).LoadProject(0xc0003a8980, 0x0, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/context.go:189 +0x517
                main.(*ensureCommand).Run(0xc00043d740, 0xc0003a8980, 0xc000324e00, 0x1, 0x1, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/ensure.go:162 +0x7d
                main.(*Config).Run(0xc000366f00, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:212 +0x115d
                main.main()
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:84 +0x69a
                
                	(WNT): nothing to -add, github.com/sdboyer/deptest is already in Gopkg.toml and the project's direct imports or required list
    --- FAIL: TestIntegration/ensure/add/errs/double-diff-spec (0.00s)
        --- FAIL: TestIntegration/ensure/add/errs/double-diff-spec/external (0.53s)
            integration_test.go:194: cmd init raised an unexpected error: exit status 2
    --- FAIL: TestIntegration/ensure/add/desync (0.00s)
        --- FAIL: TestIntegration/ensure/add/desync/external (0.52s)
            integration_test.go:199: exit status 1
            testcase.go:187: expected command not to fail, but it did
            testcase.go:171: error raised where none was expected: 
                The following issues were found in Gopkg.toml:
                
                  ✗ github.com/sdboyer/deptest is not a valid path for a source on github.com
                
                ProjectRoot name validation failed
    --- FAIL: TestIntegration/ensure/add/all-new-spec (0.00s)
        --- FAIL: TestIntegration/ensure/add/all-new-spec/external (0.52s)
            integration_test.go:194: cmd init raised an unexpected error: exit status 1
    --- FAIL: TestIntegration/ensure/add/all-new-double-spec (0.00s)
        --- FAIL: TestIntegration/ensure/add/all-new-double-spec/external (10.86s)
            integration_test.go:199: exit status 2
            testcase.go:187: expected command not to fail, but it did
            testcase.go:171: error raised where none was expected: 
                panic: runtime error: invalid memory address or nil pointer dereference
                [signal SIGSEGV: segmentation violation code=0x1 addr=0x20 pc=0x7f92a5123840]
                
                goroutine 9 [running]:
                regexp.(*Regexp).FindStringSubmatch(0xc0003a4900, 0xc000447000, 0x1e, 0x56192f902980, 0xc0003a4900, 0x56192f8d7e80)
                	/usr/lib64/go/src/regexp/regexp.go:982 +0x50
                github.com/golang/dep/gps.githubDeducer.deduceRoot(0xc0003a4900, 0xc000447000, 0x1e, 0x56192f803add, 0xb, 0x56192f902980, 0xc0003a4900)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/gps/deduce.go:115 +0x45
                github.com/golang/dep/gps.(*deductionCoordinator).deduceKnownPaths(0xc00045b890, 0xc000447000, 0x1e, 0x0, 0x0, 0x0, 0x0, 0x0, 0xc000325260, 0xc000325278)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/gps/deduce.go:668 +0x107
                github.com/golang/dep/gps.(*deductionCoordinator).deduceRootPath(0xc00045b890, 0x56192f904f00, 0xc0003280f8, 0xc000447000, 0x1e, 0x0, 0x0, 0x0, 0x0, 0x0, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/gps/deduce.go:608 +0x35b
                github.com/golang/dep/gps.(*SourceMgr).DeduceProjectRoot(0xc000324fc0, 0xc000447000, 0x1e, 0x0, 0x0, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/gps/source_manager.go:595 +0xf4
                github.com/golang/dep.ValidateProjectRoots.func1(0xc000447000, 0x1e)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/manifest.go:306 +0xab
                created by github.com/golang/dep.ValidateProjectRoots
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/manifest.go:316 +0x1b2
    --- FAIL: TestIntegration/ensure/add/all-new-double (0.00s)
        --- FAIL: TestIntegration/ensure/add/all-new-double/external (0.52s)
            integration_test.go:194: cmd init raised an unexpected error: exit status 1
    --- FAIL: TestIntegration/ensure/add/all-new (0.00s)
        --- FAIL: TestIntegration/ensure/add/all-new/external (1.15s)
            integration_test.go:194: cmd init raised an unexpected error: exit status 1
    --- FAIL: TestIntegration/check/vendororphans (0.00s)
        --- FAIL: TestIntegration/check/vendororphans/external (0.57s)
            integration_test.go:199: exit status 2
            testcase.go:171: error raised where none was expected: 
                panic: runtime error: invalid memory address or nil pointer dereference
                [signal SIGSEGV: segmentation violation code=0x1 addr=0x20 pc=0x7fae71d4b840]
                
                goroutine 1 [running]:
                regexp.(*Regexp).FindStringSubmatch(0xc0003a4240, 0xc0004328a0, 0x6, 0x6, 0x7fae7345a460, 0x7fae71968a00)
                	/usr/lib64/go/src/regexp/regexp.go:982 +0x50
                github.com/golang/dep/vendor/github.com/Masterminds/semver.NewVersion(0xc0004328a0, 0x6, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/vendor/github.com/Masterminds/semver/version.go:81 +0x165
                github.com/golang/dep/gps.NewVersion(...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/gps/version.go:107
                github.com/golang/dep.fromRawLock(0xc000432942, 0x3, 0x1, 0xc0004337d8, 0x8, 0x1, 0xc0000137a0, 0x1, 0x1, 0xc0003a4240, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/lock.go:96 +0x2a3
                github.com/golang/dep.readLock(0x5604f5176c20, 0xc000212060, 0xc000212060, 0xc000000000, 0xc000212060)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/lock.go:74 +0x1d2
                github.com/golang/dep.(*Ctx).LoadProject(0xc0003a8980, 0x0, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/context.go:189 +0x517
                main.(*checkCommand).Run(0xc000433746, 0xc0003a8980, 0xc00000f800, 0x0, 0x0, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/check.go:67 +0x6d
                main.(*Config).Run(0xc000364f60, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:212 +0x115d
                main.main()
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:84 +0x69a
    --- FAIL: TestIntegration/check/unmet_override (0.00s)
        --- FAIL: TestIntegration/check/unmet_override/external (1.11s)
            integration_test.go:199: exit status 2
            testcase.go:171: error raised where none was expected: 
                panic: runtime error: makeslice: len out of range
                
                goroutine 1 [running]:
                regexp.(*Regexp).doOnePass(0xc0003a4240, 0x0, 0x0, 0x0, 0x0, 0x0, 0xc000433840, 0x6, 0x0, 0x616c6f672f6d6f63, ...)
                	/usr/lib64/go/src/regexp/exec.go:405 +0x9a8
                regexp.(*Regexp).doExecute(0xc0003a4240, 0x0, 0x0, 0x0, 0x0, 0x0, 0xc000433840, 0x6, 0x0, 0x616c6f672f6d6f63, ...)
                	/usr/lib64/go/src/regexp/exec.go:528 +0x51d
                regexp.(*Regexp).FindStringSubmatch(0xc0003a4240, 0xc000433840, 0x6, 0x6, 0x7f6048804460, 0x7f6046d12a00)
                	/usr/lib64/go/src/regexp/regexp.go:982 +0xb7
                github.com/golang/dep/vendor/github.com/Masterminds/semver.NewVersion(0xc000433840, 0x6, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/vendor/github.com/Masterminds/semver/version.go:81 +0x165
                github.com/golang/dep/gps.NewVersion(...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/gps/version.go:107
                github.com/golang/dep.fromRawLock(0xc0004338e2, 0x3, 0x1, 0xc000433b68, 0x8, 0x1, 0xc0003cc350, 0x1, 0x1, 0xc0003a43f0, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/lock.go:96 +0x2a3
                github.com/golang/dep.readLock(0x55e2415ebc20, 0xc000212088, 0xc000212088, 0xc000000000, 0xc000212088)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/lock.go:74 +0x1d2
                github.com/golang/dep.(*Ctx).LoadProject(0xc0003a8080, 0x0, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/context.go:189 +0x517
                main.(*checkCommand).Run(0xc00043225c, 0xc0003a8080, 0xc00000e800, 0x0, 0x0, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/check.go:67 +0x6d
                main.(*Config).Run(0xc0003642a0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:212 +0x115d
                main.main()
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:84 +0x69a
    --- FAIL: TestIntegration/check/unmet_constraint (0.00s)
        --- FAIL: TestIntegration/check/unmet_constraint/external (1.13s)
            integration_test.go:199: exit status 2
            testcase.go:171: error raised where none was expected: 
                panic: runtime error: invalid memory address or nil pointer dereference
                [signal SIGSEGV: segmentation violation code=0x1 addr=0x3a pc=0x7f811accf840]
                
                goroutine 1 [running]:
                regexp.(*Regexp).FindStringSubmatch(0xc0003a4240, 0xc00043d830, 0x6, 0x6, 0x7f811c3de460, 0x7f811a8eca00)
                	/usr/lib64/go/src/regexp/regexp.go:982 +0x50
                github.com/golang/dep/vendor/github.com/Masterminds/semver.NewVersion(0xc00043d830, 0x6, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/vendor/github.com/Masterminds/semver/version.go:81 +0x165
                github.com/golang/dep/gps.NewVersion(...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/gps/version.go:107
                github.com/golang/dep.fromRawLock(0xc00043d8d2, 0x3, 0x1, 0xc00043db58, 0x8, 0x1, 0xc000436350, 0x1, 0x1, 0xc0003a42d0, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/lock.go:96 +0x2a3
                github.com/golang/dep.readLock(0x56079f563c20, 0xc000212078, 0xc000212078, 0xc000000000, 0xc000212078)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/lock.go:74 +0x1d2
                github.com/golang/dep.(*Ctx).LoadProject(0xc0003a8000, 0x0, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/context.go:189 +0x517
                main.(*checkCommand).Run(0xc00043c00a, 0xc0003a8000, 0xc00000e020, 0x0, 0x0, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/check.go:67 +0x6d
                main.(*Config).Run(0xc0003641e0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:212 +0x115d
                main.main()
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:84 +0x69a
    --- FAIL: TestIntegration/check/noverify/vendororphans (0.00s)
        --- FAIL: TestIntegration/check/noverify/vendororphans/external (0.91s)
            integration_test.go:199: exit status 2
            testcase.go:171: error raised where none was expected: 
                panic: runtime error: invalid memory address or nil pointer dereference
                [signal SIGSEGV: segmentation violation code=0x1 addr=0x3a pc=0x7f0deda3e840]
                
                goroutine 1 [running]:
                regexp.(*Regexp).FindStringSubmatch(0xc0003a4240, 0xc000433750, 0x6, 0x6, 0x7f0def14d460, 0x7f0ded65ba00)
                	/usr/lib64/go/src/regexp/regexp.go:982 +0x50
                github.com/golang/dep/vendor/github.com/Masterminds/semver.NewVersion(0xc000433750, 0x6, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/vendor/github.com/Masterminds/semver/version.go:81 +0x165
                github.com/golang/dep/gps.NewVersion(...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/gps/version.go:107
                github.com/golang/dep.fromRawLock(0xc0004337f2, 0x3, 0x1, 0xc000433a78, 0x8, 0x1, 0xc00044a070, 0x1, 0x1, 0xc0003a42d0, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/lock.go:96 +0x2a3
                github.com/golang/dep.readLock(0x55dbb8f27c20, 0xc000212060, 0xc000212060, 0xc000000000, 0xc000212060)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/lock.go:74 +0x1d2
                github.com/golang/dep.(*Ctx).LoadProject(0xc0003a8000, 0x0, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/context.go:189 +0x517
                main.(*checkCommand).Run(0xc00043200a, 0xc0003a8000, 0xc00000e020, 0x0, 0x0, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/check.go:67 +0x6d
                main.(*Config).Run(0xc0003641e0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:212 +0x115d
                main.main()
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:84 +0x69a
    --- FAIL: TestIntegration/check/noverify/unmet_override (0.00s)
        --- FAIL: TestIntegration/check/noverify/unmet_override/external (0.86s)
            integration_test.go:199: exit status 2
            testcase.go:171: error raised where none was expected: 
                panic: runtime error: makeslice: len out of range
                
                goroutine 1 [running]:
                regexp.(*Regexp).doOnePass(0xc0003a4240, 0x0, 0x0, 0x0, 0x0, 0x0, 0xc000433ac0, 0x6, 0x0, 0x616c6f672f6d6f63, ...)
                	/usr/lib64/go/src/regexp/exec.go:405 +0x9a8
                regexp.(*Regexp).doExecute(0xc0003a4240, 0x0, 0x0, 0x0, 0x0, 0x0, 0xc000433ac0, 0x6, 0x0, 0x616c6f672f6d6f63, ...)
                	/usr/lib64/go/src/regexp/exec.go:528 +0x51d
                regexp.(*Regexp).FindStringSubmatch(0xc0003a4240, 0xc000433ac0, 0x6, 0x6, 0x7fc38b4da460, 0x7fc3899e8a00)
                	/usr/lib64/go/src/regexp/regexp.go:982 +0xb7
                github.com/golang/dep/vendor/github.com/Masterminds/semver.NewVersion(0xc000433ac0, 0x6, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/vendor/github.com/Masterminds/semver/version.go:81 +0x165
                github.com/golang/dep/gps.NewVersion(...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/gps/version.go:107
                github.com/golang/dep.fromRawLock(0xc000433b62, 0x3, 0x1, 0xc000433de8, 0x8, 0x1, 0xc000434660, 0x1, 0x1, 0xc0003a43f0, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/lock.go:96 +0x2a3
                github.com/golang/dep.readLock(0x5577c6ef0c20, 0xc000212088, 0xc000212088, 0xc000000000, 0xc000212088)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/lock.go:74 +0x1d2
                github.com/golang/dep.(*Ctx).LoadProject(0xc0003a8080, 0x0, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/context.go:189 +0x517
                main.(*checkCommand).Run(0xc00043225c, 0xc0003a8080, 0xc00000e8a0, 0x0, 0x0, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/check.go:67 +0x6d
                main.(*Config).Run(0xc0003642a0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:212 +0x115d
                main.main()
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:84 +0x69a
    --- FAIL: TestIntegration/check/noverify/unmet_constraint (0.00s)
        --- FAIL: TestIntegration/check/noverify/unmet_constraint/external (0.89s)
            integration_test.go:199: exit status 2
            testcase.go:171: error raised where none was expected: 
                panic: runtime error: makeslice: len out of range
                
                goroutine 1 [running]:
                regexp.(*Regexp).doOnePass(0xc0003a4240, 0x0, 0x0, 0x0, 0x0, 0x0, 0xc000433ac0, 0x6, 0x0, 0x616c6f672f6d6f63, ...)
                	/usr/lib64/go/src/regexp/exec.go:405 +0x9a8
                regexp.(*Regexp).doExecute(0xc0003a4240, 0x0, 0x0, 0x0, 0x0, 0x0, 0xc000433ac0, 0x6, 0x0, 0x616c6f672f6d6f63, ...)
                	/usr/lib64/go/src/regexp/exec.go:528 +0x51d
                regexp.(*Regexp).FindStringSubmatch(0xc0003a4240, 0xc000433ac0, 0x6, 0x6, 0x7f9eb56ff460, 0x7f9eb3c0da00)
                	/usr/lib64/go/src/regexp/regexp.go:982 +0xb7
                github.com/golang/dep/vendor/github.com/Masterminds/semver.NewVersion(0xc000433ac0, 0x6, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/vendor/github.com/Masterminds/semver/version.go:81 +0x165
                github.com/golang/dep/gps.NewVersion(...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/gps/version.go:107
                github.com/golang/dep.fromRawLock(0xc000433b62, 0x3, 0x1, 0xc000433de8, 0x8, 0x1, 0xc0003cc650, 0x1, 0x1, 0xc0003a43f0, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/lock.go:96 +0x2a3
                github.com/golang/dep.readLock(0x55df8ffa6c20, 0xc000212080, 0xc000212080, 0xc000000000, 0xc000212080)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/lock.go:74 +0x1d2
                github.com/golang/dep.(*Ctx).LoadProject(0xc0003a8080, 0x0, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/context.go:189 +0x517
                main.(*checkCommand).Run(0xc00043212c, 0xc0003a8080, 0xc00000e2e0, 0x0, 0x0, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/check.go:67 +0x6d
                main.(*Config).Run(0xc000364240, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:212 +0x115d
                main.main()
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:84 +0x69a
    --- FAIL: TestIntegration/check/noverify/hash_version_mismatch (0.00s)
        --- FAIL: TestIntegration/check/noverify/hash_version_mismatch/external (0.82s)
            integration_test.go:199: exit status 2
            testcase.go:187: expected command not to fail, but it did
            testcase.go:171: error raised where none was expected: 
                panic: runtime error: invalid memory address or nil pointer dereference
                [signal SIGSEGV: segmentation violation code=0x1 addr=0x3a pc=0x7f6c22597840]
                
                goroutine 1 [running]:
                regexp.(*Regexp).FindStringSubmatch(0xc0003a4240, 0xc000433750, 0x6, 0x6, 0x7f6c23ca6460, 0x7f6c221b4a00)
                	/usr/lib64/go/src/regexp/regexp.go:982 +0x50
                github.com/golang/dep/vendor/github.com/Masterminds/semver.NewVersion(0xc000433750, 0x6, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/vendor/github.com/Masterminds/semver/version.go:81 +0x165
                github.com/golang/dep/gps.NewVersion(...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/gps/version.go:107
                github.com/golang/dep.fromRawLock(0xc0004337f2, 0x3, 0x1, 0xc000433a78, 0x8, 0x1, 0xc000442060, 0x1, 0x1, 0xc0003a42d0, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/lock.go:96 +0x2a3
                github.com/golang/dep.readLock(0x55b91a38fc20, 0xc000212060, 0xc000212060, 0xc000000000, 0xc000212060)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/lock.go:74 +0x1d2
                github.com/golang/dep.(*Ctx).LoadProject(0xc0003a8000, 0x0, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/context.go:189 +0x517
                main.(*checkCommand).Run(0xc00043200c, 0xc0003a8000, 0xc00000e260, 0x0, 0x0, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/check.go:67 +0x6d
                main.(*Config).Run(0xc0003641e0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:212 +0x115d
                main.main()
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:84 +0x69a
    --- FAIL: TestIntegration/check/hash_version_mismatch (0.00s)
        --- FAIL: TestIntegration/check/hash_version_mismatch/external (0.67s)
            integration_test.go:199: exit status 2
            testcase.go:171: error raised where none was expected: 
                panic: runtime error: invalid memory address or nil pointer dereference
                [signal SIGSEGV: segmentation violation code=0x1 addr=0x3a pc=0x7fd7cae2b840]
                
                goroutine 1 [running]:
                regexp.(*Regexp).FindStringSubmatch(0xc0003a4240, 0xc0004328f0, 0x6, 0x6, 0x7fd7cc53a460, 0x7fd7caa48a00)
                	/usr/lib64/go/src/regexp/regexp.go:982 +0x50
                github.com/golang/dep/vendor/github.com/Masterminds/semver.NewVersion(0xc0004328f0, 0x6, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/vendor/github.com/Masterminds/semver/version.go:81 +0x165
                github.com/golang/dep/gps.NewVersion(...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/gps/version.go:107
                github.com/golang/dep.fromRawLock(0xc000432992, 0x3, 0x1, 0xc0004337d8, 0x8, 0x1, 0xc000013870, 0x1, 0x1, 0xc0003a42d0, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/lock.go:96 +0x2a3
                github.com/golang/dep.readLock(0x55be4a286c20, 0xc000212060, 0xc000212060, 0xc000000000, 0xc000212060)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/lock.go:74 +0x1d2
                github.com/golang/dep.(*Ctx).LoadProject(0xc0003a8000, 0x0, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/context.go:189 +0x517
                main.(*checkCommand).Run(0xc00043200c, 0xc0003a8000, 0xc00000e1a0, 0x0, 0x0, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/check.go:67 +0x6d
                main.(*Config).Run(0xc0003641e0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:212 +0x115d
                main.main()
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:84 +0x69a
    --- FAIL: TestIntegration/check/hash_mismatch (0.00s)
        --- FAIL: TestIntegration/check/hash_mismatch/external (0.62s)
            integration_test.go:199: exit status 2
            testcase.go:171: error raised where none was expected: 
                panic: runtime error: invalid memory address or nil pointer dereference
                [signal SIGSEGV: segmentation violation code=0x1 addr=0x3a pc=0x7fad77912840]
                
                goroutine 1 [running]:
                regexp.(*Regexp).FindStringSubmatch(0xc0003a4240, 0xc0004328d0, 0x6, 0x6, 0x7fad79021460, 0x7fad7752fa00)
                	/usr/lib64/go/src/regexp/regexp.go:982 +0x50
                github.com/golang/dep/vendor/github.com/Masterminds/semver.NewVersion(0xc0004328d0, 0x6, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/vendor/github.com/Masterminds/semver/version.go:81 +0x165
                github.com/golang/dep/gps.NewVersion(...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/gps/version.go:107
                github.com/golang/dep.fromRawLock(0xc000432972, 0x3, 0x1, 0xc0004337d8, 0x8, 0x1, 0xc0000137b0, 0x1, 0x1, 0xc0003a42d0, ...)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/lock.go:96 +0x2a3
                github.com/golang/dep.readLock(0x55c5ba926c20, 0xc000212060, 0xc000212060, 0xc000000000, 0xc000212060)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/lock.go:74 +0x1d2
                github.com/golang/dep.(*Ctx).LoadProject(0xc0003a8000, 0x0, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/context.go:189 +0x517
                main.(*checkCommand).Run(0xc000433746, 0xc0003a8000, 0xc00000f820, 0x0, 0x0, 0x0, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/check.go:67 +0x6d
                main.(*Config).Run(0xc000364f00, 0x0)
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:212 +0x115d
                main.main()
                	/yocto/build/tmp/work/core2-64-wrs-linux/go-dep/0.5.0-r0/build/src/github.com/golang/dep/cmd/dep/main.go:84 +0x69a

FAIL: github.com/golang/dep/cmd/dep/dep.test

#12 lore raw

Re: [PATCH v5 06/13] go.bbclass: ptest cleanup and improvements

Quoted 49 lines · Mingli
Quoted 37 lines · Matt Madison
Quoted 23 lines · Mingli
Quoted 8 lines · Matt Madison
Quoted 6 lines · Mingli

Hi Matt,

I noticed your commit is the latest update for go-dep ptest. But the go-dep ptest doesn't work in my environment. I'm trying to figure out what's wrong is here though I didn't know much about go.

Quoted 10 lines

I went back over the commits, and I don't think I did anything with go-dep specifically. I can see that the tests are failing for it, and it looks like it's because go-dep's test programs make some assumptions about the environment. For one thing, it needs the go compiler installed. It also looks like it's expecting some source files to be present... in other words, it's not really designed for a cross-build setup, with tests run on the cross-built target. It could be messy to work around that, and I'm not sure how useful it would be anyway, seeing as how go-dep is more of a build tool. Might be better to just disable ptests for it completely.

Quoted 6 lines

Many thanks Matt for your information!
Did you ever run go-dep ptest?
Go through the run-ptest script for go-dep, it actually runs the /usr/lib64/go-dep/ptest/github.com/golang/dep/cmd/dep/dep.test whose source file is
https://github.com/golang/dep/blob/master/cmd/dep/dep_test.go.

Yes, I see that. That main program starts by rebuilding the dep program from source, then runs the tests using that copy of the program, so it's assuming that you're still in a development environment where you can run a full go build. That's what I meant by it not being designed for a cross-build setup.

Quoted 7 lines

I've patched the test program to create a symlink to the installed dep program instead of rebuilding, and got further. You'll need to include 'go', 'git', and 'git-perltools' in the image to get the tests to run. Some of the test cases failed until I set GOCACHE in the environment to point to a valid path; I'm not sure why. The tests took a long time to run on my qemux86 build, though - at least 30 minutes.

Quoted 6 lines

Thanks very much for Matt's guide!

I have applied the patch you provide to create a symlink to the installed dep program instead of rebuilding and also add go', 'git', and 'git-perltools' into the image, but there is no PASS case, all failed as attached go-dep_ptest.log.

The device under test needs Internet access to fetch repos from Github. From the log, it looks like perhaps yours didn't?

Quoted 2 lines

BTW, you said you set GOCACHE, what's the valid path do you mean?

Any directory that the user has write access to. The default is $HOME/.cache/go-build .

-M

Quoted 47 lines

Thanks,

Quoted 44 lines

Here's the patch I applied to use the already-built dep binary. An alternative approach would be to put everything in place to allow the test program to rebuild the dep binary itself, but that would drive up the time for the test run even further.

Regards,

(quoted diff) +0 -2
-Matt
 
---
  cmd/dep/dep_test.go | 13 +++++++++----
  1 file changed, 9 insertions(+), 4 deletions(-)
src/github.com/golang/dep/cmd/dep/dep_test.go +0 -0
index 687eef3a..535ca56d 100644
@@ -18,13 +18,18 @@ import (
  // deletes it after the tests have been run.
  // Most of this is taken from

https://github.com/golang/go/blob/master/src/cmd/go/go_test.go and reused here.
func TestMain(m *testing.M) {
- args := []string{"build", "-o", "testdep" + test.ExeSuffix}
- out, err := exec.Command("go", args...).CombinedOutput()
+ args := []string{"dep"}
+ out, err := exec.Command("which", args...).CombinedOutput()
if err != nil {
- fmt.Fprintf(os.Stderr, "building testdep failed: %v\n%s", err, out)
+ fmt.Fprintf(os.Stderr, "finding dep failed: %v\n%s", err, out)
+ os.Exit(2)
+ }
+ args = []string{"-s", string(out[:len(out)-1]), "testdep" + test.ExeSuffix}
+ out, err = exec.Command("ln", args...).CombinedOutput()
+ if err != nil {
+ fmt.Fprintf(os.Stderr, "symlinking dep failed: %v\n%s", err, out) os.Exit(2)
}
-
// Don't let these environment variables confuse the test. os.Unsetenv("GOPATH")
os.Unsetenv("GIT_ALLOW_PROTOCOL")

#13 lore raw

Re: [PATCH v5 06/13] go.bbclass: ptest cleanup and improvements

Quoted 57 lines · Matt Madison
Quoted 49 lines · Mingli
Quoted 37 lines · Matt Madison
Quoted 23 lines · Mingli
Quoted 8 lines · Matt Madison
Quoted 6 lines · Mingli

Hi Matt,

I noticed your commit is the latest update for go-dep ptest. But the go-dep ptest doesn't work in my environment. I'm trying to figure out what's wrong is here though I didn't know much about go.

Quoted 10 lines

I went back over the commits, and I don't think I did anything with go-dep specifically. I can see that the tests are failing for it, and it looks like it's because go-dep's test programs make some assumptions about the environment. For one thing, it needs the go compiler installed. It also looks like it's expecting some source files to be present... in other words, it's not really designed for a cross-build setup, with tests run on the cross-built target. It could be messy to work around that, and I'm not sure how useful it would be anyway, seeing as how go-dep is more of a build tool. Might be better to just disable ptests for it completely.

Quoted 6 lines

Many thanks Matt for your information!
Did you ever run go-dep ptest?
Go through the run-ptest script for go-dep, it actually runs the /usr/lib64/go-dep/ptest/github.com/golang/dep/cmd/dep/dep.test whose source file is
https://github.com/golang/dep/blob/master/cmd/dep/dep_test.go.

Yes, I see that. That main program starts by rebuilding the dep program from source, then runs the tests using that copy of the program, so it's assuming that you're still in a development environment where you can run a full go build. That's what I meant by it not being designed for a cross-build setup.

Quoted 7 lines

I've patched the test program to create a symlink to the installed dep program instead of rebuilding, and got further. You'll need to include 'go', 'git', and 'git-perltools' in the image to get the tests to run. Some of the test cases failed until I set GOCACHE in the environment to point to a valid path; I'm not sure why. The tests took a long time to run on my qemux86 build, though - at least 30 minutes.

Quoted 6 lines

Thanks very much for Matt's guide!

I have applied the patch you provide to create a symlink to the installed dep program instead of rebuilding and also add go', 'git', and 'git-perltools' into the image, but there is no PASS case, all failed as attached go-dep_ptest.log.

Quoted 8 lines

The device under test needs Internet access to fetch repos from Github. From the log, it looks like perhaps yours didn't?

Quoted 2 lines

BTW, you said you set GOCACHE, what's the valid path do you mean?

Any directory that the user has write access to. The default is $HOME/.cache/go-build .

There is no difference after set GOCACHE, still all the case failed.

Thanks,

Quoted 51 lines

-M

Quoted 47 lines

Thanks,

Quoted 44 lines

Here's the patch I applied to use the already-built dep binary. An alternative approach would be to put everything in place to allow the test program to rebuild the dep binary itself, but that would drive up the time for the test run even further.

Regards,

(quoted diff) +0 -2
-Matt
 
---
   cmd/dep/dep_test.go | 13 +++++++++----
   1 file changed, 9 insertions(+), 4 deletions(-)
src/github.com/golang/dep/cmd/dep/dep_test.go +0 -0
index 687eef3a..535ca56d 100644
@@ -18,13 +18,18 @@ import (
   // deletes it after the tests have been run.
   // Most of this is taken from

https://github.com/golang/go/blob/master/src/cmd/go/go_test.go and reused here.
func TestMain(m *testing.M) {
- args := []string{"build", "-o", "testdep" + test.ExeSuffix}
- out, err := exec.Command("go", args...).CombinedOutput()
+ args := []string{"dep"}
+ out, err := exec.Command("which", args...).CombinedOutput()

    if err != nil {

- fmt.Fprintf(os.Stderr, "building testdep failed: %v\n%s", err, out)
+ fmt.Fprintf(os.Stderr, "finding dep failed: %v\n%s", err, out)
+ os.Exit(2)
+ }
+ args = []string{"-s", string(out[:len(out)-1]), "testdep" + test.ExeSuffix}
+ out, err = exec.Command("ln", args...).CombinedOutput()
+ if err != nil {
+ fmt.Fprintf(os.Stderr, "symlinking dep failed: %v\n%s", err, out)

    os.Exit(2)
    }
-
    // Don't let these environment variables confuse the test.
    os.Unsetenv("GOPATH")
    os.Unsetenv("GIT_ALLOW_PROTOCOL")
#14 lore raw

PATCH v5 7/13 goarch.bbclass: disable shared runtime for nativesdk builds

In reply to Matt Madison

While useful on embedded devices for saving disk space, use of shared runtime in Go is not the usual practice, so disable it for nativesdk builds. We don't use it for native builds, either, so this makes the SDK match the native environment more closely.

---
 meta/classes/goarch.bbclass | 1 +
 1 file changed, 1 insertion(+)
meta/classes/goarch.bbclass +1 -0
index 1021b94d4c..5c8ed33b15 100644
@@ -24,6 +24,7 @@ GO_DYNLINK_x86 = "1"
 GO_DYNLINK_x86-64 = "1"
 GO_DYNLINK_powerpc64 = "1"
 GO_DYNLINK_class-native = ""
+GO_DYNLINK_class-nativesdk = ""
 
 # define here because everybody inherits this class
 #
Signature · 1 line
2.14.1
#15 lore raw

PATCH v5 8/13 go: move common settings to go-common.inc

In reply to Matt Madison

Eliminate some redundancy in the recipes by moving some commonly-used variable settings to the common include file. Also removed a duplicate inherit from go-target.inc that was already in go-common.inc.

---
 meta/recipes-devtools/go/go-common.inc         | 4 ++++
 meta/recipes-devtools/go/go-cross-canadian.inc | 4 ----
 meta/recipes-devtools/go/go-cross.inc          | 3 ---
 meta/recipes-devtools/go/go-crosssdk.inc       | 4 ----
 meta/recipes-devtools/go/go-native.inc         | 3 ---
 meta/recipes-devtools/go/go-runtime.inc        | 5 +----
 meta/recipes-devtools/go/go-target.inc         | 5 -----
 7 files changed, 5 insertions(+), 23 deletions(-)
meta/recipes-devtools/go/go-common.inc +4 -0
index 611775b2cc..11d55c4d36 100644
@@ -23,6 +23,10 @@ INHIBIT_PACKAGE_DEBUG_SPLIT = "1"
 SSTATE_SCAN_CMD = "true"
 
 export GOROOT_OVERRIDE = "1"
+export GOTMPDIR ?= "${WORKDIR}/go-tmp"
+GOTMPDIR[vardepvalue] = ""
+export GOCACHE = "off"
+export CGO_ENABLED = "1"
 
 do_compile_prepend() {
 	BUILD_CC=${BUILD_CC}
meta/recipes-devtools/go/go-cross-canadian.inc +0 -4
index 4a43d831fa..e630b83df8 100644
@@ -10,10 +10,6 @@ export GOHOSTARCH = "${BUILD_GOARCH}"
 export GOROOT_BOOTSTRAP = "${STAGING_LIBDIR_NATIVE}/go"
 export GOTOOLDIR_BOOTSTRAP = "${STAGING_LIBDIR_NATIVE}/${HOST_SYS}/go/pkg/tool/${BUILD_GOTUPLE}"
 export GOROOT_FINAL = "${libdir}/go"
-export CGO_ENABLED = "1"
-export GOCACHE = "off"
-export GOTMPDIR ?= "${WORKDIR}/go-tmp"
-GOTMPDIR[vardepvalue] = ""
 export CGO_CFLAGS = "${CFLAGS}"
 export CGO_LDFLAGS = "${LDFLAGS}"
 export GO_LDFLAGS = '-linkmode external -extld ${HOST_PREFIX}gcc -extldflags "--sysroot=${STAGING_DIR_HOST} ${HOST_CC_ARCH} ${LDFLAGS}"'
meta/recipes-devtools/go/go-cross.inc +0 -3
index 289ae77104..44f230b8bc 100644
@@ -15,9 +15,6 @@ export GOMIPS = "${TARGET_GOMIPS}"
 export GOROOT_BOOTSTRAP = "${STAGING_LIBDIR_NATIVE}/go"
 export GOROOT_FINAL = "${libdir}/go"
 export GOCACHE = "off"
-export GOTMPDIR ?= "${WORKDIR}/go-tmp"
-GOTMPDIR[vardepvalue] = ""
-export CGO_ENABLED = "1"
 CC = "${@d.getVar('BUILD_CC').strip()}"
 
 do_configure[noexec] = "1"
meta/recipes-devtools/go/go-crosssdk.inc +0 -4
index 05ca62eba8..4391b32424 100644
@@ -10,10 +10,6 @@ export GOOS = "${TARGET_GOOS}"
 export GOARCH = "${TARGET_GOARCH}"
 export GOROOT_BOOTSTRAP = "${STAGING_LIBDIR_NATIVE}/go"
 export GOROOT_FINAL = "${libdir}/go"
-export CGO_ENABLED = "1"
-export GOCACHE = "off"
-export GOTMPDIR ?= "${WORKDIR}/go-tmp"
-GOTMPDIR[vardepvalue] = ""
 
 do_configure[noexec] = "1"
 
meta/recipes-devtools/go/go-native.inc +0 -3
index 35561768df..b76fb0825e 100644
@@ -10,11 +10,8 @@ SRC_URI[bootstrap.sha256sum] = "f4ff5b5eb3a3cae1c993723f3eab519c5bae18866b5e5f96
 
 export GOOS = "${BUILD_GOOS}"
 export GOARCH = "${BUILD_GOARCH}"
-export GOTMPDIR ?= "${WORKDIR}/go-tmp"
-GOTMPDIR[vardepvalue] = ""
 CC = "${@d.getVar('BUILD_CC').strip()}"
 
-export CGO_ENABLED = "1"
 GOMAKEARGS ?= "--no-banner"
 
 do_configure() {
meta/recipes-devtools/go/go-runtime.inc +1 -4
index 0fe4566360..a79295df47 100644
@@ -11,14 +11,11 @@ export GO386 = "${TARGET_GO386}"
 export GOMIPS = "${TARGET_GOMIPS}"
 export GOROOT_BOOTSTRAP = "${STAGING_LIBDIR_NATIVE}/go"
 export GOROOT_FINAL = "${libdir}/go"
-export CGO_ENABLED = "1"
 export CGO_CFLAGS = "${CFLAGS}"
 export CGO_CPPFLAGS = "${CPPFLAGS}"
 export CGO_CXXFLAGS = "${CXXFLAGS}"
 export CGO_LDFLAGS = "${LDFLAGS}"
-export GOCACHE = "off"
-export GOTMPDIR ?= "${WORKDIR}/go-tmp"
-GOTMPDIR[vardepvalue] = ""
+
 GO_EXTLDFLAGS ?= "${HOST_CC_ARCH}${TOOLCHAIN_OPTIONS} ${LDFLAGS}"
 GO_LINKMODE ?= ""
 GO_LINKMODE_class-nativesdk = "--linkmode=external"
meta/recipes-devtools/go/go-target.inc +0 -5
index 141a456cca..3bc32f3bec 100644
@@ -1,4 +1,3 @@
-inherit goarch
 DEPENDS = "virtual/${TARGET_PREFIX}go go-native"
 DEPENDS_class-nativesdk = "virtual/${TARGET_PREFIX}go-crosssdk go-native"
 
@@ -11,10 +10,6 @@ export GO386 = "${TARGET_GO386}"
 export GOMIPS = "${TARGET_GOMIPS}"
 export GOROOT_BOOTSTRAP = "${STAGING_LIBDIR_NATIVE}/go"
 export GOROOT_FINAL = "${libdir}/go"
-export CGO_ENABLED = "1"
-export GOCACHE = "off"
-export GOTMPDIR ?= "${WORKDIR}/go-tmp"
-GOTMPDIR[vardepvalue] = ""
 GO_LDFLAGS = ""
 GO_LDFLAGS_class-nativesdk = "-linkmode external"
 export GO_LDFLAGS
Signature · 1 line
2.14.1
#16 lore raw

PATCH v5 9/13 go.bbclass, goarch.bbclass: update SECURITY_CFLAGS

In reply to Matt Madison

With go1.10 the NOPIE flags are only required for
MIPS target builds, and are now incompatible for
the other architectures.

---
 meta/classes/go.bbclass     | 3 ---
 meta/classes/goarch.bbclass | 2 ++
 2 files changed, 2 insertions(+), 3 deletions(-)
meta/classes/go.bbclass +0 -3
index a51ba3e9f0..d33d83ea7f 100644
@@ -34,9 +34,6 @@ GOTOOLDIR = "${STAGING_LIBDIR_NATIVE}/${TARGET_SYS}/go/pkg/tool/${BUILD_GOTUPLE}
 GOTOOLDIR_class-native = "${STAGING_LIBDIR_NATIVE}/go/pkg/tool/${BUILD_GOTUPLE}"
 export GOTOOLDIR
 
-SECURITY_CFLAGS = "${SECURITY_NOPIE_CFLAGS}"
-SECURITY_LDFLAGS = ""
-
 export CGO_ENABLED ?= "1"
 export CGO_CFLAGS ?= "${CFLAGS}"
 export CGO_CPPFLAGS ?= "${CPPFLAGS}"
meta/classes/goarch.bbclass +2 -0
index 5c8ed33b15..f54c5169e3 100644
@@ -35,6 +35,8 @@ COMPATIBLE_HOST_powerpc64 = "null"
 COMPATIBLE_HOST_mipsarchn32 = "null"
 ARM_INSTRUCTION_SET = "arm"
 TUNE_CCARGS_remove = "-march=mips32r2"
+SECURITY_CFLAGS_mips = "${SECURITY_NOPIE_CFLAGS}"
+SECURITY_NOPIE_CFLAGS ??= ""
 
 def go_map_arch(a, d):
     import re
Signature · 1 line
2.14.1
#17 lore raw

PATCH v5 10/13 go: disable PIE CFLAGS for nativesdk and cross-canadian builds

In reply to Matt Madison

The statically-linked Go code in the toolchain is not compatible with PIE, so disable its use in the C compiler during the toolchain build.

---
 meta/recipes-devtools/go/go-cross-canadian.inc    | 6 +++---
 meta/recipes-devtools/go/go-cross-canadian_1.9.bb | 4 ++--
 meta/recipes-devtools/go/go-target.inc            | 3 +--
 3 files changed, 6 insertions(+), 7 deletions(-)
meta/recipes-devtools/go/go-cross-canadian.inc +3 -3
index e630b83df8..ea68b8875d 100644
@@ -12,13 +12,13 @@ export GOTOOLDIR_BOOTSTRAP = "${STAGING_LIBDIR_NATIVE}/${HOST_SYS}/go/pkg/tool/$
 export GOROOT_FINAL = "${libdir}/go"
 export CGO_CFLAGS = "${CFLAGS}"
 export CGO_LDFLAGS = "${LDFLAGS}"
-export GO_LDFLAGS = '-linkmode external -extld ${HOST_PREFIX}gcc -extldflags "--sysroot=${STAGING_DIR_HOST} ${HOST_CC_ARCH} ${LDFLAGS}"'
+export GO_LDFLAGS = '-linkmode external -extld ${HOST_PREFIX}gcc -extldflags "--sysroot=${STAGING_DIR_HOST} ${SECURITY_NOPIE_CFLAGS} ${HOST_CC_ARCH} ${LDFLAGS}"'
 
 do_configure[noexec] = "1"
 
 do_compile() {
-	export CC_FOR_${HOST_GOOS}_${HOST_GOARCH}="${HOST_PREFIX}gcc --sysroot=${STAGING_DIR_HOST}${SDKPATHNATIVE}"
-	export CXX_FOR_${HOST_GOOS}_${HOST_GOARCH}="${HOST_PREFIX}gxx --sysroot=${STAGING_DIR_HOST}${SDKPATHNATIVE}"
+	export CC_FOR_${HOST_GOOS}_${HOST_GOARCH}="${HOST_PREFIX}gcc --sysroot=${STAGING_DIR_HOST}${SDKPATHNATIVE} ${SECURITY_NOPIE_CFLAGS}"
+	export CXX_FOR_${HOST_GOOS}_${HOST_GOARCH}="${HOST_PREFIX}gxx --sysroot=${STAGING_DIR_HOST}${SDKPATHNATIVE} ${SECURITY_NOPIE_CFLAGS}"
 	cd src
 	./make.bash --host-only --no-banner
 	cd ${B}
meta/recipes-devtools/go/go-cross-canadian_1.9.bb +2 -2
index 0306fdf684..367a967056 100644
@@ -3,8 +3,8 @@ require go-${PV}.inc
 
 export GOHOSTOS_CROSS = "${HOST_GOOS}"
 export GOHOSTARCH_CROSS = "${HOST_GOARCH}"
-export CC_FOR_TARGET = "${HOST_PREFIX}gcc --sysroot=${STAGING_DIR_HOST}${SDKPATHNATIVE}"
-export CXX_FOR_TARGET = "${HOST_PREFIX}g++ --sysroot=${STAGING_DIR_HOST}${SDKPATHNATIVE}"
+export CC_FOR_TARGET = "${HOST_PREFIX}gcc --sysroot=${STAGING_DIR_HOST}${SDKPATHNATIVE} ${SECURITY_NOPIE_CFLAGS}"
+export CXX_FOR_TARGET = "${HOST_PREFIX}g++ --sysroot=${STAGING_DIR_HOST}${SDKPATHNATIVE} ${SECURITY_NOPIE_CFLAGS}"
 
 do_compile_prepend() {
 	export GOBIN="${B}/bin"
meta/recipes-devtools/go/go-target.inc +1 -2
index 3bc32f3bec..29a1344675 100644
@@ -14,8 +14,7 @@ GO_LDFLAGS = ""
 GO_LDFLAGS_class-nativesdk = "-linkmode external"
 export GO_LDFLAGS
 
-SECURITY_CFLAGS = "${SECURITY_NOPIE_CFLAGS}"
-SECURITY_LDFLAGS = ""
+CC_append_class-nativesdk = " ${SECURITY_NOPIE_CFLAGS}"
 
 do_configure[noexec] = "1"
 
Signature · 1 line
2.14.1
#18 lore raw

PATCH v5 11/13 packagegroup-go-sdk-target: add go-runtime-staticdev

In reply to Matt Madison

to allow go programs to be linked either statically or dynamically when cross-compiling with the SDK.

---
 meta/recipes-core/packagegroups/packagegroup-go-sdk-target.bb | 1 +
 1 file changed, 1 insertion(+)
meta/recipes-core/packagegroups/packagegroup-go-sdk-target.bb +1 -0
index 3e190770a7..7d2ccbda22 100644
@@ -5,4 +5,5 @@ inherit packagegroup goarch
 RDEPENDS_${PN} = " \
     go-runtime \
     go-runtime-dev \
+    go-runtime-staticdev \
 "
Signature · 1 line
2.14.1
#19 lore raw

PATCH v5 12/13 go-runtime: remove unneeded nativesdk override, rename variable

In reply to Matt Madison

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).

---
 meta/recipes-devtools/go/go-runtime.inc | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)
meta/recipes-devtools/go/go-runtime.inc +2 -4
index a79295df47..0041e8afab 100644
@@ -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}
 }
Signature · 1 line
2.14.1
#20 lore raw

PATCH v5 13/13 tcmode-default.inc: add settings for go

In reply to Matt Madison

to allow GOVERSION to be set for using an older
go toolchain.

---
 meta/conf/distro/include/tcmode-default.inc | 10 ++++++++++
 1 file changed, 10 insertions(+)
meta/conf/distro/include/tcmode-default.inc +10 -0
index 87a5920cad..5c6681fb9d 100644
@@ -67,3 +67,13 @@ PREFERRED_VERSION_cross-localedef-native   ?= "${GLIBCVERSION}"
 # Setup suitable toolchain flags
 require conf/distro/include/as-needed.inc
 
+GOVERSION ?= "1.10%"
+PREFERRED_VERSION_virtual/${TARGET_PREFIX}go ?= "${GOVERSION}"
+PREFERRED_VERSION_go-cross-${TARGET_ARCH} ?= "${GOVERSION}"
+PREFERRED_VERSION_go-crosssdk-${SDK_ARCH} ?= "${GOVERSION}"
+PREFERRED_VERSION_go-cross-canadian-${TRANSLATED_TARGET_ARCH} ?= "${GOVERSION}"
+PREFERRED_VERSION_go ?= "${GOVERSION}"
+PREFERRED_VERSION_go-native ?= "${GOVERSION}"
+PREFERRED_VERSION_go-runtime ?= "${GOVERSION}"
+PREFERRED_VERSION_nativesdk-go ?= "${GOVERSION}"
+PREFERRED_VERSION_nativesdk-go-runtime ?= "${GOVERSION}"
Signature · 1 line
2.14.1
#21 lore raw

✗ patchtest: failure for go1.10 update and misc improvements (rev5)

In reply to Matt Madison

== Series Details ==

Series: go1.10 update and misc improvements (rev5)
Revision: 5
URL : https://patchwork.openembedded.org/series/11102/
State : failure

== Summary ==

Thank you for submitting this patch series to OpenEmbedded Core. This is an automated response. Several tests have been executed on the proposed series by patchtest resulting in the following failures:

* Issue Patches not removed from tree [test_src_uri_left_files]

  Suggested fix    Amend the patch containing the software patch file removal
  Patch            0002-cmd-go-fix-CC-and-CXX-environment-variable-construct.patch
  Patch            0001-make.bash-quote-CC_FOR_TARGET.patch
  Patch            0003-make.bash-better-separate-host-and-target-builds.patch
  Patch            0005-cmd-go-make-GOROOT-precious-by-default.patch
  Patch            0009-cmd-go-buildmode-pie-forces-external-linking-mode-on.patch
  Patch            0008-make.bash-add-GOHOSTxx-indirection-for-cross-canadia.patch
  Patch            0007-ld-add-soname-to-shareable-objects.patch
  Patch            0004-cmd-go-allow-GOTOOLDIR-to-be-overridden-in-the-envir.patch
  Patch            0006-make.bash-add-GOTOOLDIR_BOOTSTRAP-environment-variab.patch
  Patch            0010-make.bash-override-CC-when-building-dist-and-go_boot.patch

If you believe any of these test results are incorrect, please reply to the mailing list ([email protected]) raising your concerns. Otherwise we would appreciate you correcting the issues and submitting a new version of the patchset if applicable. Please ensure you add/increment the version number when sending the new version (i.e. [PATCH] -> [PATCH v2] -> [PATCH v3] -> ...).

---

Guidelines:     https://www.openembedded.org/wiki/Commit_Patch_Message_Guidelines
Test framework: http://git.yoctoproject.org/cgit/cgit.cgi/patchtest
Test suite:     http://git.yoctoproject.org/cgit/cgit.cgi/patchtest-oe