aboutsummaryrefslogtreecommitdiff
path: root/src/make.bash
AgeCommit message (Collapse)Author
2021-08-11src/make.*: make --no-clean flag a no-op that prints a warningMatthew Dempsky
This flag is undocumented and is no longer useful. Users who want to install additional toolchains without cleaning the installed packages should just use `go install`. This CL changes cmd/dist to print a warning that --no-clean is deprecated and to advise users to use `go install std cmd` instead, and then otherwise ignores it: ``` $ ./make.bash --no-clean Building Go cmd/dist using $GOROOT_BOOTSTRAP. (devel +b7a85e0003 linux/amd64) warning: --no-clean is deprecated and has no effect; use 'go install std cmd' instead Building Go toolchain1 using $GOROOT_BOOTSTRAP. ``` Fixes #47204. Change-Id: I275031832098401a49e491e324e8de3427973630 Reviewed-on: https://go-review.googlesource.com/c/go/+/341392 Trust: Matthew Dempsky <mdempsky@google.com> Run-TryBot: Matthew Dempsky <mdempsky@google.com> TryBot-Result: Go Bot <gobot@golang.org> Reviewed-by: Ian Lance Taylor <iant@golang.org>
2021-08-06make.bash: do not overwrite GO_LDSO if already setCherry Mui
Change-Id: I704bdb411bda3d8a40906c12f182e268dca4718f Reviewed-on: https://go-review.googlesource.com/c/go/+/340450 Trust: Cherry Mui <cherryyz@google.com> Reviewed-by: Ian Lance Taylor <iant@golang.org> Run-TryBot: Ian Lance Taylor <iant@golang.org> TryBot-Result: Go Bot <gobot@golang.org>
2021-05-18make.bash: fix misuse of continueCherry Mui
Apparently, in bash, the "continue" keyword can only be used inside of a loop, not in an if block. If readelf exists but $CC does not, make.bash emits a warning: ./make.bash: line 135: continue: only meaningful in a `for', `while', or `until' loop Change it to a conditional. Change-Id: I00a0940ed99bc0c565094e506705961b6b3d362e Reviewed-on: https://go-review.googlesource.com/c/go/+/320170 Trust: Cherry Mui <cherryyz@google.com> Run-TryBot: Cherry Mui <cherryyz@google.com> TryBot-Result: Go Bot <gobot@golang.org> Reviewed-by: Ian Lance Taylor <iant@golang.org> Reviewed-by: Cuong Manh Le <cuong.manhle.vn@gmail.com>
2021-03-19make.bash: this change modifies Go to correctly select a dyamic linkerDilyn Corner
Alpine Linux is not the only musl-based Linux distribution. Checking for /etc/alpine-release excludes many other distributions (Oasis, KISS, Sabotage, sta.li). Not having the correct GO_LDSO set during go builds will result in the wrong linker/loader on nonalpine musl systems for pie builds. Instead, the dynamic loader should be checked for every system and set. This results in the correct dynamic linker being found on glibc systems (/lib/ld-linux-x86-64.so.2) and musl systems (/lib/ld-musl-x84_64.so.1). Fixes #45034 Change-Id: I4c9389abc759aa34431dc6c781022636b81d6910 GitHub-Last-Rev: e17b9eb10693bfce7c9ce03af3b15bd0e56e8dbe GitHub-Pull-Request: golang/go#45036 Reviewed-on: https://go-review.googlesource.com/c/go/+/301989 Reviewed-by: Ian Lance Taylor <iant@golang.org> Run-TryBot: Ian Lance Taylor <iant@golang.org> TryBot-Result: Go Bot <gobot@golang.org> Trust: Cherry Zhang <cherryyz@google.com>
2020-09-21make.bash: avoid warning when bootstrap doesn't support GOOS/GOARCHAustin Clements
Currently, if make.bash is run with a GOOS or GOARCH that the bootstrap toolchain doesn't support, it will print an ominous but harmless warning like: 2020/09/21 09:05:27 unsupported GOARCH arm64 This comes from the invocation of "go version" to get the exact bootstrap toolchain version. Since the GOOS and GOARCH don't matter for this purpose, this CL simply clears them on the invocation of the bootstrap toolchain's "go version". Fixes #41525. Change-Id: I17d44eaafed9999b9fa7dcb9fb100b5fd5e554d0 Reviewed-on: https://go-review.googlesource.com/c/go/+/256297 Trust: Austin Clements <austin@google.com> Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org> Reviewed-by: David Chase <drchase@google.com> Run-TryBot: Austin Clements <austin@google.com> TryBot-Result: Go Bot <gobot@golang.org>
2020-09-10all: check GOROOT_BOOTSTRAP executable before bootsrapppingCuong Manh Le
Otherwise we’d still be writing that we're building cmd/dist even if GOROOT_BOOTSTRAP we’re wrongly set. Change-Id: I940e18c3cebae5664f85babc9919e9eb215d5093 Reviewed-on: https://go-review.googlesource.com/c/go/+/253877 Run-TryBot: Cuong Manh Le <cuong.manhle.vn@gmail.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Emmanuel Odeke <emm.odeke@gmail.com>
2019-11-01make.bash: show bootstrap versionBrad Fitzpatrick
For debugging. (The "go1.4" can be misleading since it might actually be go1.4.3 or go1.11 or go1.12 or master) Change-Id: I27520b931a2be018de577a299592d082260aa467 Reviewed-on: https://go-review.googlesource.com/c/go/+/204757 Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Ian Lance Taylor <iant@golang.org>
2019-04-23cmd/go: add env -w and env -u to set and unset default env varsRuss Cox
Setting environment variables for go command configuration is too difficult and system-specific. This CL adds go env -w, to change the default settings more easily, in a portable way. It also adds go env -u, to unset those changes. See https://golang.org/design/30411-env for details. Fixes #30411. Change-Id: I36e83f55b666459f8f7f482432a4a6ee015da71d Reviewed-on: https://go-review.googlesource.com/c/go/+/171137 Run-TryBot: Russ Cox <rsc@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Bryan C. Mills <bcmills@google.com>
2019-03-11cmd,std: add go.mod filesBryan C. Mills
Updates #30241 Updates #30228 Change-Id: Ida0fe8263bf44e0498fed2048e22283ba5716835 Reviewed-on: https://go-review.googlesource.com/c/go/+/164622 Run-TryBot: Bryan C. Mills <bcmills@google.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Jay Conrod <jayconrod@google.com>
2019-03-01cmd/dist, cmd/link: allow passing default dynamic linker/loaderTobias Klauser
Add an environment variable to make.bash to allow setting the default dynamic linker/loader. This fixes alpine builds to use /lib/ld-musl-x86_64.so.1: $ readelf -l ../bin/go | grep 'interpreter:' | sed -e 's/^.*interpreter: \(.*\)[]]/\1/' /lib/ld-musl-x86_64.so.1 Also re-enable the internal linker tests that were previously disabled for alpine (CL 41759, CL 41678). Fixes #18243 Updates #19938 This resurrects CL 50070 authored by Jessie Frazelle. Change-Id: I132b5282045a3d60c8568e3b002a7f075eac2d93 Reviewed-on: https://go-review.googlesource.com/c/163977 Run-TryBot: Tobias Klauser <tobias.klauser@gmail.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Ian Lance Taylor <iant@golang.org>
2018-11-16build: clear GO111MODULE during make.bash etcRuss Cox
The standard build assumes the variable is unset. Make it so, like we do for GOFLAGS, GOBIN, and so on. Change-Id: I4ad5695f8021b08bd1a35dd99112970a813d247c Reviewed-on: https://go-review.googlesource.com/c/149959 Run-TryBot: Russ Cox <rsc@golang.org> Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
2018-08-01cmd/go: add $GOFLAGS environment variableRuss Cox
People sometimes want to turn on a particular go command flag by default. In Go 1.11 we have at least two different cases where users may need this. 1. Linking can be noticeably slower on underpowered systems due to DWARF, and users may want to set -ldflags=-w by default. 2. For modules, some users or CI systems will want vendoring always, so they want -getmode=vendor (soon to be -mod=vendor) by default. This CL generalizes the problem to “set default flags for the go command.” $GOFLAGS can be a space-separated list of flag settings, but each space-separated entry in the list must be a standalone flag. That is, you must do 'GOFLAGS=-ldflags=-w' not 'GOFLAGS=-ldflags -w'. The latter would mean to pass -w to go commands that understand it (if any do; if not, it's an error to mention it). For #26074. For #26318. Fixes #26585. Change-Id: I428f79c1fbfb9e41e54d199c68746405aed2319c Reviewed-on: https://go-review.googlesource.com/126656 Run-TryBot: Russ Cox <rsc@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Rob Pike <r@golang.org>
2018-06-20make.bash: don't pass GOOS and GOARCH to cmd/go when finding GOROOT_BOOTSTRAPLE Manh Cuong
Fixes #25962 Change-Id: I10d41713f6aef100d7b2c8c976f22d1c8ac376d5 Reviewed-on: https://go-review.googlesource.com/119937 Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2018-05-04src/*.bash: remove some trailing whitespaceZhou Peng
Change-Id: I11793daafdb69156b1dafaa80fe501fcaeeff202 Reviewed-on: https://go-review.googlesource.com/111435 Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2017-11-03cmd/dist: fix bad LC_TIME assumption in 'date' invocationAlberto Donizetti
With GOBUILDTIMELOGFILE set, make.bash logs the starting time using $ echo $(date) > file and expects to be able to read the date back with time.Parse(time.UnixDate) but in some locales the default date format is not the same as time.UnixDate; for example on LC_TIME="en_GB.UTF-8" $ locale date_fmt %a %e %b %H:%M:%S %Z %Y Fix this by setting LC_TIME=C before the date command invocation. Fixes #22541 Change-Id: I59bf944bb868e2acdd816c7e35134780cdbfc6a6 Reviewed-on: https://go-review.googlesource.com/75370 Run-TryBot: Alberto Donizetti <alb.donizetti@gmail.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Russ Cox <rsc@golang.org> Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2017-11-01make.bash: show correct GOROOT_BOOTSTRAP when using `go env GOROOT`Filippo Valsorda
Also, support spaces in go binaries locations, and document GOROOT_BOOTSTRAP at the top. Change-Id: I643d22df57aad9a2200cc256edd20e8c811bc70d Reviewed-on: https://go-review.googlesource.com/74951 Run-TryBot: Filippo Valsorda <hi@filippo.io> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Russ Cox <rsc@golang.org>
2017-10-31build: quiet make.bash, make.bat, make.rcRuss Cox
The signal-to-noise ratio is too low. Stop printing the name of every package. Can still get the old output with make.bash -v. Change-Id: Ib2c82e037166e6d2ddc31ae2a4d29af5becce574 Reviewed-on: https://go-review.googlesource.com/74351 Run-TryBot: Russ Cox <rsc@golang.org> Reviewed-by: Ian Lance Taylor <iant@golang.org> Reviewed-by: David Crawshaw <crawshaw@golang.org>
2017-10-31cmd/dist: log timing to $GOBUILDTIMELOGFILERuss Cox
We can't make all.bash faster if we can't measure it. Measure it. Change-Id: Ia5da791d4cfbfa1fd9a8e905b3188f63819ade73 Reviewed-on: https://go-review.googlesource.com/73990 Reviewed-by: Ian Lance Taylor <iant@golang.org>
2017-10-25build: move final steps of make.bash, make.bat, make.rc into cmd/distRuss Cox
This CL expands the job of "dist bootstrap" to be "finish make.bash". I need to change that logic in upcoming CLs related to cmd/go changes, and I'd rather not change it in three places in three different shell script languages. Change-Id: I545dc215e408289e4d0b28f7c2ffcd849d89ad3b Reviewed-on: https://go-review.googlesource.com/72870 Reviewed-by: David Crawshaw <crawshaw@golang.org>
2017-08-25build: add `go env GOROOT` as default GOROOT_BOOTSTRAP valueWei Congrui
This change also added the same check in make.bash to make.rc, which makes sure $GOROOT_BOOTSTRAP != $GOROOT. Fixes #14339 Change-Id: I2758f4a845bae42ace02492fc6a911f6d6247d26 Reviewed-on: https://go-review.googlesource.com/57753 Run-TryBot: Ian Lance Taylor <iant@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Ian Lance Taylor <iant@golang.org>
2017-03-14*.bash: always use the same string equality operatorDaniel Martí
POSIX Shell only supports = to compare variables inside '[' tests. But this is Bash, where == is an alias for =. In practice they're the same, but the current form is inconsisnent and breaks POSIX for no good reason. Change-Id: I38fa7a5a90658dc51acc2acd143049e510424ed8 Reviewed-on: https://go-review.googlesource.com/38031 Reviewed-by: Ian Lance Taylor <iant@golang.org> Run-TryBot: Ian Lance Taylor <iant@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
2017-03-10cmd/go: when expanding "cmd", skip vendored main packagesIan Lance Taylor
We are vendoring pprof from github.com/google/pprof, which comes with a main package. If we don't explicitly skip that main package, then `go install cmd` will install the compiled program in $GOROOT/bin. Fixes #19441. Change-Id: Ib268ffd16d4be65f7d80e4f8d9dc6e71523a94de Reviewed-on: https://go-review.googlesource.com/38007 Run-TryBot: Ian Lance Taylor <iant@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Raul Silvera <rsilvera@google.com> Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2017-03-09src/*.bash: use tabs consistentlyDaniel Martí
make.bash used mostly tabs and buildall.bash used mostly spaces, but they were both mixing them. Be consistent and use tabs, as that's what's more common and what the Go code uses. Change-Id: Ia6affbfccfe64fda800c1ac400965df364d2c545 Reviewed-on: https://go-review.googlesource.com/37967 Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org> Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
2016-10-03cmd/dist, cmd/go: add environment variable override for pkg-configBoris Nagaev
Allow overriding default name of `pkg-config` tool via environment variable PKG_CONFIG (same as used by autoconf pkg.m4 macros). This facilitates easy cross-compilation of cgo code. Original patch against Go <= 1.4 was written by xnox_canonical <dimitri.ledkov@canonical.com> in 2014. Source: https://codereview.appspot.com/104960043/ Fixes #16253 Change-Id: I31c33ffc3ecbff65da31421e6188d092ab4fe7e4 Reviewed-on: https://go-review.googlesource.com/29991 Reviewed-by: Ian Lance Taylor <iant@golang.org> Run-TryBot: Ian Lance Taylor <iant@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
2016-05-19build: unset GOBIN during buildBrad Fitzpatrick
Fixes #14340 Change-Id: I43e1624fafc972fb868708c3857fc8acf1bfbbd7 Reviewed-on: https://go-review.googlesource.com/23255 Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org> Reviewed-by: Rob Pike <r@golang.org>
2016-03-18cmd/dist: redo flag-passing for bootstrapDavid Chase
This ought to revert the bad effects of https://go-review.googlesource.com/#/c/20775/ If you don't pass BOOT_GO_GCFLAGS, you get the old behavior. Tweaked to allow multiple space-separated flags in BOOT_GO_GCFLAGS. Change-Id: I2a22a04211b4535d1c5a8ec7a8a78cb051161c31 Reviewed-on: https://go-review.googlesource.com/20871 Run-TryBot: David Chase <drchase@google.com> Reviewed-by: Russ Cox <rsc@golang.org>
2016-03-18cmd/compile: get gcflags to bootstrap; ssa debug opts for "all"David Chase
This is intended to help debug compiler problems that pop up in the bootstrap phase of make.bash. GO_GCFLAGS does not normally apply there. Options-for-all phases is intended to allow crude tracing (and full timing) by turning on timing for all phases, not just one. Phase names can also be specified using a regular expression, for example BOOT_GO_GCFLAGS=-d='ssa/~^.*scc$/off' \ GO_GCFLAGS='-d=ssa/~^.*scc$/off' ./make.bash I just added this because it was the fastest way to get me to a place where I could easily debug the compiler. Change-Id: I0781f3e7c19651ae7452fa25c2d54c9a245ef62d Reviewed-on: https://go-review.googlesource.com/20775 Reviewed-by: Keith Randall <khr@golang.org> Run-TryBot: David Chase <drchase@google.com> TryBot-Result: Gobot Gobot <gobot@golang.org>
2016-02-24cmd/go, go/build: add support for Fortrankortschak
This change adds support for Fortran files (.f, .F, .for, .f90) to the go tool, in a similar fashion to Objective-C/C++. Only gfortran is supported out of the box so far but leaves other Fortran compiler toolchains the ability to pass the correct link options via CGO_LDFLAGS. A simple test (misc/cgo/fortran) has been added and plugged into the general test infrastructure. This test is only enabled when the $FC environment variable is defined (or if 'gfortran' was found in $PATH.) Derived from CL 4114. Change-Id: Ifc855091942f95c6e9b17d91c17ceb4eee376408 Reviewed-on: https://go-review.googlesource.com/19670 Reviewed-by: Ian Lance Taylor <iant@golang.org> Run-TryBot: Ian Lance Taylor <iant@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
2015-12-17src: remove reference to since-deleted dist -s flagBrad Fitzpatrick
(Found while debugging release problems with go1.6beta1) Updates #12002 Change-Id: Iec197a754205e7fd28be154f27f17f3315886364 Reviewed-on: https://go-review.googlesource.com/18011 Reviewed-by: Chris Broadfoot <cbro@golang.org>
2015-08-24make.bash: abort if $GOROOT_BOOTSTRAP == $GOROOTDave Cheney
Fixes #12214 Change-Id: I82586b54ac7b9c0c71055bb66b921e3efbf4977c Reviewed-on: https://go-review.googlesource.com/13719 Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org> Reviewed-by: Andrew Gerrand <adg@golang.org>
2015-06-17doc: replace references to {5..9}{g,l} with go tool compile and go tool linkJeremy Jackins
I updated some references to 6g, 6l and friends that I came across, as those programs don't exist anymore. I also fixed some echos in make.rc to match other make.* scripts while I was there. Change-Id: Ib84532cd4688cf65174dd9869e5d42af98a20a48 Reviewed-on: https://go-review.googlesource.com/11162 Reviewed-by: Ian Lance Taylor <iant@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-04[dev.cc] all: merge master (b8fcae0) into dev.ccRuss Cox
Change-Id: I2aa1d0b0c4cf7632a54e843810959b468e3812ab
2015-02-04cmd/go, make: remove ccflagsJosh Bleecher Snyder
cc is no more. Change-Id: I8d1bc0d2e471cd9357274204c9bc1fa67cbc272d Reviewed-on: https://go-review.googlesource.com/3833 Reviewed-by: Ian Lance Taylor <iant@golang.org> Reviewed-by: Andrew Gerrand <adg@golang.org>
2015-01-21[dev.cc] build: do not 'clean -i std' between dist and go_bootstrapRuss Cox
Executing 'clean -i std' removes installed Go programs, including the toolchain binaries we need for building. It's not clear why the 'clean -i std' is here in the first place. cmd/dist just removed the entire pkg tree, so everything is new. The only reason for 'clean -i std' would be if you don't trust that dist compiled the packages properly. If that's true for some reason, we can fix cmd/dist, or add -a to the install commands that follow. Perhaps clean -i std should not remove tools, or perhaps std should not expand to any tools. Not sure. Also remove banner from make.bat and make.rc that was already removed from make.bash. cmd/dist prints it now. Also fix array size error in liblink/objfile.c. Fixes dev.cc build. Change-Id: I60855e001a682efce55ad9aa307a8f3ee47f7366 Reviewed-on: https://go-review.googlesource.com/3100 Reviewed-by: Russ Cox <rsc@golang.org>
2015-01-21[dev.cc] cmd/dist: bootstrap Go toolchain using Go 1.4Russ Cox
Bootstrap the Go parts of the Go toolchain using Go 1.4, as described in https://golang.org/s/go15bootstrap. The first Go part of the Go toolchain will be cmd/objwriter, but for now that's just an empty program to test that this new code works. Once the build dashboard is okay with this change, we'll make objwriter a real program depended upon by the build. Change-Id: Iad3dce675571cbdb5ab6298fe6f98f53ede47d5c Reviewed-on: https://go-review.googlesource.com/3044 Reviewed-by: Ian Lance Taylor <iant@golang.org>
2015-01-14[dev.cc] build: do not pass GOHOSTOS and GOHOSTARCH to Go 1.4 buildRuss Cox
Go 1.4 should build what it knows how to build. GOHOSTOS and GOHOSTARCH are for the Go 1.5 build only. Change-Id: Id0f367f03485100a896e61cfdace4ac44a22e16d Reviewed-on: https://go-review.googlesource.com/2818 Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2015-01-14[dev.cc] build: fix cross-compilationRuss Cox
Fixes #9574. Change-Id: Ifd7ecccb25e934f9aba284b2d72b6b22f18cb0b6 Reviewed-on: https://go-review.googlesource.com/2812 Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
2015-01-10build: require old Go to build new Go (and convert cmd/dist to Go)Russ Cox
This CL introduces the bootstrap requirement that in order to build the current release (or development version) of Go, you need an older Go release (1.4 or newer) already installed. This requirement is the whole point of this CL. To enforce the requirement, convert cmd/dist from C to Go. With this bootstrapping out of the way, we can move on to replacing other, larger C programs like the Go compiler, the assemblers, and the linker. See golang.org/s/go15bootstrap for details. Change-Id: I53fd08ddacf3df9fae94fe2c986dba427ee4a21d Reviewed-on: https://go-review.googlesource.com/2470 Reviewed-by: Ian Lance Taylor <iant@golang.org> Reviewed-by: Rob Pike <r@golang.org>
2014-12-13build: change all.bash output to be more markdown-friendlyRuss Cox
People keep pasting all.bash output into GitHub bugs, which turns the # lines into <h1> headlines. Add some more #s so that the bug reports are more readable. Not ideal but seems like the best of a few bad options. Change-Id: I4c69930ec304b2d504d7cd66221281a8577b87ae Reviewed-on: https://go-review.googlesource.com/1286 Reviewed-by: Ian Lance Taylor <iant@golang.org> Reviewed-by: Andrew Gerrand <adg@golang.org>
2014-09-08build: adjustments for move from src/pkg to srcRuss Cox
This CL adjusts code referring to src/pkg to refer to src. Immediately after submitting this CL, I will submit a change doing 'hg mv src/pkg/* src'. That change will be too large to review with Rietveld but will contain only the 'hg mv'. This CL will break the build. The followup 'hg mv' will fix it. For more about the move, see golang.org/s/go14nopkg. LGTM=r R=r CC=golang-codereviews https://golang.org/cl/134570043
2014-05-20build: make nacl passRuss Cox
Add nacl.bash, the NaCl version of all.bash. It's a separate script because it builds a variant of package syscall with a large zip file embedded in it, containing all the input files needed for tests. Disable various tests new since the last round, mostly the ones using os/exec. Fixes #7945. LGTM=dave R=golang-codereviews, remyoudompheng, dave, bradfitz CC=golang-codereviews https://golang.org/cl/100590044
2014-04-29make.bash: if CC is not set, and gcc doesn't exist, try clang/clang++.Shenghou Ma
This should make Go build without setting CC and CXX on newer FreeBSDs. LGTM=iant R=golang-codereviews, dave, gobot, iant CC=golang-codereviews https://golang.org/cl/89230045
2014-02-06cmd/go, cmd/cgo, make.bash: cross compiling with cgo enabledElias Naur
Introduce two new environment variables, CC_FOR_TARGET and CXX_FOR_TARGET. CC_FOR_TARGET defaults to CC and is used when compiling for GOARCH, while CC remains for compiling for GOHOSTARCH. CXX_FOR_TARGET defaults to CXX and is used when compiling C++ code for GOARCH. CGO_ENABLED defaults to disabled when cross compiling and has to be explicitly enabled. Update #4714 LGTM=minux.ma, iant R=golang-codereviews, minux.ma, iant, rsc, dominik.honnef CC=golang-codereviews https://golang.org/cl/57100043
2013-10-01cmd/dist, build: support building statically linked toolchainShenghou Ma
Added a new $GO_DISTFLAGS to make.bash, and while we're here, added mention $CXX in make.bash (CL 13704044). Fixes #6448. Update #3564 We can pass GO_DISTFLAGS=-s from misc/dist to make.bash so that it will build a statically linked toolchain. (Note: OS X doesn't have the concept of static linking, so don't pass GO_DISTFLAGS=-s for OS X builds) R=adg, rsc, iant CC=golang-dev https://golang.org/cl/13887043
2013-08-19make.bash: exit if dist failsRob Pike
The shell's -e doesn't work across "eval"; need to error-check by hand. The recent spate of Darwin build failures pointed out that if the first run of cmd/dist fails, we keep going. We shouldn't. R=golang-dev, dsymonds CC=golang-dev https://golang.org/cl/13098043
2013-04-16cmd/dist, make.bash: pass -mmacosx-version-min=10.6 to gcc on DarwinShenghou Ma
Fixes #5261. R=golang-dev, r CC=golang-dev https://golang.org/cl/8798044
2013-03-29cmd/dist, cmd/ld: GO_EXTLINK_ENABLED=0 defaults to -linkmode=internalIan Lance Taylor
Change build system to set GO_EXTLINK_ENABLED=0 by default for OS X 10.6, since the system linker has a bug and can not handle the object files generated by 6l. Fixes #5130. R=golang-dev, r CC=golang-dev https://golang.org/cl/8183043
2013-03-16make.bash: delete vestigial TODO, now resolvedRob Pike
R=golang-dev, minux.ma CC=golang-dev https://golang.org/cl/7789050
2013-03-12go/types: delete from main repo; part of move to go.expRob Pike
See also https://golang.org/cl/7656044 R=golang-dev, gri, rsc CC=golang-dev https://golang.org/cl/7625048