tailscale/tool/gocross
Brad Fitzpatrick b56058d7e3 tool/gocross: fix regression detecting when gocross needs rebuild
Fix regression from #8108 (Mar 2023). Since that change, gocross has
always been rebuilt on each run of ./tool/go (gocross-wrapper.sh),
adding ~100ms.  (Well, not totally rebuilt; cmd/go's caching still
ends up working fine.)

The problem was $gocross_path was just "gocross", which isn't in my
path (and "." isn't in my $PATH, as it shouldn't be), so this line was
always evaluating to the empty string:

    gotver="$($gocross_path gocross-version 2>/dev/null || echo '')"

The ./gocross is fine because of the earlier `cd "$repo_root"`

Updates tailscale/corp#21262
Updates tailscale/corp#21263

Change-Id: I80d25446097a3bb3423490c164352f0b569add5f
Signed-off-by: Brad Fitzpatrick <bradfitz@tailscale.com>
2024-07-01 14:40:51 -07:00
..
autoflags_test.go tool/gocross: add debug data to CGO builds 2024-05-22 20:47:28 -07:00
autoflags.go tool/gocross: add debug data to CGO builds 2024-05-22 20:47:28 -07:00
env_test.go tool/gocross: a tool for building Tailscale binaries 2023-02-22 17:55:16 +00:00
env.go tool/gocross: a tool for building Tailscale binaries 2023-02-22 17:55:16 +00:00
exec_other.go tool/gocross: a tool for building Tailscale binaries 2023-02-22 17:55:16 +00:00
exec_unix.go tool/gocross: a tool for building Tailscale binaries 2023-02-22 17:55:16 +00:00
gocross_wrapper_test.go tool/gocross: fix regression detecting when gocross needs rebuild 2024-07-01 14:40:51 -07:00
gocross-wrapper.sh tool/gocross: fix regression detecting when gocross needs rebuild 2024-07-01 14:40:51 -07:00
gocross.go various: add golangci-lint, fix issues (#7905) 2023-04-17 18:38:24 -04:00
goroot.go all: cleanup unused code, part 1 (#10661) 2023-12-20 14:50:30 -08:00
toolchain.go tool/gocross: support running from outside the repo dir 2023-03-20 15:01:58 -07:00