aboutsummaryrefslogtreecommitdiff
path: root/mesonbuild/build.py
diff options
context:
space:
mode:
authorGerion Entrup <gerion.entrup@flump.de>2024-03-11 11:21:56 +0100
committerDylan Baker <dylan@pnwbakers.com>2024-04-05 09:36:59 -0700
commit06bc8a8d37620506ec5d176577fdc9f6ae5f011b (patch)
tree35a4c860c6b33e2948a66fb0392f000d96301cc3 /mesonbuild/build.py
parent30c38e2bd69b2bab74b6e76da1c626f3c9853613 (diff)
downloadmeson-06bc8a8d37620506ec5d176577fdc9f6ae5f011b.zip
meson-06bc8a8d37620506ec5d176577fdc9f6ae5f011b.tar.gz
meson-06bc8a8d37620506ec5d176577fdc9f6ae5f011b.tar.bz2
depends keyword argument: accept CustomTargetIndex
That holds for all of these meson function: run_target, generator and custom_target and additionally to the Windows and Gnome module.
Diffstat (limited to 'mesonbuild/build.py')
-rw-r--r--mesonbuild/build.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/mesonbuild/build.py b/mesonbuild/build.py
index 2b6ce88..6f0d6a2 100644
--- a/mesonbuild/build.py
+++ b/mesonbuild/build.py
@@ -2815,11 +2815,11 @@ class RunTarget(Target, CommandBase):
def __init__(self, name: str,
command: T.Sequence[T.Union[str, File, BuildTargetTypes, programs.ExternalProgram]],
- dependencies: T.Sequence[Target],
+ dependencies: T.Sequence[T.Union[Target, CustomTargetIndex]],
subdir: str,
subproject: str,
environment: environment.Environment,
- env: T.Optional['EnvironmentVariables'] = None,
+ env: T.Optional[EnvironmentVariables] = None,
default_env: bool = True):
# These don't produce output artifacts
super().__init__(name, subdir, subproject, False, MachineChoice.BUILD, environment)
@@ -2834,10 +2834,10 @@ class RunTarget(Target, CommandBase):
repr_str = "<{0} {1}: {2}>"
return repr_str.format(self.__class__.__name__, self.get_id(), self.command[0])
- def get_dependencies(self) -> T.List[T.Union[BuildTarget, 'CustomTarget']]:
+ def get_dependencies(self) -> T.List[T.Union[BuildTarget, CustomTarget, CustomTargetIndex]]:
return self.dependencies
- def get_generated_sources(self) -> T.List['GeneratedTypes']:
+ def get_generated_sources(self) -> T.List[GeneratedTypes]:
return []
def get_sources(self) -> T.List[File]: