7 # Copyright (c) 2008-2017 knut st. osmundsen <bird-kBuild-spam-xviiv@anduin.net>
9 # This file is part of kBuild.
11 # kBuild is free software; you can redistribute it and/or modify
12 # it under the terms of the GNU General Public License as published by
13 # the Free Software Foundation; either version 2 of the License, or
14 # (at your option) any later version.
16 # kBuild is distributed in the hope that it will be useful,
17 # but WITHOUT ANY WARRANTY; without even the implied warranty of
18 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19 # GNU General Public License for more details.
21 # You should have received a copy of the GNU General Public License
22 # along with kBuild; if not, write to the Free Software
23 # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
26 # As a special exception you are granted permission to include this file, via
27 # the kmk include directive, as you wish without this in itself causing the
28 # resulting makefile, program or whatever to be covered by the GPL license.
29 # This exception does not however invalidate any other reasons why the makefile,
30 # program, whatever should not be covered the GPL.
36 $(error kBuild
: The qt3 unit was included twice
!)
41 if
!defined
(UNIT_qt4
) && !defined
(UNIT_qt5
)
42 # Add our target properties (same as qt4 & qt5).
43 PROPS_SINGLE
+= QTTOOL MOCTOOL UICTOOL LRCTOOL QT_TRANSLATIONS_INST QT_TRANSLATIONS_TEMPLATE QT_PREFIX
44 PROPS_ACCUMULATE_R
+= MOCDEFS MOCFLAGS UICFLAGS LRCFLAGS QT_TRANSLATIONS QT_MOCSRCS QT_MOCHDRS
47 PROPS_ACCUMULATE_R
+= QT_IMAGES
53 # This is implemented here rather than in sdks/QT3.kmk to enforce the global USES.
54 # It also makes things easier to develop, with fewer files I mean.
56 ## @todo the SDK might actually not be necessary as it turns out... For now it servers
57 # a purpose if the host differs from the target, in theory at least.
60 # SDK Specific Properties
61 # PATH_SDK_QT3 - the general location of the Qt3 SDK stuff.
62 # PATH_SDK_QT3_INC - the Qt3 include directory.
63 # PATH_SDK_QT3_LIB - the Qt3 library directory for KBUILD_TARGET.
64 # PATH_SDK_QT3_LIB.amd64 - the Qt3 library directory for AMD64.
65 # PATH_SDK_QT3_LIB.x86 - the Qt3 library directory for X86.
67 PATH_SDK_QT3
:= $(firstword $(rsort
$(wildcard $(KBUILD_DEVTOOLS_TRG
)/qt
/v3
*)))
68 ifeq ($(PATH_SDK_QT3
),)
69 # If target == host, try look for Qt in the various platform specific places.
70 ifeq ($(KBUILD_TARGET
),$(KBUILD_HOST
))
71 ifeq ($(KBUILD_TARGET
),darwin
)
73 else ifeq ($(KBUILD_TARGET
),os2
)
74 # No idea here yet... Check QTDIR perhaps, but for now users have toset PATH_SDK_QT3.
75 else ifeq ($(KBUILD_TARGET
),win
)
76 # No idea here yet... Check QTDIR perhaps, but for now users have toset PATH_SDK_QT3.
78 # The Unices. Includes and esp. libs are tricky, so override the PATH_SDK_QT3_LIB* stuff if it doesn't work.
79 # Try find the general location of the thing by looking for the qm2ts program, then try looking for
80 # the moc program in likely and unlikely places save /usr[/local]/bin to avoid mistaking it with Qt4.
81 PATH_SDK_QT3
:= $(patsubst %/bin
/qm2ts
,%,$(firstword $(wildcard \
82 /usr
/lib
/qt-3.3
/bin
/qm2ts \
83 /usr
/lib64
/qt-3.3
/bin
/qm2ts \
85 $(if
$(QTDIR
),$(QTDIR
)/bin
/qm2ts
) \
87 /usr
/local
/bin
/qm2ts \
88 /usr
/share
/qt3
/bin
/qm2ts \
90 ifeq ($(PATH_SDK_QT3
),) # Try with moc, but not in /usr/bin and /usr/local/bin.
91 PATH_SDK_QT3
:= $(patsubst %/bin
/moc
,%,$(firstword $(wildcard \
92 /usr
/lib
/qt-3.3
/bin
/moc \
93 /usr
/lib64
/qt-3.3
/bin
/moc \
95 /usr
/share
/qt3
/bin
/moc \
96 $(if
$(QTDIR
),$(QTDIR
)/bin
/moc
) \
99 ifneq ($(PATH_SDK_QT3
),)
100 # Found something! Export the variable for the benefit of recursive make instances.
103 # Determin the include directory.
104 ifeq ($(PATH_SDK_QT3_INC
),)
105 PATH_SDK_QT3_INC
:= $(patsubst %/private
/qfiledefs_p.h
,%,$(firstword $(wildcard \
106 $(PATH_SDK_QT3
)/include/private
/qfiledefs_p.h \
107 $(PATH_SDK_QT3
)/include/qt3
/private
/qfiledefs_p.h \
108 /usr
/include/qt3
/private
/qfiledefs_p.h
)))
109 ifneq ($(PATH_SDK_QT3_INC
),)
110 export PATH_SDK_QT3_INC
114 # Determin the most likely x86 and AMD64 lib directories (only used for making PATH_SDK_QT3_LIB).
115 ifeq ($(PATH_SDK_QT3_LIB.x86
),)
116 PATH_SDK_QT3_LIB.x86
:= $(patsubst %/libqt-mt
$(SUFF_DLL
),%,$(firstword $(wildcard \
117 $(PATH_SDK_QT3
)/lib32
/libqt-mt
$(SUFF_DLL
) \
118 $(PATH_SDK_QT3
)/lib32
/qt3
/libqt-mt
$(SUFF_DLL
) \
119 $(PATH_SDK_QT3
)/lib32
/qt3-3
/lib
/libqt-mt
$(SUFF_DLL
) \
120 /usr
/lib32
/libqt-mt
$(SUFF_DLL
) \
121 /usr
/lib32
/qt3
/libqt-mt
$(SUFF_DLL
) \
122 /usr
/lib
/i386-linux-gnu
/libqt-mt
$(SUFF_DLL
) \
123 /usr
/local
/lib32
/libqt-mt
$(SUFF_DLL
) \
124 /usr
/local
/lib32
/qt3
/libqt-mt
$(SUFF_DLL
) \
125 /usr
/local
/lib32
/qt3-3
/lib
/libqt-mt
$(SUFF_DLL
) \
126 /usr
/local
/lib
/i386-linux-gnu
/libqt-mt
$(SUFF_DLL
) \
127 $(PATH_SDK_QT3
)/lib
/libqt-mt
$(SUFF_DLL
) \
128 $(PATH_SDK_QT3
)/lib
/qt3
/libqt-mt
$(SUFF_DLL
) \
129 $(PATH_SDK_QT3
)/lib
/qt3-3
/lib
/libqt-mt
$(SUFF_DLL
) \
130 $(PATH_SDK_QT3
)/lib
/i386-linux-gnu
/libqt-mt
$(SUFF_DLL
) \
132 ifneq ($(PATH_SDK_QT3_LIB.x86
),)
133 export PATH_SDK_QT3_LIB.x86
136 ifeq ($(PATH_SDK_QT3_LIB.amd64
),)
137 PATH_SDK_QT3_LIB.amd64
:= $(patsubst %/libqt-mt
$(SUFF_DLL
),%,$(firstword $(wildcard \
138 $(PATH_SDK_QT3
)/lib64
/libqt-mt
$(SUFF_DLL
) \
139 $(PATH_SDK_QT3
)/lib64
/qt3
/libqt-mt
$(SUFF_DLL
) \
140 $(PATH_SDK_QT3
)/lib64
/qt3-3
/lib
/libqt-mt
$(SUFF_DLL
) \
141 $(PATH_SDK_QT3
)/lib
/amd64
/libqt-mt
$(SUFF_DLL
) \
142 $(PATH_SDK_QT3
)/lib
/64/libqt-mt
$(SUFF_DLL
) \
143 /usr
/lib64
/libqt-mt
$(SUFF_DLL
) \
144 /usr
/lib64
/qt3
/libqt-mt
$(SUFF_DLL
) \
145 /usr
/lib64
/qt3-3
/lib
/libqt-mt
$(SUFF_DLL
) \
146 /usr
/lib
/amd64
/libqt-mt
$(SUFF_DLL
) \
147 /usr
/lib
/64/libqt-mt
$(SUFF_DLL
) \
148 /usr
/lib
/x86_64-linux-gnu
/libqt-mt
$(SUFF_DLL
) \
149 /usr
/local
/lib64
/libqt-mt
$(SUFF_DLL
) \
150 /usr
/local
/lib64
/qt3
/libqt-mt
$(SUFF_DLL
) \
151 /usr
/local
/lib64
/qt3-3
/lib
/libqt-mt
$(SUFF_DLL
) \
152 /usr
/local
/lib
/amd64
/libqt-mt
$(SUFF_DLL
) \
153 /usr
/local
/lib
/64/libqt-mt
$(SUFF_DLL
) \
154 /usr
/local
/lib
/x86_64-linux-gnu
/libqt-mt
$(SUFF_DLL
) \
155 $(PATH_SDK_QT3
)/lib
/libqt-mt
$(SUFF_DLL
) \
156 $(PATH_SDK_QT3
)/lib
/qt3
/libqt-mt
$(SUFF_DLL
) \
157 $(PATH_SDK_QT3
)/lib
/qt3-3
/lib
/libqt-mt
$(SUFF_DLL
) \
158 $(PATH_SDK_QT3
)/lib
/x86_64-linux-gnu
/libqt-mt
$(SUFF_DLL
) \
160 ifneq ($(PATH_SDK_QT3_LIB.amd64
),)
161 export PATH_SDK_QT3_LIB.amd64
165 # Determin the KBUILD_TARGET lib directory.
166 ifeq ($(PATH_SDK_QT3_LIB
),)
167 PATH_SDK_QT3_LIB
:= $(PATH_SDK_QT3_LIB.
$(KBUILD_TARGET_ARCH
))
168 ifeq ($(PATH_SDK_QT3_LIB
),)
169 PATH_SDK_QT3_LIB
:= $(patsubst %/libqt-mt
$(SUFF_DLL
),%,$(firstword $(wildcard \
170 $(PATH_SDK_QT3
)/lib
/libqt-mt
$(SUFF_DLL
) \
171 $(PATH_SDK_QT3
)/lib
/qt3
/libqt-mt
$(SUFF_DLL
) \
172 $(PATH_SDK_QT3
)/lib
/qt3-3
/lib
/libqt-mt
$(SUFF_DLL
) \
173 /usr
/lib
/libqt-mt
$(SUFF_DLL
) \
174 /usr
/lib
/qt3
/libqt-mt
$(SUFF_DLL
) \
175 /usr
/lib
/qt3-3
/lib
/libqt-mt
$(SUFF_DLL
) \
176 /usr
/local
/lib
/libqt-mt
$(SUFF_DLL
) \
177 /usr
/local
/lib
/qt3
/libqt-mt
$(SUFF_DLL
) \
178 /usr
/local
/lib
/qt3-3
/lib
/libqt-mt
$(SUFF_DLL
) \
180 ifneq ($(PATH_SDK_QT3_LIB
),)
181 export PATH_SDK_QT3_LIB
190 ifeq ($(PATH_SDK_QT3
),)
191 $(warning kBuild
: Couldn
't find the Qt3 headers and libaries...)
192 PATH_SDK_QT3 := $(KBUILD_DEVTOOLS_TRG)/qt/not-found
196 # Resolve any fancy stuff once and for all.
197 PATH_SDK_QT3 := $(PATH_SDK_QT3)
200 # Libraries can be in either Frameworks or lib depending on how you
201 # build it on the mac. The .dmg installs into Frameworks but builds into lib.
202 PATH_SDK_QT3_LIB ?= $(PATH_SDK_QT3)/lib
203 PATH_SDK_QT3_INC ?= $(PATH_SDK_QT3)/include
205 # The bits that kBuild picks up.
212 # This is implemented here rather than in tools/QT3.kmk to enforce the global USES.
213 # It also makes things easier to develop, with fewer files I mean.
217 # Tool Specific Properties (PATH_TOOL_QT3_BIN and TOOL_QT3_BIN_SUFF)
218 # TOOL_QT3_BIN_SUFF - the '-qt3
' bit found on debian.
219 # PATH_TOOL_QT3_BIN - the directory containing moc, uic, lrelease, lupdate and qm2ts.
220 ifndef PATH_TOOL_QT3_BIN
221 PATH_TOOL_QT3_BIN := $(firstword $(rsort $(wildcard $(KBUILD_DEVTOOLS_BLD)/qt/v3*/bin)))
222 ifeq ($(PATH_TOOL_QT3_BIN),)
223 if1of ($(KBUILD_HOST), win os2)
224 # Sorry, no joy here. Check QTDIR perhaps, but for now users have to set PATH_TOOL_QT3_BIN.
226 ifdef TOOL_QT3_BIN_SUFF
227 TOOL_QT3_BIN_SUFF := $(TOOL_QT3_BIN_SUFF)
229 PATH_TOOL_QT3_BIN := $(patsubst %/qm2ts$(TOOL_QT3_BIN_SUFF),%,$(firstword $(wildcard \
230 /usr/lib/qt-3.3/bin/qm2ts$(TOOL_QT3_BIN_SUFF) \
231 /usr/lib64/qt-3.3/bin/qm2ts$(TOOL_QT3_BIN_SUFF) \
232 /usr/qt/3/bin/qm2ts$(TOOL_QT3_BIN_SUFF) \
233 $(if $(QTDIR),$(QTDIR)/bin/qm2ts$(TOOL_QT3_BIN_SUFF)) \
234 /usr/bin/qm2ts$(TOOL_QT3_BIN_SUFF) \
235 /usr/local/bin/qm2ts$(TOOL_QT3_BIN_SUFF) \
236 /usr/share/qt3/bin/qm2ts$(TOOL_QT3_BIN_SUFF) \
238 ifeq ($(PATH_TOOL_QT3_BIN),)
239 # If we couldn't find the qt3 specific tool qm2ts
, debian and other skip
240 # this (thanks a bundle). Try with look for 'moc' with a '-qt3' extension,
241 # then for just moc. In the latter case don't search /usr[/local]/bin to
242 # void finding the qt4 tools and messing up.
243 ifeq ($(TOOL_QT3_BIN_SUFF
),)
244 PATH_TOOL_QT3_BIN
:= $(patsubst %/moc-qt3
,%,$(firstword $(wildcard \
246 /usr
/local
/bin
/moc-qt3 \
247 /usr
/lib
/qt-3.3
/bin
/moc-qt3 \
248 /usr
/lib64
/qt-3.3
/bin
/moc-qt3 \
249 /usr
/qt
/3/bin
/moc-qt3 \
250 /usr
/share
/qt3
/bin
/moc-qt3 \
251 $(if
$(QTDIR
),$(QTDIR
)/bin
/moc-qt3
) \
254 ifneq ($(PATH_TOOL_QT3_BIN
),)
255 export TOOL_QT3_BIN_SUFF
:= -qt3
257 PATH_TOOL_QT3_BIN
:= $(patsubst %/moc
$(TOOL_QT3_BIN_SUFF
),%,$(firstword $(wildcard \
258 /usr
/lib
/qt-3.3
/bin
/moc
$(TOOL_QT3_BIN_SUFF
) \
259 /usr
/lib64
/qt-3.3
/bin
/moc
$(TOOL_QT3_BIN_SUFF
) \
260 /usr
/qt
/3/bin
/moc
$(TOOL_QT3_BIN_SUFF
) \
261 /usr
/share
/qt3
/bin
/moc
$(TOOL_QT3_BIN_SUFF
) \
262 $(if
$(QTDIR
),$(QTDIR
)/bin
/moc
$(TOOL_QT3_BIN_SUFF
)) \
266 ifneq ($(PATH_TOOL_QT3_BIN
),)
267 export PATH_TOOL_QT3_BIN
271 # If not found, we'll enter the 'pathless' mode.
273 # Resolve any fancy stuff once and for all.
274 PATH_TOOL_QT3_BIN
:= $(PATH_TOOL_QT3_BIN
)
275 TOOL_QT3_BIN_SUFF
:= $(TOOL_QT3_BIN_SUFF
)
277 ifneq ($(PATH_TOOL_QT3_BIN
),)
278 ifeq ($(KBUILD_HOST
),os2
)
279 TOOL_QT3_ENV_SETUP ?
= $(REDIRECT
) -E
'BEGINLIBPATH=$(PATH_TOOL_QT3_BIN);$(libpath BEGINLIBPATH)' --
281 TOOL_QT3_MOC ?
= $(TOOL_QT3_ENV_SETUP
) $(PATH_TOOL_QT3_BIN
)/moc
$(TOOL_QT3_BIN_SUFF
)$(HOST_SUFF_EXE
)
282 TOOL_QT3_UIC ?
= $(TOOL_QT3_ENV_SETUP
) $(PATH_TOOL_QT3_BIN
)/uic
$(TOOL_QT3_BIN_SUFF
)$(HOST_SUFF_EXE
)
283 TOOL_QT3_LRC ?
= $(TOOL_QT3_ENV_SETUP
) $(PATH_TOOL_QT3_BIN
)/lrelease
$(TOOL_QT3_BIN_SUFF
)$(HOST_SUFF_EXE
)
284 TOOL_QT3_LUPDATE ?
= $(TOOL_QT3_ENV_SETUP
) $(PATH_TOOL_QT3_BIN
)/lupdate
$(TOOL_QT3_BIN_SUFF
)$(HOST_SUFF_EXE
)
286 # Pathless, relies on the environment.
287 TOOL_QT3_MOC ?
= moc
$(TOOL_QT3_BIN_SUFF
)$(HOST_SUFF_EXE
)
288 TOOL_QT3_UIC ?
= uic
$(TOOL_QT3_BIN_SUFF
)$(HOST_SUFF_EXE
)
289 TOOL_QT3_LRC ?
= lrelease
$(TOOL_QT3_BIN_SUFF
)$(HOST_SUFF_EXE
)
290 TOOL_QT3_LUPDATE ?
= lupdate
$(TOOL_QT3_BIN_SUFF
)$(HOST_SUFF_EXE
)
293 # General Properties used by kBuild and/or units/qt.kmk
299 ## MOC a C++ source file.
300 # @param $(target) Normalized main target name.
301 # @param $(source) Source filename (relative).
302 # @param $(out) Object file name. This shall be (re)created by the compilation.
303 # @param $(dep) Dependcy file. This may be (re)created by the compilation.
304 # @param $(flags) Flags.
305 # @param $(outbase) Output basename (full). Use this for list files and such.
307 TOOL_QT3_MOC_CPP_DEPEND
=
308 TOOL_QT3_MOC_CPP_DEPORD
=
309 TOOL_QT3_MOC_CPP_OUTPUT
=
310 TOOL_QT3_MOC_CPP_OUTPUT_MAYBE
=
311 define TOOL_QT3_MOC_CPP_CMDS
312 $(QUIET
)$(TOOL_QT3_MOC
)\
319 ## MOC a C++ header file.
320 # @param $(target) Normalized main target name.
321 # @param $(source) Source filename (relative).
322 # @param $(out) Object file name. This shall be (re)created by the compilation.
323 # @param $(dep) Dependcy file. This may be (re)created by the compilation.
324 # @param $(flags) Flags.
325 # @param $(outbase) Output basename (full). Use this for list files and such.
327 TOOL_QT3_MOC_HPP_DEPEND
=
328 TOOL_QT3_MOC_HPP_DEPORD
=
329 TOOL_QT3_MOC_HPP_OUTPUT
=
330 TOOL_QT3_MOC_HPP_OUTPUT_MAYBE
=
331 define TOOL_QT3_MOC_HPP_CMDS
332 $(QUIET
)$(TOOL_QT3_MOC
)\
338 ## Compile a Qt user interface file (.ui).
339 # @param $(target) Normalized main target name.
340 # @param $(source) Source filename (relative).
341 # @param $(out.cpp) The C++ source file to be generated.
342 # @param $(out.h) The C++ header file to be generated.
343 # @param $(dep) Dependcy file. This may be (re)created by the compilation.
344 # @param $(flags) Flags.
345 # @param $(outbase) Output basename (full). Use this for list files and such.
347 TOOL_QT3_UIC_UI_DEPEND
=
348 TOOL_QT3_UIC_UI_DEPORD
=
349 TOOL_QT3_UIC_UI_OUTPUT
=
350 TOOL_QT3_UIC_UI_OUTPUT_MAYBE
=
351 define TOOL_QT3_UIC_UI_CMDS
352 $(QUIET
)$(TOOL_QT3_UIC
)\
356 $(QUIET
)$(TOOL_QT3_UIC
)\
363 ## Compile a Qt translation file (.ts).
364 # @param $(target) Normalized main target name.
365 # @param $(source) Source filename (relative).
366 # @param $(out) Object file name. This shall be (re)created by the compilation.
367 # @param $(dep) Dependcy file. This may be (re)created by the compilation.
368 # @param $(flags) Flags.
369 # @param $(defs) Definitions.
370 # @param $(incs) Includes.
371 # @param $(outbase) Output basename (full). Use this for list files and such.
373 TOOL_QT3_LRC_TS_DEPEND
=
374 TOOL_QT3_LRC_TS_DEPORD
=
375 TOOL_QT3_LRC_TS_OUTPUT
=
376 TOOL_QT3_LRC_TS_OUTPUT_MAYBE
=
377 define TOOL_QT3_LRC_TS_CMDS
378 $(QUIET
)$(TOOL_QT3_LRC
)\
388 # Back to the Qt3 unit.
393 ## wrapper for the lrelease (LRC) command dependencies.
394 ifndef NO_COMPILE_CMDS_DEPS
395 _UNIT_QT3_LRC_CMDS_DEP
= $$(comp-cmds-ex
$$($(target
)_
$(subst :,_
,$(source
))_QT3_LRC_CMDS_PREV_
),$$(commands
$(out
)),FORCE
)
397 _UNIT_QT3_LRC_CMDS_DEP
=
401 # def_unit_qt3_target_pre_handle_translation helper that is expanded before evaluation.
403 # This is necessary to resolve reference to local variables before doing
404 # assignments and setting up commands. They would otherwise be resolved
405 # later in a different context and the result would be completely wrong.
407 define def_unit_qt3_target_pre_handle_translation_dx
409 $(out
) + $(more_output
) +|
$(maybe_output
): \
411 $(value _UNIT_QT3_LRC_CMDS_DEP
) \
414 %$$(call MSG_TOOL
,lrelease
,$(target
),$(source
),$$@
)
415 $(QUIET2
)$(RM
) -f
$(out
) $(more_output
) $(maybe_output
) $(dep
)
419 ifndef NO_COMPILE_CMDS_DEPS
420 %$$(QUIET2
)$$(APPEND
) '$(dep)'
421 %$$(QUIET2
)$$(APPEND
) '$(dep)' 'define $(target)_$(subst :,_,$(source))_QT3_LRC_CMDS_PREV_'
422 %$$(QUIET2
)$$(APPEND
) -c
'$(dep)' '$(out)'
423 %$$(QUIET2
)$$(APPEND
) '$(dep)' 'endef'
426 $(target
)_CLEAN
+= $(out
) $(more_output
) $(maybe_output
) $(dep
)
427 $(target
)-inst-nls_SOURCES
+= $(out
)
429 endef # def_unit_qt3_target_pre_handle_translation_dx
432 # Handle a source file listed in QT_TRANSLATIONS.
434 # The files listed in QT_TRANSLATIONS are translation files (.ts) which needs
435 # to be translated into .qm files that are loadble by Qt.
437 # @remarks Invoked via $(evalvalctx ).
438 define def_unit_qt3_target_pre_handle_translation
441 # fetch the properties.
442 local tool
:= $(kb-src-tool dummy_var
)
443 local qtnlsdir
:= $($(target
)_0_OUTDIR
)/qtnls
444 local outbase
:= $(qtnlsdir
)/$(notdir $(basename $(source
)))
445 local out
:= $(outbase
).qm
446 local dep
:= $(out
).dep
447 local flags
:= $(kb-src-prop FLAGS
,dummy_var
,right-to-left
)
448 local deps
:= $(kb-src-prop DEPS
,dummy_var
,left-to-right
)
449 local orderdeps
:= $(call DIRDEP
,$(dir $(outbase
))) $(kb-src-prop ORDERDEPS
,dummy_var
,left-to-right
)
451 # default path + source dep.
453 local source
:= $(abspathex
$(source
),$(defpath
))
454 local deps
:= $(abspathex
$(deps
),$(defpath
)) $(source
)
455 local incs
:= $(abspathex
$(incs
),$(defpath
))
457 local deps
+= $(source
)
461 ifndef TOOL_
$(tool
)_LRC_TS_CMDS
462 $(error kBuild
: qt lrelease tool not found
: TOOL_
$(tool
)_LRC_TS_CMDS
)
464 local cmds
:= $(TOOL_
$(tool
)_LRC_TS_CMDS
)
465 local more_output
:= $(TOOL_
$(tool
)_LRC_TS_OUTPUT
)
466 local maybe_output
:= $(TOOL_
$(tool
)_LRC_TS_OUTPUT_MAYBE
)
467 local deps
+= $(TOOL_
$(tool
)_LRC_TS_DEPEND
)
468 local orderdeps
+= $(TOOL_
$(tool
)_LRC_TS_DEPORD
)
470 # generate the link rule and update some source and target variables.
471 ifndef NO_COMPILE_CMDS_DEPS
472 $(eval includedep
$(dep
))
474 $(eval
$(def_unit_qt3_target_pre_handle_translation_dx
))
476 endef # def_unit_qt3_target_pre_handle_translation
480 ## wrapper for the UIC command dependencies.
481 ifndef NO_COMPILE_CMDS_DEPS
482 _UNIT_QT3_UIC_CMDS_DEP
= $$(comp-cmds-ex
$$($(target
)_
$(subst :,_
,$(source
))_QT3_UIC_CMDS_PREV_
),$$(commands
$(out.h
)),FORCE
)
484 _UNIT_QT3_UIC_CMDS_DEP
=
488 # def_unit_qt3_src_handler_ui helper that is expanded before evaluation.
490 # This is necessary to resolve reference to local variables before doing
491 # assignments and setting up commands. They would otherwise be resolved
492 # later in a different context and the result would be completely wrong.
494 define def_unit_qt3_target_pre_handle_ui_dx
496 $(out.h
) + $(out.
cpp) +|
$(realout.h
) $(realout.
cpp) $(more_output
) $(maybe_output
): \
498 $(value _UNIT_QT3_UIC_CMDS_DEP
) \
501 %$$(call MSG_TOOL
,uic
,$(target
),$(source
),$(out.h
) $(out.
cpp))
502 $(QUIET2
)$(RM
) -f
$(out.h
) $(out.
cpp) $(more_output
) $(maybe_output
) $(dep
)
506 $(QUIET
)$(CP
) --changed
-f
$(out.h
) $(realout.h
)
507 $(QUIET
)$(CP
) --changed
-f
$(out.
cpp) $(realout.
cpp)
508 ifndef NO_COMPILE_CMDS_DEPS
509 %$$(QUIET2
)$$(APPEND
) '$(dep)'
510 %$$(QUIET2
)$$(APPEND
) '$(dep)' 'define $(target)_$(subst :,_,$(source))_QT3_UIC_CMDS_PREV_'
511 %$$(QUIET2
)$$(APPEND
) -c
'$(dep)' '$(out.h)'
512 %$$(QUIET2
)$$(APPEND
) '$(dep)' 'endef'
515 $(target
)_2_INTERMEDIATES
+= $(realout.h
)
516 $(target
)_GEN_SOURCES_
+= $(realout.
cpp)
517 $(target
)_CLEAN
+= $(out.h
) $(out.
cpp) $(realout.h
) $(realout.
cpp) $(more_output
) $(maybe_output
) $(dep
)
519 endef # def_unit_qt3_target_pre_handle_ui_dx
522 # Source handler for .ui sources.
524 # @remarks $(evalvalctx me).
525 define def_unit_qt3_src_handler_ui
528 # fetch the properties.
529 local tool
:= $(kb-src-tool dummy_var
)
530 local qtuicdir
:= $($(target
)_0_OUTDIR
)/qtuic
531 local outbase
:= $(qtuicdir
)/$(notdir $(basename $(source
)))
532 local out.h
:= $(outbase
).tmp.h
533 local out.
cpp := $(outbase
).tmp.
cpp
534 local realout.h
:= $(outbase
).h
535 local realout.
cpp:=$(outbase
).
cpp
536 local dep
:= $(realout.h
).dep
537 local flags
:= $(kb-src-prop FLAGS
,dummy_var
,right-to-left
)
538 local deps
:= $(kb-src-prop DEPS
,dummy_var
,left-to-right
)
539 local orderdeps
:= $(call DIRDEP
,$(dir $(outbase
))) $(kb-src-prop ORDERDEPS
,dummy_var
,left-to-right
)
541 # default path + source dep.
543 local source
:= $(abspathex
$(source
),$(defpath
))
544 local deps
:= $(abspathex
$(deps
),$(defpath
)) $(source
)
545 local incs
:= $(abspathex
$(incs
),$(defpath
))
547 local deps
+= $(source
)
551 ifndef TOOL_
$(tool
)_UIC_UI_CMDS
552 $(error kBuild
: qt uic tool not found
: TOOL_
$(tool
)_UIC_UI_CMDS
)
554 local cmds
:= $(TOOL_
$(tool
)_UIC_UI_CMDS
)
555 local more_output
:= $(TOOL_
$(tool
)_UIC_UI_OUTPUT
)
556 local maybe_output
:= $(TOOL_
$(tool
)_UIC_UI_OUTPUT_MAYBE
)
557 local deps
+= $(TOOL_
$(tool
)_UIC_UI_DEPEND
)
558 local orderdeps
+= $(TOOL_
$(tool
)_UIC_UI_DEPORD
)
560 # generate the link rule and update some source and target variables.
561 ifndef NO_COMPILE_CMDS_DEPS
562 $(eval includedep
$(dep
))
564 $(eval
$(def_unit_qt3_target_pre_handle_ui_dx
))
566 endef # def_unit_qt3_src_handler_ui
570 ## wrapper for the MOC command dependencies.
571 ifndef NO_COMPILE_CMDS_DEPS
572 _UNIT_QT3_MOC_HPP_CMDS_DEP
= $$(comp-cmds-ex
$$($(target
)_
$(subst :,_
,$(source
))_QT3_MOC_HPP_CMDS_PREV_
),$$(commands
$(out
)),FORCE
)
574 _UNIT_QT3_MOC_HPP_CMDS_DEP
=
578 # def_unit_qt3_target_pre_handle_moc_hdr helper that is expanded before evaluation.
580 # This is necessary to resolve reference to local variables before doing
581 # assignments and setting up commands. They would otherwise be resolved
582 # later in a different context and the result would be completely wrong.
584 define def_unit_qt3_target_pre_handle_moc_hdr_dx
586 $(out
) +|
$(realout
) $(more_output
) $(maybe_output
): \
588 $(value _UNIT_QT3_MOC_HPP_CMDS_DEP
) \
591 %$$(call MSG_TOOL
,moc
,$(target
),$(source
),$(realout
))
592 $(QUIET2
)$(RM
) -f
$(out
) $(more_output
) $(maybe_output
) $(dep
)
596 $(QUIET
)$(CP
) --changed
-f
$(out
) $(realout
)
597 ifndef NO_COMPILE_CMDS_DEPS
598 %$$(QUIET2
)$$(APPEND
) '$(dep)'
599 %$$(QUIET2
)$$(APPEND
) '$(dep)' 'define $(target)_$(subst :,_,$(source))_QT3_MOC_HPP_CMDS_PREV_'
600 %$$(QUIET2
)$$(APPEND
) -c
'$(dep)' '$(out)'
601 %$$(QUIET2
)$$(APPEND
) '$(dep)' 'endef'
604 $(target
)_2_INTERMEDIATES
+= $(realout
)
605 $(target
)_GEN_SOURCES_
+= $(realout
)
606 $(target
)_CLEAN
+= $(out
) $(realout
) $(more_output
) $(maybe_output
) $(dep
)
611 # Handle a source file listed in QT_MOCHDRS.
613 # The files listed in QT_MOCHDRS uses the Q_OBJECT macro and we will
614 # generate a .cpp file for each of them and add it to the generated
615 # sources so that it's compiled and linked. (There is an alternative
616 # way to do this where the .cpp file is included, this isn't currently
617 # supported by this unit.)
619 # @remarks Invoked via $(evalvalctx ).
620 define def_unit_qt3_target_pre_handle_moc_hdr
623 # fetch the properties.
624 local tool
:= $(kb-src-tool dummy_var
)
625 local outbase
:= $(qtmocdir
)/$(notdir $(basename $(source
)))
626 local out
:= $(outbase
).tmp.
cpp
627 local realout
:= $(outbase
).
cpp
628 local dep
:= $(realout
).dep
629 local flags
:= $(kb-src-prop FLAGS
,dummy_var
,right-to-left
)
630 local deps
:= $(kb-src-prop DEPS
,dummy_var
,left-to-right
)
631 local orderdeps
:= $(call DIRDEP
,$(dir $(outbase
))) $(kb-src-prop ORDERDEPS
,dummy_var
,left-to-right
)
633 # default path + source dep.
635 local source
:= $(abspathex
$(source
),$(defpath
))
636 local deps
:= $(abspathex
$(deps
),$(defpath
)) $(source
)
638 local deps
+= $(source
)
642 ifndef TOOL_
$(tool
)_MOC_HPP_CMDS
643 $(error kBuild
: qt moc tool not found
: TOOL_
$(tool
)_MOC_HPP_CMDS
)
645 local cmds
:= $(TOOL_
$(tool
)_MOC_HPP_CMDS
)
646 local more_output
:= $(TOOL_
$(tool
)_MOC_HPP_OUTPUT
)
647 local maybe_output
:= $(TOOL_
$(tool
)_MOC_HPP_OUTPUT_MAYBE
)
648 local deps
+= $(TOOL_
$(tool
)_MOC_HPP_DEPEND
)
649 local orderdeps
+= $(TOOL_
$(tool
)_MOC_HPP_DEPORD
)
651 # generate the link rule and update some source and target variables.
652 ifndef NO_COMPILE_CMDS_DEPS
653 $(eval includedep
$(dep
))
655 $(eval
$(def_unit_qt3_target_pre_handle_moc_hdr_dx
))
657 endef # def_unit_qt3_target_pre_handle_moc_hdr
661 ## wrapper for the MOC command dependencies.
662 ifndef NO_COMPILE_CMDS_DEPS
663 _UNIT_QT3_MOC_CPP_CMDS_DEP
= $$(comp-cmds-ex
$$($(target
)_
$(subst :,_
,$(source
))_QT3_MOC_CPP_CMDS_PREV_
),$$(commands
$(out
)),FORCE
)
665 _UNIT_QT3_MOC_CPP_CMDS_DEP
=
669 # def_unit_qt3_target_pre_handle_moc_src helper that is expanded before evaluation.
671 # This is necessary to resolve reference to local variables before doing
672 # assignments and setting up commands. They would otherwise be resolved
673 # later in a different context and the result would be completely wrong.
675 define def_unit_qt3_target_pre_handle_moc_src_dx
677 $(out
) +|
$(realout
) $(more_output
) $(maybe_output
): \
679 $(value _UNIT_QT3_MOC_CPP_CMDS_DEP
) \
682 %$$(call MSG_TOOL
,moc
,$(target
),$(source
),$(realout
))
683 $(QUIET2
)$(RM
) -f
$(out
) $(more_output
) $(maybe_output
) $(dep
)
687 $(QUIET
)$(CP
) --changed
-f
$(out
) $(realout
)
688 ifndef NO_COMPILE_CMDS_DEPS
689 %$$(QUIET2
)$$(APPEND
) '$(dep)'
690 %$$(QUIET2
)$$(APPEND
) '$(dep)' 'define $(target)_$(subst :,_,$(source))_QT3_MOC_CPP_CMDS_PREV_'
691 %$$(QUIET2
)$$(APPEND
) -c
'$(dep)' '$(out)'
692 %$$(QUIET2
)$$(APPEND
) '$(dep)' 'endef'
695 $(target
)_2_INTERMEDIATES
+= $(realout
)
696 $(target
)_CLEAN
+= $(out
) $(realout
) $(more_output
) $(maybe_output
) $(dep
)
701 # Handle a source file listed in QT_MOCSRCS.
703 # The files listed in QT_MOCSRCS uses the Q_OBJECT macro and will include
704 # a .moc file that we're expected to generate here.
706 # @remarks Invoked via $(evalvalctx ).
707 define def_unit_qt3_target_pre_handle_moc_src
710 # fetch the properties.
711 local tool
:= $(kb-src-tool dummy_var
)
712 local outbase
:= $(qtmocdir
)/$(notdir $(basename $(source
)))
713 local out
:= $(outbase
).tmp.moc
714 local realout
:= $(outbase
).moc
715 local dep
:= $(realout
).dep
716 local flags
:= $(kb-src-prop FLAGS
,dummy_var
,right-to-left
)
717 local deps
:= $(kb-src-prop DEPS
,dummy_var
,left-to-right
)
718 local orderdeps
:= $(call DIRDEP
,$(dir $(outbase
))) $(kb-src-prop ORDERDEPS
,dummy_var
,left-to-right
)
720 # default path + source dep.
722 local source
:= $(abspathex
$(source
),$(defpath
))
723 local deps
:= $(abspathex
$(deps
),$(defpath
)) $(source
)
724 local incs
:= $(abspathex
$(incs
),$(defpath
))
726 local deps
+= $(source
)
730 ifndef TOOL_
$(tool
)_MOC_CPP_CMDS
731 $(error kBuild
: qt moc tool not found
: TOOL_
$(tool
)_MOC_CPP_CMDS
)
733 local cmds
:= $(TOOL_
$(tool
)_MOC_CPP_CMDS
)
734 local more_output
:= $(TOOL_
$(tool
)_MOC_CPP_OUTPUT
)
735 local maybe_output
:= $(TOOL_
$(tool
)_MOC_CPP_OUTPUT_MAYBE
)
736 local deps
+= $(TOOL_
$(tool
)_MOC_CPP_DEPEND
)
737 local orderdeps
+= $(TOOL_
$(tool
)_MOC_CPP_DEPORD
)
739 # generate the link rule and update some source and target variables.
740 ifndef NO_COMPILE_CMDS_DEPS
741 $(eval includedep
$(dep
))
743 $(eval
$(def_unit_qt3_target_pre_handle_moc_src_dx
))
745 endef # def_unit_qt3_target_pre_handle_moc_src
749 # Adds sources containing Q_OBJECT to QT_MOCSRCS.
750 define def_unit_qt3_target_pre_cpp_source
751 ifneq ($(file-size
$(source
)),-1)
752 ifneq ($(strip $(shell $(SED
) -f
$(KBUILD_PATH
)/units
/qt-Q_OBJECT.sed
$(source
))),)
753 $(eval
$(target
)_QT_MOCSRCS
+= $(source
))
756 endef # def_unit_qt3_target_pre_cpp_source
760 # Invoked early in the processing of a target that uses the Qt unit.
762 # It will append the qt source handlers to the target (.h, .ui, .ts,
765 # It will then check all the C++ sources and check which needs
766 # a .moc files and generate rules and dependencies fofor these
768 define def_unit_qt3_target_pre
770 # Make QTTOOL the default for the specific Qt tools instead of TOOL.
771 ifneq ($($(target
)_QTTOOL
),)
772 ifeq ($($(target
)_MOCTOOL
),)
773 $(target
)_MOCTOOL
:= $($(target
)_QTTOOL
)
775 ifeq ($($(target
)_UICTOOL
),)
776 $(target
)_UICTOOL
:= $($(target
)_QTTOOL
)
778 ifeq ($($(target
)_LRCTOOL
),)
779 $(target
)_LRCTOOL
:= $($(target
)_QTTOOL
)
783 # Deal with QT_MODULES and QT_PREFIX.
784 local qt_prefix
:= $(firstword \
785 $($(target
)_QT_PREFIX.
$(bld_trg
)) \
786 $($(target
)_QT_PREFIX.
$(bld_trg_arch
)) \
787 $($(target
)_QT_PREFIX.
$(bld_trg
).
$(bld_trg_arch
)) \
788 $($(target
)_QT_PREFIX.
$(bld_trg_cpu
)) \
789 $($(target
)_QT_PREFIX.
$(bld_type
)) \
790 $($(target
)_QT_PREFIX
))
791 ifeq ($(bld_trg
),win
)
792 local qt_lib
:= $(firstword $(wildcard \
793 $(PATH_SDK_QT3_LIB
)/dynamic
/$(qt_prefix
)qt-mt3
*$(SUFF_LIB
) \
794 $(PATH_SDK_QT3_LIB
)/$(qt_prefix
)qt-mt3
*$(SUFF_LIB
) \
795 $(PATH_SDK_QT3_LIB
)/dynamic
/$(qt_prefix
)qt-mt
$(SUFF_LIB
) \
796 $(PATH_SDK_QT3_LIB
)/$(qt_prefix
)qt-mt
$(SUFF_LIB
) \
797 $(PATH_SDK_QT3_LIB
)/dynamic
/$(qt_prefix
)Qt3
*$(SUFF_LIB
) \
798 $(PATH_SDK_QT3_LIB
)/$(qt_prefix
)Qt3
*$(SUFF_LIB
) \
799 $(PATH_SDK_QT3_LIB
)/dynamic
/$(qt_prefix
)Qt
*$(SUFF_LIB
) \
800 $(PATH_SDK_QT3_LIB
)/$(qt_prefix
)Qt
*$(SUFF_LIB
) \
801 ) $(PATH_SDK_QT3_LIB
)/$(qt_prefix
)qt-mt
$(SUFF_LIB
) )
802 $(eval
$(target
)_LIBS
+= $(qt_lib
) )
803 ifeq ($(tool_do
),LINK_PROGRAM
)
804 local qt_main_lib
:= $(firstword $(wildcard \
805 $(PATH_SDK_QT3_LIB
)/$(qt_prefix
)qtmain
$(SUFF_LIB
) \
806 $(PATH_SDK_QT3_LIB
)/qtmain
$(SUFF_LIB
) \
807 ) $(PATH_SDK_QT3_LIB
)/$(qt_prefix
)qtmain
$(SUFF_LIB
) )
808 $(eval
$(target
)_LIBS
+= $(qt_main_lib
) )
810 else ifeq ($(bld_trg
),os2
)
811 # This is a real PITA since the dll/lib can be called (almost) anything. :-(
812 local qt_lib
:= $(firstword $(wildcard \
813 $(PATH_SDK_QT3_LIB
)/$(qt_prefix
)*qt3
*$(SUFF_LIB
) \
814 $(PATH_SDK_QT3_LIB
)/$(qt_prefix
)*qt
*$(SUFF_LIB
) \
817 local qt_prls
:= $(basename $(wildcard $(PATH_SDK_QT3_LIB
)/$(qt_prefix
)*.prl
))
818 local qt_defs
:= $(basename $(wildcard $(PATH_SDK_QT3_LIB
)/$(qt_prefix
)*.def
))
819 local qt_dlls
:= $(basename $(wildcard $(PATH_SDK_QT3_LIB
)/$(qt_prefix
)*.dll
))
820 local qt_libs
:= $(basename $(wildcard $(PATH_SDK_QT3_LIB
)/$(qt_prefix
)*.lib
))
821 local qt_lib
:= $(firstword \
822 $(addsuffix .lib
,$(filter $(qt_prls
), $(filter $(qt_defs
), $(filter $(qt_dlls
), $(qt_libs
))))) \
823 $(PATH_SDK_QT3_LIB
)/myqt.lib
)
825 $(eval
$(target
)_LIBS
+= $(qt_lib
) )
827 local qt_lib
:= $(PATH_SDK_QT3_LIB
)/lib
$(qt_prefix
)qt-mt
$(SUFF_DLL
)
828 $(eval
$(target
)_LIBS
+= $(qt_lib
) )
830 $(eval
$(target
)_INCS
+= $(PATH_SDK_QT3_INC
) )
832 # On Qt3 we will try pickup the QMAKE_PRL_DEFINES listed in the .prl file (in libs).
833 local qt_prl
:= $(firstword $(wildcard \
834 $(patsubst %$(SUFF_DLL
),%,$(patsubst %$(SUFF_LIB
),%,$(qt_lib
))).prl \
835 $(dir $(qt_lib
))/$(qt_prefix
)qt-mt.prl \
836 $(dir $(qt_lib
))/*qt-mt
*.prl \
837 $(dir $(qt_lib
))/*qt
*.prl \
841 $(eval
$(target
)_DEFS
+= $(QMAKE_PRL_DEFINES
))
844 # Autodetect source files with Q_OBJECT references if QT_MOCSRCS is undefined. (slow)
845 # Tip: Use target_QT_MOCSRCS = $(NO_SUCH_VARIABLE) to avoid this.
846 ifndef $(target
)_QT_MOCSRCS
847 $(foreach source
, $(filter %.
cxx %.CXX
%.
cpp %.CPP
%.
cc %.CC
,\
848 $($(target
)_SOURCES.
$(bld_trg
)) \
849 $($(target
)_SOURCES.
$(bld_trg_arch
)) \
850 $($(target
)_SOURCES.
$(bld_trg
).
$(bld_trg_arch
)) \
851 $($(target
)_SOURCES.
$(bld_trg_cpu
)) \
852 $($(target
)_SOURCES.
$(bld_type
)) \
853 $($(target
)_SOURCES
) \
854 ), $(evalval def_unit_qt3_target_pre_cpp_source
))
857 # Install source handlers for .ui files.
858 $(target
)_SRC_HANDLERS
+= \
859 .ui
:def_unit_qt3_src_handler_ui \
860 .UI
:def_unit_qt3_src_handler_ui
862 # Calc the MOC and UI output directories and add them to BLDDIRS and INCS.
863 local qtmocdir
:= $($(target
)_0_OUTDIR
)/qtmoc
864 local qtuicdir
:= $($(target
)_0_OUTDIR
)/qtuic
865 local qtnlsdir
:= $($(target
)_0_OUTDIR
)/qtnls
866 $(eval
$(target
)_BLDDIRS
+= $(qtmocdir
) $(qtuicdir
) $(qtnlsdir
) )
867 $(eval
$(target
)_INCS
+= $(qtmocdir
) $(qtuicdir
) )
869 # Calc .ui sources so we can add them to the QT_MOCSRCS and QT_MOCHDRS.
870 local ui_sources
:= $(notdir $(basename $(filter %.ui
%.UI
, \
871 $($(target
)_SOURCES.
$(bld_trg
)) \
872 $($(target
)_SOURCES.
$(bld_trg_arch
)) \
873 $($(target
)_SOURCES.
$(bld_trg
).
$(bld_trg_arch
)) \
874 $($(target
)_SOURCES.
$(bld_trg_cpu
)) \
875 $($(target
)_SOURCES.
$(bld_type
)) \
876 $($(target
)_SOURCES
) \
878 #$(error ui_sources:=$(ui_sources))
880 # Deal with QT_MOCSRCS.
882 $($(target
)_QT_MOCSRCS.
$(bld_trg
)) \
883 $($(target
)_QT_MOCSRCS.
$(bld_trg_arch
)) \
884 $($(target
)_QT_MOCSRCS.
$(bld_trg
).
$(bld_trg_arch
)) \
885 $($(target
)_QT_MOCSRCS.
$(bld_trg_cpu
)) \
886 $($(target
)_QT_MOCSRCS.
$(bld_type
)) \
887 $($(target
)_QT_MOCSRCS
) \
888 $(addsuffix .h
,$(addprefix $(qtuicdir
)/,$(notdir $(basename $(ui_sources
))))) \
889 , $(evalvalctx def_unit_qt3_target_pre_handle_moc_src
))
891 # Deal with QT_MOCHDRS.
893 $($(target
)_QT_MOCHDRS.
$(bld_trg
)) \
894 $($(target
)_QT_MOCHDRS.
$(bld_trg_arch
)) \
895 $($(target
)_QT_MOCHDRS.
$(bld_trg
).
$(bld_trg_arch
)) \
896 $($(target
)_QT_MOCHDRS.
$(bld_trg_cpu
)) \
897 $($(target
)_QT_MOCHDRS.
$(bld_type
)) \
898 $($(target
)_QT_MOCHDRS
) \
899 $(addsuffix .h
,$(addprefix $(qtuicdir
)/,$(notdir $(basename $(ui_sources
))))) \
900 , $(evalvalctx def_unit_qt3_target_pre_handle_moc_hdr
))
902 # Deal with QT_TRANSLATIONS.
903 # ASSUMES (_ALL_)INSTALLS is processed after the targets using this unit.
904 local translations
:= \
905 $($(target
)_QT_TRANSLATIONS.
$(bld_trg
)) \
906 $($(target
)_QT_TRANSLATIONS.
$(bld_trg_arch
)) \
907 $($(target
)_QT_TRANSLATIONS.
$(bld_trg
).
$(bld_trg_arch
)) \
908 $($(target
)_QT_TRANSLATIONS.
$(bld_trg_cpu
)) \
909 $($(target
)_QT_TRANSLATIONS.
$(bld_type
)) \
910 $($(target
)_QT_TRANSLATIONS
)
911 ifneq ($(strip $(translations
)),)
912 local expr
:= _ALL_INSTALLS_IMPLICIT
+= $(target
)-inst-nls
914 ifdef $(target
)_QT_TRANSLATIONS_TEMPLATE
915 $(target
)-inst-nls_TEMPLATE
:= $($(target
)_QT_TRANSLATIONS_TEMPLATE
)
917 $(target
)-inst-nls_MODE
:= 0644
919 ifdef $(target
)_QT_TRANSLATIONS_INST
920 $(target
)-inst-nls_INST
:= $($(target
)_QT_TRANSLATIONS_INST
)
922 $(target
)-inst-nls_SOURCES
:=
923 $(foreach source
, $(translations
)\
924 , $(evalvalctx def_unit_qt3_target_pre_handle_translation
))
927 endef # def_unit_qt3_target_pre
931 # Rule for debugging.
934 @
$(ECHO
) 'The Qt3 SDK variables:'
935 @
$(ECHO
) ' PATH_SDK_QT3 = "$(PATH_SDK_QT3)"'
936 @
$(ECHO
) ' PATH_SDK_QT3_INC = "$(PATH_SDK_QT3_INC)"'
937 @
$(ECHO
) ' PATH_SDK_QT3_LIB = "$(PATH_SDK_QT3_LIB)"'
938 @
$(ECHO
) ' PATH_SDK_QT3_LIB.amd64 = "$(PATH_SDK_QT3_LIB.amd64)"'
939 @
$(ECHO
) ' PATH_SDK_QT3_LIB.x86 = "$(PATH_SDK_QT3_LIB.x86)"'
940 @
$(ECHO
) 'The Qt3 TOOL variables:'
941 @
$(ECHO
) ' PATH_TOOL_QT3_BIN = "$(PATH_TOOL_QT3_BIN)"'
942 @
$(ECHO
) ' TOOL_QT3_BIN_SUFF = "$(TOOL_QT3_BIN_SUFF)"'
943 @
$(ECHO
) ' TOOL_QT3_MOC = "$(TOOL_QT3_MOC)"'
944 @
$(ECHO
) ' TOOL_QT3_UIC = "$(TOOL_QT3_UIC)"'
945 @
$(ECHO
) ' TOOL_QT3_LRC = "$(TOOL_QT3_LRC)"'
946 @
$(ECHO
) ' TOOL_QT3_LUPDATE = "$(TOOL_QT3_LUPDATE)"'