Skip to content

Commit

Permalink
cross-go.mk: Fix mod file download missing u+rw flags
Browse files Browse the repository at this point in the history
Ref golang/go#31481
Otherwise files under pkg/mod/golang.org/* are read-only and
make clean cannot proceed with it's deletion.
  • Loading branch information
th0ma7 committed Feb 1, 2024
1 parent 05ae8f0 commit 854b2f8
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions mk/spksrc.cross-go-env.mk
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,9 @@ ENV += PATH=$(WORK_DIR)/../../../native/go/work-native/go/bin/:$$PATH
ENV += GOARCH=$(GO_ARCH)
ENV += GOOS=$(GOOS)

# Ensure downloaded mod are u+rw
ENV += GOFLAGS=-modcacherw

ifneq ($(strip $(GO_BIN_DIR)),)
GO_BUILD_ARGS := -o $(GO_BIN_DIR) $(GO_BUILD_ARGS)
endif
Expand Down

0 comments on commit 854b2f8

Please sign in to comment.