FS#56229 - [go] package missing race libs
Attached to Project:
Arch Linux
Opened by Patrick Hemmer (phemmer) - Saturday, 04 November 2017, 03:58 GMT
Last edited by Bartłomiej Piotrowski (Barthalion) - Sunday, 10 December 2017, 14:41 GMT
Opened by Patrick Hemmer (phemmer) - Saturday, 04 November 2017, 03:58 GMT
Last edited by Bartłomiej Piotrowski (Barthalion) - Sunday, 10 December 2017, 14:41 GMT
|
Details
Description:
Attempting to build GO packages using `go build --race` results in permission errors as go attempts to build and install missing race libs in stdlib. # go build mypkg go install container/heap: open /usr/lib/go/pkg/linux_amd64_race/container/heap.a: permission denied go install encoding/csv: open /usr/lib/go/pkg/linux_amd64_race/encoding/csv.a: permission denied go install html: open /usr/lib/go/pkg/linux_amd64_race/html.a: permission denied go install database/sql/driver: mkdir /usr/lib/go/pkg/linux_amd64_race/database: permission denied go install expvar: open /usr/lib/go/pkg/linux_amd64_race/expvar.a: permission denied go install archive/tar: mkdir /usr/lib/go/pkg/linux_amd64_race/archive/: permission denied go install text/template/parse: mkdir /usr/lib/go/pkg/linux_amd64_race/text/template/: permission denied The binary package downloadable from https://golang.org/dl/ does not have this issue. I reported the issue upstream (https://github.com/golang/go/issues/22372) since it looks like the GO package in Arch is built following the official GO build doc, and the response was that the build procedure needs to be updated to include: go install -race -a std The response on the upstream issue also indicates other steps need to be taken to get something equivalent to the official binary release, but it was not stated what those steps are. Additional info: * package version(s) 1.9.2-2 * config and/or log files etc. Steps to reproduce: Try to build the following code with `go build -race`: package main import "encoding/csv" func main() { csv.NewReader(nil) } |
This task depends upon
Closed by Bartłomiej Piotrowski (Barthalion)
Sunday, 10 December 2017, 14:41 GMT
Reason for closing: Fixed
Additional comments about closing: go 2:1.9.2-3
Sunday, 10 December 2017, 14:41 GMT
Reason for closing: Fixed
Additional comments about closing: go 2:1.9.2-3
* "optional feature" means something that can be enabled/disabled. `go build -race` is built into go and can not be disabled.
* "doesn't work" means broken, which is a bug. Adding functionality which is not currently present is a feature request.
And that's exactly what this is. An optional feature can, and often is, build time optional, not run time optional. That's what you've got here, an optional part of the go library isn't enabled and you want it to be.