This CL makes it possible to run make.bash with
GOOS and GOARCH set to something other than
the native host GOOS and GOARCH.
As part of the CL, the tool directory moves from bin/tool/
to pkg/tool/goos_goarch where goos and goarch are
the values for the host system (running the build), not
the target. pkg/ is not technically appropriate, but C objects
are there now tool (pkg/obj/) so this puts all the generated
binaries in one place (rm -rf $GOROOT/pkg cleans everything).
Including goos_goarch in the name allows different systems
to share a single $GOROOT on a shared file system.
Fixes#2920.
R=golang-dev, r
CC=golang-dev
https://golang.org/cl/5645093
Also, echo cmd/dist during bootstrap build
Makes that phase look like all the others.
Fixes#2908.
R=golang-dev, alex.brainman, bradfitz
CC=golang-dev
https://golang.org/cl/5655065
The go- is redundant now that the directory is required
to be inside $GOROOT. Rob LGTMed the idea.
R=golang-dev, gri
CC=golang-dev
https://golang.org/cl/5618044
Consequently, remove many package Makefiles,
and shorten the few that remain.
gomake becomes 'go tool make'.
Turn off test phases of run.bash that do not work,
flagged with $BROKEN. Future CLs will restore these,
but this seemed like a big enough CL already.
R=golang-dev, r
CC=golang-dev
https://golang.org/cl/5601057
1) create go-tool dir in make.bash
2) clean up stale binaries in make.bash
3) add 'tool' command to go
4) convert goyacc->yacc as a first test tool
Since goyacc stands alone, it's a safe trial.
R=rsc
CC=golang-dev
https://golang.org/cl/5576061
Move error information into Package struct, so that
a package can be returned even if a dependency failed
to load or did not exist. This makes it possible to run
'go fix' or 'go fmt' on packages with broken dependencies
or missing imports. It also enables go get -fix.
The new go list -e flag lets go list process those package
errors as normal data.
Change p.Doc to be first sentence of package doc, not
entire package doc. Makes go list -json or
go list -f '{{.ImportPath}} {{.Doc}}' much more reasonable.
The go tool now depends on http, which means also
net and crypto/tls, both of which use cgo. Trying to
make the build scripts that build the go tool understand
and handle cgo is too much work. Instead, we build
a stripped down version of the go tool, compiled as go_bootstrap,
that substitutes an error stub for the usual HTTP code.
The buildscript builds go_bootstrap, go_bootstrap builds
the standard packages and commands, including the full
including-HTTP-support go tool, and then go_bootstrap
gets deleted.
Also handle the case where the buildscript needs updating
during all.bash: if it fails but a go command can be found on
the current $PATH, try to regenerate it. This gracefully
handles situations like adding a new file to a package
used by the go tool.
R=r, adg
CC=golang-dev
https://golang.org/cl/5553059
The -v flag prints the names of packages as they are built/installed.
Use -v in make.bash/run.bash to avoid a silent pause during
the build while Go code is being compiled.
R=golang-dev, r
CC=golang-dev
https://golang.org/cl/5532055
* work around a linker/cgo bug
* do not run deps.bash on Windows unless we need it
(cuts a full minute off the build time)
* add windows to the list of cgo-enabled targets
The gopack problem is issue 2601.
R=golang-dev, r, bradfitz
CC=golang-dev
https://golang.org/cl/5504062
* correct dependency calculations
* comment meaning of action fields
* new alias "std" like "all" but standard packages only
* add -o flag to 'go build'
* set up for parallel build (still serial)
* understand that import "C" depends on cgo, runtime/cgo
R=golang-dev, mikioh.mikioh
CC=golang-dev
https://golang.org/cl/5502055
If something goes wrong, it should suffice to set
USE_GO_TOOL=false in env.bash to fall back to the
makefiles. I will delete the makefiles in January.
R=golang-dev, r
CC=golang-dev
https://golang.org/cl/5502047
This is like the ill-fated CL 5493063 except that
I have written a shell script (autogen.sh) instead of
thinking I could possibly write a correct Makefile.
R=golang-dev, r
CC=golang-dev
https://golang.org/cl/5496075
That was the last build that was close to working.
I will try that change again next week.
Make is being very subtle today.
At the reverted-to CL, the ARM traceback appears
to be broken. I'll look into that next week too.
R=golang-dev, r
CC=golang-dev
https://golang.org/cl/5492063
Fedora 16 mounts selinux at /sys/fs/selinux, instead of the
traditional /selinux. Check both locations for the selinux
filesystem in make.bash
Fixes#2448.
R=golang-dev, rsc
CC=golang-dev
https://golang.org/cl/5373077
Apparently some versions of bash do the ||exit implicitly
when in set -e mode, but others do not. ???
R=gri
CC=golang-dev
https://golang.org/cl/5285043
On recent Debian systems the gold 2.20 check triggers though
Debian doesn't have version 2.20 but rather has:
GNU gold (GNU Binutils for Debian 2.21.52.20110606) 1.11
^^^^
R=rsc, iant
CC=golang-dev
https://golang.org/cl/5252055
Commands written in Go depend on Go packages, so they
cannot be built by src/cmd/make.bash. They have been
built by src/make.bash after all the packages are done, but
we want to be able to use cgo (written in Go) during the build
of package net. To make this possible, build the commands
from src/pkg/Makefile instead of src/make.bash, so that they
are included in the package dependency analysis.
R=r
CC=golang-dev
https://golang.org/cl/1972046
factor out environment variable checks.
infer $GOROOT etc during build if not set.
it's still necessary to set them for yourself
to use the standard Makefiles.
when running all.bash, don't recompile all the
go packages in run.bash, since make.bash already did.
R=r
CC=golang-dev
https://golang.org/cl/609042
This change removes the necessity to have GOBIN in $PATH,
and also doesn't assume that the build is being run from
$GOROOT/src. This is a minimal set of necessary changes
to get Go to build happily from the FreeBSD ports
collection.
R=rsc
CC=golang-dev
https://golang.org/cl/171044
before this change, if pkg/Make.deps is missing or broken, clean.bash fails and the build dies
but not until much later.
add freebsd to error message about valid values of $GOOS
TODO: would be nice if this process exited when an error occurred. subshells make it hard
R=rsc
CC=golang-dev
https://golang.org/cl/160065