aboutsummaryrefslogtreecommitdiff
path: root/mesonbuild
diff options
context:
space:
mode:
authorXavier Claessens <xavier.claessens@collabora.com>2023-02-10 17:23:28 -0500
committerXavier Claessens <xclaesse@gmail.com>2023-02-15 15:12:34 -0500
commitd21b64487e30a6b9aa51e6db9f13dbb44e700788 (patch)
tree90f652fbd28548b412d74a26c0289238f29f1d42 /mesonbuild
parentc2a55bfe43fae1b44cf49a083297d6755c89e1cc (diff)
downloadmeson-d21b64487e30a6b9aa51e6db9f13dbb44e700788.zip
meson-d21b64487e30a6b9aa51e6db9f13dbb44e700788.tar.gz
meson-d21b64487e30a6b9aa51e6db9f13dbb44e700788.tar.bz2
preprocess: Add dependencies kwarg
Diffstat (limited to 'mesonbuild')
-rw-r--r--mesonbuild/interpreter/compiler.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/mesonbuild/interpreter/compiler.py b/mesonbuild/interpreter/compiler.py
index d27fc20..eab8607 100644
--- a/mesonbuild/interpreter/compiler.py
+++ b/mesonbuild/interpreter/compiler.py
@@ -87,6 +87,7 @@ if T.TYPE_CHECKING:
output: str
compile_args: T.List[str]
include_directories: T.List[build.IncludeDirs]
+ dependencies: T.List[dependencies.Dependency]
class _TestMode(enum.Enum):
@@ -760,6 +761,7 @@ class CompilerHolder(ObjectHolder['Compiler']):
KwargInfo('output', str, default='@PLAINNAME@.i'),
KwargInfo('compile_args', ContainerTypeInfo(list, str), listify=True, default=[]),
_INCLUDE_DIRS_KW,
+ _DEPENDENCIES_KW.evolve(since='1.1.0'),
)
def preprocess_method(self, args: T.Tuple[T.List['mesonlib.FileOrString']], kwargs: 'PreprocessKW') -> T.List[build.CustomTargetIndex]:
compiler = self.compiler.get_preprocessor()
@@ -771,6 +773,7 @@ class CompilerHolder(ObjectHolder['Compiler']):
f'{self.compiler.language}_args': kwargs['compile_args'],
'build_by_default': False,
'include_directories': kwargs['include_directories'],
+ 'dependencies': kwargs['dependencies'],
}
tg_name = f'preprocessor_{next(self.preprocess_uid)}'
tg = build.CompileTarget(