Open qiulaidongfeng opened 2 months ago
Related Issues
(Emoji vote if this was helpful or unhelpful; more detailed feedback welcome in this discussion.)
Adding some detail: The pkg-config implementation in question is u-config, and the test failure isn't specific to Windows. It fails unless standard error includes a very specific error string (Package .* not found
), and my implementation outputs a slightly different error string. The two most popular implementations, pkg-config and pkgconf, output something like this:
$ pkg-config --cflags libnot-a-valid-cgo-library
Package libnot-a-valid-cgo-library was not found in the pkg-config search path.
...
While u-config does this, which doesn't match:
$ pkg-config --cflags libnot-a-valid-cgo-library
pkg-config: could not find package 'libnot-a-valid-cgo-library'
Change https://go.dev/cl/596935 mentions this issue: cmd/go: relax the regular expression of TestScript/list_pkgconfig_error
Go version
go version devel go1.23-beaf7f32 Mon Jun 10 22:06:47 2024 +0000 windows/amd64
Output of
go env
in your module/workspace:What did you do?
use w64devkit 1.23.0 , from https://github.com/skeeto/w64devkit/releases/tag/v1.23.0 get. run
go test -short -run=TestScript/list_pkgconfig_error cmd/go
What did you see happen?
What did you expect to see?
test pass.