diff options
author | Dylan Baker <dylan@pnwbakers.com> | 2021-08-10 14:36:54 -0700 |
---|---|---|
committer | Daniel Mensinger <daniel@mensinger-ka.de> | 2021-09-30 21:01:38 +0200 |
commit | 0a6fdd4900546f02fbecf6632892d00c28279dbf (patch) | |
tree | 90a06f3eff5cc895d60ea34fd0925fb5892718c6 /mesonbuild | |
parent | f9b14dc5702d171b2fa74f6aafa2e23c60625eff (diff) | |
download | meson-0a6fdd4900546f02fbecf6632892d00c28279dbf.zip meson-0a6fdd4900546f02fbecf6632892d00c28279dbf.tar.gz meson-0a6fdd4900546f02fbecf6632892d00c28279dbf.tar.bz2 |
build: Fully annotate RunTarget
Diffstat (limited to 'mesonbuild')
-rw-r--r-- | mesonbuild/build.py | 15 |
1 files changed, 10 insertions, 5 deletions
diff --git a/mesonbuild/build.py b/mesonbuild/build.py index 7f69f61..8a3ce8d 100644 --- a/mesonbuild/build.py +++ b/mesonbuild/build.py @@ -2536,8 +2536,13 @@ class CustomTarget(Target, CommandBase): return len(self.outputs) class RunTarget(Target, CommandBase): - def __init__(self, name: str, command, dependencies, - subdir: str, subproject: str, env: T.Optional['EnvironmentVariables'] = None): + + def __init__(self, name: str, + command: T.Sequence[T.Union[str, File, BuildTarget, 'CustomTarget', 'CustomTargetIndex', programs.ExternalProgram]], + dependencies: T.Sequence[T.Union[BuildTarget, 'CustomTarget']], + subdir: str, + subproject: str, + env: T.Optional['EnvironmentVariables'] = None): self.typename = 'run' # These don't produce output artifacts super().__init__(name, subdir, subproject, False, MachineChoice.BUILD) @@ -2554,13 +2559,13 @@ class RunTarget(Target, CommandBase): def process_kwargs(self, kwargs): return self.process_kwargs_base(kwargs) - def get_dependencies(self): + def get_dependencies(self) -> T.List[T.Union[BuildTarget, 'CustomTarget']]: return self.dependencies - def get_generated_sources(self): + def get_generated_sources(self) -> T.List['GeneratedTypes']: return [] - def get_sources(self): + def get_sources(self) -> T.List[File]: return [] def should_install(self) -> bool: |