浏览代码

Facilitate shadow build development since that is the Creator default

Donald Carr 6 年之前
父节点
当前提交
f9d050ed87
共有 2 个文件被更改,包括 3 次插入1 次删除
  1. 2 0
      src/main.cpp
  2. 1 1
      src/src.pro

+ 2 - 0
src/main.cpp

@@ -112,6 +112,8 @@ void ArtView::populateScreen(QScreen *screen)
 #else
 #else
     if (QCoreApplication::applicationDirPath().startsWith("/usr")) {
     if (QCoreApplication::applicationDirPath().startsWith("/usr")) {
         qmlPath = "/usr/share/" % qApp->applicationName() % "/qml";
         qmlPath = "/usr/share/" % qApp->applicationName() % "/qml";
+    } else {
+        qmlPath = QString("%1%2").arg(ORIGINAL_SOURCE_PATH).arg("/../qml");
     }
     }
 #endif
 #endif
 
 

+ 1 - 1
src/src.pro

@@ -14,7 +14,7 @@ CONFIG += c++11
 
 
 linux-*: CONFIG += systemd
 linux-*: CONFIG += systemd
 
 
-DEFINES *= QT_USE_QSTRINGBUILDER
+DEFINES *= QT_USE_QSTRINGBUILDER ORIGINAL_SOURCE_PATH=\\\"$$PWD\\\"
 
 
 #CONFIG += box2d
 #CONFIG += box2d
 box2d {
 box2d {