}
// install installs the package named by path, which is needed by parent.
-func install(pkg, parent string) (built bool) {
+func install(pkg, parent string) {
// Make sure we're not already trying to install pkg.
switch visit[pkg] {
case done:
errorf("%s: package has no files\n", pkg)
return
}
- var depBuilt bool
for _, p := range dirInfo.Imports {
if p != "C" {
- if install(p, pkg) {
- depBuilt = true
- }
+ install(p, pkg)
}
}
if errors {
script.Clean()
}
if *doInstall {
- if depBuilt || script.Stale() {
+ if script.Stale() {
printf("%s: install\n", pkg)
if err := script.Run(); err != nil {
errorf("%s: install: %v\n", pkg, err)
return
}
- built = true
} else {
printf("%s: up-to-date\n", pkg)
}