build_res.pri 881 B

1234567891011121314151617181920212223242526
  1. message(==========BUILDING EXTERNAL RES============)
  2. guiRes.target = BuildResources
  3. exists($$BIN_PATH/res) {
  4. message("Directory $$BIN_PATH/res already exists")
  5. } else {
  6. message("Directory $$BIN_PATH/res DOES NOT exist")
  7. guiRes.commands += $(MKDIR) \"$$BIN_PATH/res\" $$escape_expand(\n\t)
  8. }
  9. EXT_RES = \
  10. "$${PROJECT_ROOT_PATH}/resources/backgrounds.qrc -o $$BIN_PATH/data01.gtr" \
  11. "$${PROJECT_ROOT_PATH}/resources/common.qrc -o $$BIN_PATH/data02.gtr" \
  12. for (RES, EXT_RES) {
  13. win32 {
  14. message(rcc.exe -binary $${RES})
  15. guiRes.commands += rcc.exe -binary $${RES} $$escape_expand(\n\t)
  16. }
  17. unix {
  18. guiRes.commands += rcc -binary $${RES} $$escape_expand(\n\t)
  19. }
  20. }
  21. QMAKE_EXTRA_TARGETS += guiRes
  22. PRE_TARGETDEPS += BuildResources