aboutsummaryrefslogtreecommitdiff
path: root/src/race.bat
AgeCommit message (Collapse)Author
2020-06-08all: treat all files as binary, but check in .bat with CRLFDmitri Shuralyov
This is a followup to CL 96495. It should be simpler and more robust to achieve .bat files having CRLF line endings by treating it as a binary file, like all other files, and checking it in with the desired CRLF line endings. A test is used to check the entire Go tree, short of directories starting with "." and named "testdata", for any .bat files that have anything other than strict CRLF line endings. This will help catch any accidental modifications to existing .bat files or check ins of new .bat files. Importantly, this is compatible with how Gerrit serves .tar.gz files, making it so that CRLF line endings are preserved. The Go project is supported on many different environments, some of which may have limited git implementations available, or none at all. Relying on fewer git features and special rules makes it easier to have confidence in the exact content of all files. Additionally, Go development started in Subversion, moved to Perforce, then Mercurial, and now uses Git.¹ Reducing its reliance on git-specific features will help if there will be another transition in the project's future. There are only 5 .bat files in the entire Go source tree, so a new one being added is a rare event, and we prefer to do things in Go instead. We still have the option of improving the experience for developers by adding a pre-commit converter for .bat files to the git-codereview tool. ¹ https://groups.google.com/d/msg/golang-dev/sckirqOWepg/YmyT7dWJiocJ Fixes #39391. For #37791. Change-Id: I6e202216322872f0307ac96f1b8d3f57cb901e6b Reviewed-on: https://go-review.googlesource.com/c/go/+/236437 Reviewed-by: Bryan C. Mills <bcmills@google.com>
2020-03-22build: force all Windows batch files to CRLFGiovanni Bajo
Batch files should use CRLF endings. LF endings mostly work but in some situations they cause random errors like goto commands failing for mysterious reasons. See golang.org/issue/37791 for more information. Next CL triggered one of such bug (a label was not being recognized), so prepare for it by converting to CRLF. This CL also touches all existing batch files to force git to update the line endings (unfortunately, changing .gitattributes only has effect next time the file is checked out or modified). Fixes #37791 Updates #9281 Change-Id: I6f9a114351cb7ac9881914400aa210c930eb8cc1 Reviewed-on: https://go-review.googlesource.com/c/go/+/96495 Run-TryBot: Giovanni Bajo <rasky@develer.com> Reviewed-by: Ian Lance Taylor <iant@golang.org> Reviewed-by: Alex Brainman <alex.brainman@gmail.com>
2018-08-25cmd/dist: fix compilation on windowsFlorin Pățan
Add missing extensions to binary files in order to allow execution. Change-Id: Idfe4c72c80c26b7b938023bc7bbe1ef85e1aa7b0 Change-Id: Idfe4c72c80c26b7b938023bc7bbe1ef85e1aa7b0 GitHub-Last-Rev: ed9d8124270c30b7f25f89656432ef5089466c7e GitHub-Pull-Request: golang/go#26464 Reviewed-on: https://go-review.googlesource.com/124936 Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org> Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2015-12-29cmd/dist: make test default to --no-rebuildRuss Cox
I'm tired of having to remember it on every command. Rebuilding everything is the wrong default. This CL updates the build script, but the builders may (or may not) need work, depending on whether they rebuild using the test command (I doubt it). Change-Id: I21f202a2f13e73df3f6bd54ae6a317c467b68151 Reviewed-on: https://go-review.googlesource.com/18084 Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2015-07-11all: link to https instead of httpBrad Fitzpatrick
The one in misc/makerelease/makerelease.go is particularly bad and probably warrants rotating our keys. I didn't update old weekly notes, and reverted some changes involving test code for now, since we're late in the Go 1.5 freeze. Otherwise, the rest are all auto-generated changes, and all manually reviewed. Change-Id: Ia2753576ab5d64826a167d259f48a2f50508792d Reviewed-on: https://go-review.googlesource.com/12048 Reviewed-by: Rob Pike <r@golang.org>
2015-06-09cmd/dist: move guts of race.bash into distBrad Fitzpatrick
After a little build coordinator change, this will get us sharding of the race builder. Update #11074 Change-Id: I4c55267563b6f5e213def7dd6707c837ae2106bf Reviewed-on: https://go-review.googlesource.com/10845 Reviewed-by: Andrew Gerrand <adg@golang.org>
2015-02-23[dev.cc] cmd/go: fix expansion of 'std', add 'cmd'Russ Cox
The wildcard 'std' is defined in documentation to be all the packages in the Go standard library. It has also historically matched commands in the main repo, but as we implement core commands in Go, that becomes problematic. We need a wildcard that means just the library, and since 'std' is already documented to have that definition, make it so. Add a new wildcard 'cmd' for the commands in the main repo ($GOROOT). Commands that want both can say 'std cmd' (or 'cmd std') to get the effect of the old 'std'. Update make.bash etc to say both std and cmd most of the time. Exception: in race.bash, do not install race-enabled versions of the actual commands. This avoids trying to write binaries while using them, but more importantly it avoids enabling the race detector and its associated memory overhead for the already memory-hungry compilers. Change-Id: I26bb06cb13b636dfbe71a015ee0babeb270a0275 Reviewed-on: https://go-review.googlesource.com/5550 Run-TryBot: Russ Cox <rsc@golang.org> Reviewed-by: Rob Pike <r@golang.org>
2015-02-07build: fix race.bat flagsBrad Fitzpatrick
The old C-based dist accepted merged flags (-wp) but the Go-based dist requires -w -p This should get the Windows race builder running properly, along with https://go-review.googlesource.com/#/c/4132/ Update #8640 Change-Id: Ic17bbe9ea6c8b3d3e9b29f94e234d014f2926439 Reviewed-on: https://go-review.googlesource.com/4133 Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2014-05-07race.bash,race.bat: unset GOROOT_FINAL during testsAlex Brainman
Just like run.* scripts do. Fixes race build. LGTM=dave, dvyukov R=dvyukov, dave CC=golang-codereviews https://golang.org/cl/98980043
2013-12-17race.bat: set exit statusDmitriy Vyukov
R=golang-dev, alex.brainman CC=golang-dev https://golang.org/cl/43340043
2013-12-17race.bat: fix env setupDmitriy Vyukov
Currently it fails as: go tool dist: $GOROOT is not set correctly or not exported GOROOT=c:\go c:\go\include\u.h does not exist Fail. R=golang-dev, bradfitz CC=golang-dev https://golang.org/cl/42550044
2013-09-29race.bash, race.bat: build a race enabled cmd/cgo before trying to use itDave Cheney
Fixes #5537. To avoid `go install -v race std` replacing cmd/cgo with a race enabled version and another package trying to build a cgo enabled package, always build cmd/cgo race enabled before doing the rest of the build. R=remyoudompheng, rsc, dvyukov, minux.ma CC=golang-dev https://golang.org/cl/14071044
2013-02-03src: add race.batShenghou Ma
R=golang-dev, dave, alex.brainman CC=golang-dev https://golang.org/cl/7133064