diff options
author | Colin Cross <ccross@android.com> | 2016-04-27 13:45:26 -0700 |
---|---|---|
committer | Colin Cross <ccross@android.com> | 2016-04-27 13:45:26 -0700 |
commit | da727cf9919e17051f8e6683db5efd4b692c3153 (patch) | |
tree | 1b525a6b4d103a13b962ae964343122ec947a878 | |
parent | 737cb6566f0483dce12324a5bc0d254bfe15a1f4 (diff) | |
download | build_soong-da727cf9919e17051f8e6683db5efd4b692c3153.tar.gz build_soong-da727cf9919e17051f8e6683db5efd4b692c3153.tar.bz2 build_soong-da727cf9919e17051f8e6683db5efd4b692c3153.zip |
Support nested glob patterns
Globbing separately for path/to/lib and path/to/lib/test would result in
trying to use intermediates/path/to/lib as both a file list file for the
first glob and as a directory to store the file list file for the second
glob, causing ninja to exit with an mkdir "Not a directory" error.
Add ".glob" to the file list file name to avoid collisions.
Change-Id: I8b9de9133d7ef667088a2f13eb28652508f3a290
-rw-r--r-- | common/glob.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/common/glob.go b/common/glob.go index 96655cf8..5b03bc1b 100644 --- a/common/glob.go +++ b/common/glob.go @@ -73,7 +73,7 @@ type globContext interface { } func Glob(ctx globContext, outDir string, globPattern string, excludes []string) ([]string, error) { - fileListFile := filepath.Join(outDir, "glob", globToString(globPattern)) + fileListFile := filepath.Join(outDir, "glob", globToString(globPattern)+".glob") depFile := fileListFile + ".d" // Get a globbed file list, and write out fileListFile and depFile |