Commit 384789e8 authored by Ian Lance Taylor's avatar Ian Lance Taylor

cmd/objdump: don't run TestDisasmExtld if cgo is not enabled

The test uses external linking mode, which is probably not available
if cgo does not work.

Fixes #11969.

Change-Id: Id1c2828cd2540391e16b422bf51674ba6ff084b0
Reviewed-on: https://go-review.googlesource.com/13005Reviewed-by: 's avatarRuss Cox <rsc@golang.org>
parent 296529b7
......@@ -5,6 +5,7 @@
package main
import (
"go/build"
"internal/testenv"
"io/ioutil"
"os"
......@@ -123,5 +124,8 @@ func TestDisasmExtld(t *testing.T) {
if runtime.GOOS == "openbsd" && runtime.GOARCH == "arm" {
t.Skip("skipping on openbsd/arm, no support for external linking, issue 10619")
}
if !build.Default.CgoEnabled {
t.Skip("skipping because cgo is not enabled")
}
testDisasm(t, "-ldflags=-linkmode=external")
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment