We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
go version
$ go version go version devel +a4ba411b1 Wed Jul 1 15:29:29 2020 +0000 linux/amd64
Yes.
go env
$ go env GO111MODULE="" GOARCH="amd64" GOBIN="" GOCACHE="/home/dave/.cache/go-build" GOENV="/home/dave/.config/go/env" GOEXE="" GOFLAGS="" GOHOSTARCH="amd64" GOHOSTOS="linux" GOINSECURE="" GOMODCACHE="/home/dave/Source/Go/pkg/mod" GONOPROXY="" GONOSUMDB="" GOOS="linux" GOPATH="/home/dave/Source/Go" GOPRIVATE="" GOPROXY="direct" GOROOT="/home/dave/Source/golang" GOSUMDB="off" GOTMPDIR="" GOTOOLDIR="/home/dave/Source/golang/pkg/tool/linux_amd64" GCCGO="gccgo" AR="ar" CC="gcc" CXX="g++" CGO_ENABLED="1" GOMOD="/home/dave/Source/golang/src/go.mod" CGO_CFLAGS="-g -O2" CGO_CPPFLAGS="" CGO_CXXFLAGS="-g -O2" CGO_FFLAGS="-g -O2" CGO_LDFLAGS="-g -O2" PKG_CONFIG="pkg-config" GOGCCFLAGS="-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build827569325=/tmp/go-build -gno-record-gcc-switches"
package foo // #cgo pkg-config: mozjs-68 include "C" func main() {}
$ pkg-config --cflags mozjs-68 -include /usr/include/mozjs-68/js/RequiredDefines.h -isystem /usr/include/mozjs-68
I expected it to compile.
invalid flag in pkg-config --cflags: -include
It appears validCompilerFlagsWithNextArg in src/cmd/go/internal/work/security.go is missing -include.
validCompilerFlagsWithNextArg
src/cmd/go/internal/work/security.go
-include
The text was updated successfully, but these errors were encountered:
Change https://golang.org/cl/240739 mentions this issue: cmd/go: Add -include to cgo whitelist
cmd/go: Add -include to cgo whitelist
Sorry, something went wrong.
94f3762
No branches or pull requests
What version of Go are you using (
go version
)?Does this issue reproduce with the latest release?
Yes.
What operating system and processor architecture are you using (
go env
)?go env
OutputWhat did you do?
What did you expect to see?
I expected it to compile.
What did you see instead?
invalid flag in pkg-config --cflags: -include
It appears
validCompilerFlagsWithNextArg
insrc/cmd/go/internal/work/security.go
is missing-include
.The text was updated successfully, but these errors were encountered: