Rerun globs when a dependency is missing
If you remove a folder that's part of a glob, soong will error out
currently. Instead treat it like an out-of-date dependency.
Bug: 364749114
Test: m nothing, rm glob folder, m nothing
Change-Id: I86ee755a0815b79192133223f8ef3ecd90669db1
diff --git a/ui/build/soong.go b/ui/build/soong.go
index 76a3e35..97bc997 100644
--- a/ui/build/soong.go
+++ b/ui/build/soong.go
@@ -759,7 +759,10 @@
hasNewDep := false
for _, dep := range cachedGlob.Deps {
info, err := os.Stat(dep)
- if err != nil {
+ if errors.Is(err, fs.ErrNotExist) {
+ hasNewDep = true
+ break
+ } else if err != nil {
errorsChan <- err
continue
}