|
|
|
@ -293,7 +293,8 @@ class QtBaseModule(ExtensionModule): |
|
|
|
|
Uses CustomTargets to generate .cpp files from .qrc files. |
|
|
|
|
""" |
|
|
|
|
if any(isinstance(s, (build.CustomTarget, build.CustomTargetIndex, build.GeneratedList)) for s in kwargs['sources']): |
|
|
|
|
FeatureNew.single_use('qt.compile_resources: custom_target or generator for "sources" keyword argument', '0.60.0', state.subproject) |
|
|
|
|
FeatureNew.single_use('qt.compile_resources: custom_target or generator for "sources" keyword argument', |
|
|
|
|
'0.60.0', state.subproject, location=state.current_node) |
|
|
|
|
out = self._compile_resources_impl(state, kwargs) |
|
|
|
|
return ModuleReturnValue(out, [out]) |
|
|
|
|
|
|
|
|
@ -372,7 +373,8 @@ class QtBaseModule(ExtensionModule): |
|
|
|
|
def compile_ui(self, state: 'ModuleState', args: T.Tuple, kwargs: 'UICompilerKwArgs') -> ModuleReturnValue: |
|
|
|
|
"""Compile UI resources into cpp headers.""" |
|
|
|
|
if any(isinstance(s, (build.CustomTarget, build.CustomTargetIndex, build.GeneratedList)) for s in kwargs['sources']): |
|
|
|
|
FeatureNew.single_use('qt.compile_ui: custom_target or generator for "sources" keyword argument', '0.60.0', state.subproject) |
|
|
|
|
FeatureNew.single_use('qt.compile_ui: custom_target or generator for "sources" keyword argument', |
|
|
|
|
'0.60.0', state.subproject, location=state.current_node) |
|
|
|
|
out = self._compile_ui_impl(state, kwargs) |
|
|
|
|
return ModuleReturnValue(out, [out]) |
|
|
|
|
|
|
|
|
@ -415,9 +417,11 @@ class QtBaseModule(ExtensionModule): |
|
|
|
|
) |
|
|
|
|
def compile_moc(self, state: 'ModuleState', args: T.Tuple, kwargs: 'MocCompilerKwArgs') -> ModuleReturnValue: |
|
|
|
|
if any(isinstance(s, (build.CustomTarget, build.CustomTargetIndex, build.GeneratedList)) for s in kwargs['headers']): |
|
|
|
|
FeatureNew.single_use('qt.compile_moc: custom_target or generator for "headers" keyword argument', '0.60.0', state.subproject) |
|
|
|
|
FeatureNew.single_use('qt.compile_moc: custom_target or generator for "headers" keyword argument', |
|
|
|
|
'0.60.0', state.subproject, location=state.current_node) |
|
|
|
|
if any(isinstance(s, (build.CustomTarget, build.CustomTargetIndex, build.GeneratedList)) for s in kwargs['sources']): |
|
|
|
|
FeatureNew.single_use('qt.compile_moc: custom_target or generator for "sources" keyword argument', '0.60.0', state.subproject) |
|
|
|
|
FeatureNew.single_use('qt.compile_moc: custom_target or generator for "sources" keyword argument', |
|
|
|
|
'0.60.0', state.subproject, location=state.current_node) |
|
|
|
|
out = self._compile_moc_impl(state, kwargs) |
|
|
|
|
return ModuleReturnValue(out, [out]) |
|
|
|
|
|
|
|
|
@ -476,7 +480,7 @@ class QtBaseModule(ExtensionModule): |
|
|
|
|
def preprocess(self, state: 'ModuleState', args: T.List[T.Union[str, File]], kwargs: 'PreprocessKwArgs') -> ModuleReturnValue: |
|
|
|
|
_sources = args[1:] |
|
|
|
|
if _sources: |
|
|
|
|
FeatureDeprecated.single_use('qt.preprocess positional sources', '0.59', state.subproject) |
|
|
|
|
FeatureDeprecated.single_use('qt.preprocess positional sources', '0.59', state.subproject, location=state.current_node) |
|
|
|
|
# List is invariant, os we have to cast... |
|
|
|
|
sources = T.cast(T.List[T.Union[str, File, build.GeneratedList, build.CustomTarget]], |
|
|
|
|
_sources + kwargs['sources']) |
|
|
|
@ -527,7 +531,8 @@ class QtBaseModule(ExtensionModule): |
|
|
|
|
def compile_translations(self, state: 'ModuleState', args: T.Tuple, kwargs: 'CompileTranslationsKwArgs') -> ModuleReturnValue: |
|
|
|
|
ts_files = kwargs['ts_files'] |
|
|
|
|
if any(isinstance(s, (build.CustomTarget, build.CustomTargetIndex, build.GeneratedList)) for s in ts_files): |
|
|
|
|
FeatureNew.single_use('qt.compile_translations: custom_target or generator for "ts_files" keyword argument', '0.60.0', state.subproject) |
|
|
|
|
FeatureNew.single_use('qt.compile_translations: custom_target or generator for "ts_files" keyword argument', |
|
|
|
|
'0.60.0', state.subproject, location=state.current_node) |
|
|
|
|
install_dir = kwargs['install_dir'] |
|
|
|
|
qresource = kwargs['qresource'] |
|
|
|
|
if qresource: |
|
|
|
|