cmd/go: build sets PWD to relative path #46832
Labels
early-in-cycle
A change that should be done early in the 3 month dev cycle.
FrozenDueToAge
NeedsFix
The path to resolution is known, but the work has not been done.
Milestone
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?
This is a forward of downstream ccache/ccache#860 bug where
ccache
was confused byPWD=.
set bygo build
. In ccache/ccache#860 (comment) Joel Rosdahl notes thatPWD
should be an absolute path.ccache
is fixed since but I think it's worth fixinggo build
not to produce relative paths.Executable single-file example:
Here is a directly executable example to illustrate the problem extracted from
docker
project:What did you expect to see?
Expected the test to build successfully.
What did you see instead?
The
ccache
detects relative path inPWD
and crashes:The text was updated successfully, but these errors were encountered: