qt5base-lts/mkspecs/features/win32/windeployqt.prf
Maurice Kalinowski f2c247921d windeployqt: add clean step to toplevel makefile
Currently you could only invoke windeployqt for debug and release
builds, but not windeployqt_clean resulting in artifacts after
the clean step.

Change-Id: I3a93e4909a017f3594cc5b0c2249ed25b777c008
Reviewed-by: Oliver Wolff <oliver.wolff@theqtcompany.com>
Reviewed-by: Andrew Knight <qt@panimo.net>
2015-01-06 16:50:54 +01:00

21 lines
1016 B
Plaintext

# Extra target for running windeployqt
qtPrepareTool(QMAKE_WINDEPLOYQT, windeployqt)
build_pass {
load(resolve_target)
isEmpty(WINDEPLOYQT_OPTIONS): WINDEPLOYQT_OPTIONS = -qmldir $$shell_quote($$system_path($$_PRO_FILE_PWD_))
WINDEPLOYQT_TARGET = $$shell_quote($$system_path($$QMAKE_RESOLVED_TARGET))
WINDEPLOYQT_OUTPUT = $$shell_quote($$system_path($$dirname(QMAKE_RESOLVED_TARGET)/$$basename(TARGET).windeployqt))
windeployqt.target = windeployqt
windeployqt.commands = $$QMAKE_WINDEPLOYQT $$WINDEPLOYQT_OPTIONS -list target $$WINDEPLOYQT_TARGET > $$WINDEPLOYQT_OUTPUT
windeployqt_clean.commands = if exist $$WINDEPLOYQT_OUTPUT for /f %i in ($$WINDEPLOYQT_OUTPUT) do $$QMAKE_DEL_FILE %~fi && $$QMAKE_DEL_DIR %~pi
QMAKE_EXTRA_TARGETS += windeployqt_clean
DISTCLEAN_DEPS += windeployqt_clean
QMAKE_DISTCLEAN += $$WINDEPLOYQT_OUTPUT
} else {
windeployqt.CONFIG += recursive
windeployqt_clean.CONFIG += recursive
}
QMAKE_EXTRA_TARGETS += windeployqt windeployqt_clean