From 13774a5b6dcb513ba9e25ebbe551a1b4a2241499 Mon Sep 17 00:00:00 2001 From: Srini Brahmaroutu Date: Sat, 31 Oct 2015 20:22:44 +0000 Subject: [PATCH] after the changes to unit test framework, fixing gccgo to run unit tests Signed-off-by: Srini Brahmaroutu Upstream-commit: 81b3d2eec9d107e7bb6e839ca3506f0bf9dee9db Component: engine --- components/engine/hack/make/test-unit | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/components/engine/hack/make/test-unit b/components/engine/hack/make/test-unit index 9590525372..f7b948d3e3 100644 --- a/components/engine/hack/make/test-unit +++ b/components/engine/hack/make/test-unit @@ -21,7 +21,12 @@ bundle_test_unit() { "${BUILDFLAGS[@]}" $TEST_PATH \ | grep -v github.com/docker/docker/vendor \ | grep -v github.com/docker/docker/integration-cli) - go test -cover $GCCGOFLAGS -ldflags "$LDFLAGS" "${BUILDFLAGS[@]}" $TESTFLAGS $pkg_list + go test $COVER $GCCGOFLAGS -ldflags "$LDFLAGS" "${BUILDFLAGS[@]}" $TESTFLAGS $pkg_list } +if [[ "$(go version)" =~ "gccgo" ]]; then + GCCGOFLAGS=-gccgoflags="-lpthread" +else + COVER=-cover +fi bundle_test_unit 2>&1 | tee -a "$DEST/test.log"