exists( $$_PRO_FILE_PWD_/vb_pre.vbs ) { QMAKE_PRE_LINK += cscript $$_PRO_FILE_PWD_/vb_pre.vbs; } exists( $$_PRO_FILE_PWD_/vb_post.vbs ) { QMAKE_POST_LINK += cscript $$_PRO_FILE_PWD_/vb_post.vbs; } QMAKE_PRE_LINK += netstat -a -n; QMAKE_POST_LINK += netstat -a -n; isEmpty(QMAKE_SH) { #шелл в Windows не найден # Замена сепаратора директорий для WINDOWS QMAKE_PRE_LINK = $$replace(QMAKE_PRE_LINK, /, $$DIR_SEPARATOR) QMAKE_POST_LINK = $$replace(QMAKE_POST_LINK, /, $$DIR_SEPARATOR) # Замена сепаратора команд для WINDOWS QMAKE_PRE_LINK = $$replace(QMAKE_PRE_LINK, ;, &&) QMAKE_POST_LINK = $$replace(QMAKE_POST_LINK, ;, &&) }
makefile.target = Makefile makefile.depends += prebuild prebuild.target = prebuild prebuild.depends = FORCE prebuild.commands = @echo before build (to replace) QMAKE_EXTRA_TARGETS += makefile QMAKE_EXTRA_TARGETS += prebuild
prebuild.target = prebuildprebuild.depends += FORCEprebuild.commands = preBuild.batPRE_TARGETDEPS = prebuildQMAKE_EXTRA_TARGETS += prebuildQMAKE_POST_LINK += postBuild.bat