• Russ Cox's avatar
    cmd/go: make build -a skip standard packages in Go releases · 8c3005c4
    Russ Cox authored
    Today, 'go build -a my/pkg' and 'go install -a my/pkg'
    recompile not just my/pkg and all its dependencies that
    you wrote but also the standard library packages.
    Recompiling the standard library is problematic on
    some systems because the installed copy is not writable.
    
    The -a behavior means that you can't use 'go install -a all'
    or 'go install -a my/...' to rebuild everything after a Go
    release - the rebuild stops early when it cannot overwrite
    the installed standard library.
    
    During development work, however, you do want install -a
    to rebuild everything, because anything might have changed.
    
    Resolve the conflict by making the behavior of -a depend
    on whether we are using a released copy of Go or a devel copy.
    In the release copies, -a no longer applies to the standard library.
    In the devel copies, it still does.
    
    This is the latest in a long line of refinements to the
    "do I build this or not" logic. It is surely not the last.
    
    Fixes #8290.
    
    LGTM=r
    R=golang-codereviews, r, tracey.brendan
    CC=adg, golang-codereviews, iant
    https://golang.org/cl/151730045
    8c3005c4
Name
Last commit
Last update
api Loading commit data...
doc Loading commit data...
include Loading commit data...
lib Loading commit data...
misc Loading commit data...
src Loading commit data...
test Loading commit data...
.hgignore Loading commit data...
.hgtags Loading commit data...
AUTHORS Loading commit data...
CONTRIBUTORS Loading commit data...
LICENSE Loading commit data...
PATENTS Loading commit data...
README Loading commit data...
favicon.ico Loading commit data...
robots.txt Loading commit data...