diff options
author | Dylan Baker <dylan@pnwbakers.com> | 2021-06-01 21:45:21 -0700 |
---|---|---|
committer | Dylan Baker <dylan@pnwbakers.com> | 2021-06-15 12:48:53 -0700 |
commit | 0698a50c009e0fe43f7f217985b3660b42bce924 (patch) | |
tree | 63b6ac1b6a79a266bfe7ffd89afdd8f75ed0adb7 /mesonbuild | |
parent | c42262131706143e1a213d0bac659085822a0759 (diff) | |
download | meson-0698a50c009e0fe43f7f217985b3660b42bce924.zip meson-0698a50c009e0fe43f7f217985b3660b42bce924.tar.gz meson-0698a50c009e0fe43f7f217985b3660b42bce924.tar.bz2 |
build: cleanup Generator.proccess_files a bit
Diffstat (limited to 'mesonbuild')
-rw-r--r-- | mesonbuild/build.py | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/mesonbuild/build.py b/mesonbuild/build.py index e3a7bb5..a5e8af4 100644 --- a/mesonbuild/build.py +++ b/mesonbuild/build.py @@ -1549,20 +1549,20 @@ class Generator: preserve_path_from: T.Optional[str] = None, extra_args: T.Optional[T.List[str]] = None) -> 'GeneratedList': output = GeneratedList(self, state.subdir, preserve_path_from, extra_args=extra_args if extra_args is not None else []) - #XXX + for e in files: - fs = [e] if isinstance(e, CustomTarget): output.depends.add(e) if isinstance(e, CustomTargetIndex): output.depends.add(e.target) + if isinstance(e, (CustomTarget, CustomTargetIndex, GeneratedList)): self.depends.append(e) # BUG: this should go in the GeneratedList object, not this object. - fs = [] - for f in e.get_outputs(): - fs.append(File.from_built_file(state.subdir, f)) + fs = [File.from_built_file(state.subdir, f) for f in e.get_outputs()] elif isinstance(e, str): fs = [File.from_source_file(state.environment.source_dir, state.subdir, e)] + else: + fs = [e] for f in fs: if preserve_path_from: |