From: Cherry Zhang Date: Wed, 27 Apr 2016 19:44:22 +0000 (-0400) Subject: misc/cgo/testcarchive: fix path of libgo.a for darwin/arm X-Git-Tag: go1.7beta1~450 X-Git-Url: http://www.git.cypherpunks.su/?a=commitdiff_plain;h=78bcdeb6a36a6d45f93c8ff546fa946e5fbec093;p=gostls13.git misc/cgo/testcarchive: fix path of libgo.a for darwin/arm After CL 22461, c-archive build on darwin/arm is by default compiled with -shared, so update the install path. Fix build. Change-Id: Ie93dbd226ed416b834da0234210f4b98bc0e3606 Reviewed-on: https://go-review.googlesource.com/22507 Reviewed-by: David Crawshaw Run-TryBot: David Crawshaw TryBot-Result: Gobot Gobot --- diff --git a/misc/cgo/testcarchive/carchive_test.go b/misc/cgo/testcarchive/carchive_test.go index 72e9ef1d59..19c746d49a 100644 --- a/misc/cgo/testcarchive/carchive_test.go +++ b/misc/cgo/testcarchive/carchive_test.go @@ -147,7 +147,11 @@ func TestInstall(t *testing.T) { t.Fatal(err) } - compilemain(t, filepath.Join("pkg", GOOS+"_"+GOARCH, "libgo.a")) + libgopath := filepath.Join("pkg", GOOS+"_"+GOARCH, "libgo.a") + if GOOS == "darwin" && GOARCH == "arm" { + libgopath = filepath.Join("pkg", GOOS+"_"+GOARCH+"_shared", "libgo.a") + } + compilemain(t, libgopath) binArgs := append(bin, "arg1", "arg2") if out, err := exec.Command(binArgs[0], binArgs[1:]...).CombinedOutput(); err != nil {