]> Cypherpunks repositories - gostls13.git/commitdiff
cmd/link: fix TestLargeText
authoreric fang <eric.fang@arm.com>
Thu, 2 Jun 2022 06:54:50 +0000 (06:54 +0000)
committerEric Fang <eric.fang@arm.com>
Fri, 3 Jun 2022 00:13:09 +0000 (00:13 +0000)
Do not need to add single quotes '' when passing the parameter value of
 the -ldflags option, otherwise the following error will be reported:
invalid value "'-linkmode=external'" for flag -ldflags: parameter may
not start with quote character.

Change-Id: I322fa7079ac24c8a68d9cb0872b0a20dbc4893d1
Reviewed-on: https://go-review.googlesource.com/c/go/+/410074
Reviewed-by: Than McIntosh <thanm@google.com>
TryBot-Result: Gopher Robot <gobot@golang.org>
Reviewed-by: Benny Siegert <bsiegert@gmail.com>
Run-TryBot: Eric Fang <eric.fang@arm.com>

src/cmd/link/linkbig_test.go

index 9a4430c162b99de9b56985856b123d306e976619..2551afc8cbe3c2379b7e52908de7ea77680f0a51 100644 (file)
@@ -97,7 +97,7 @@ func TestLargeText(t *testing.T) {
        }
 
        // Build and run with external linking
-       cmd = exec.Command(testenv.GoToolPath(t), "build", "-o", "bigtext", "-ldflags", "'-linkmode=external'")
+       cmd = exec.Command(testenv.GoToolPath(t), "build", "-o", "bigtext", "-ldflags", "-linkmode=external")
        cmd.Dir = tmpdir
        out, err = cmd.CombinedOutput()
        if err != nil {