Skip to content

Commit

Permalink
Replace ROOT with pkg
Browse files Browse the repository at this point in the history
Instead of writing a new file for this purpose specifically, use the
existing `pkg` directory.
  • Loading branch information
fmeum committed Nov 27, 2022
1 parent b73230b commit 1d90abd
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions go/private/actions/stdlib.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -75,13 +75,11 @@ def _sdk_stdlib(go):

def _build_stdlib(go):
pkg = go.declare_directory(go, path = "pkg")
root_file = go.declare_file(go, path = "ROOT")
args = go.builder_args(go, "stdlib")
args.add("-out", root_file.dirname)
args.add("-out", pkg.dirname)
if go.mode.race:
args.add("-race")
args.add_all(link_mode_args(go.mode))
go.actions.write(root_file, "")
env = go.env
if go.mode.pure:
env.update({"CGO_ENABLED": "0"})
Expand Down Expand Up @@ -116,5 +114,5 @@ def _build_stdlib(go):
return GoStdLib(
_list_json = _build_stdlib_list_json(go),
libs = [pkg],
root_file = root_file,
root_file = pkg,
)

0 comments on commit 1d90abd

Please sign in to comment.