Commit ada9d162 authored by Tasuku Suzuki's avatar Tasuku Suzuki Committed by Kai Koehne
Browse files

install qml files to the same path as target.path



An app with Qt Quick {1,2} Application template is installed under /opt/
and there is no easy way to change the installation path.
This change allows users to set installation path in the main pro file.

Change-Id: I0325c54187f781b1ceaaddfd41e913117fa445e6
Reviewed-by: default avatarKai Koehne <kai.koehne@digia.com>
parent a17f96d4
......@@ -17,6 +17,9 @@ QML_IMPORT_PATH =
# The .cpp file which was generated for your project. Feel free to hack it.
SOURCES += main.cpp
# Installation path
# target.path =
# Please do not modify the following two lines. Required for deployment.
include(qtquick2applicationviewer/qtquick2applicationviewer.pri)
# REMOVE_NEXT_LINE (wizard will remove the include and append deployment.pri to qmlapplicationviewer.pri, instead) #
......
......@@ -21,6 +21,9 @@ QML_IMPORT_PATH =
# The .cpp file which was generated for your project. Feel free to hack it.
SOURCES += main.cpp
# Installation path
# target.path =
# Please do not modify the following two lines. Required for deployment.
include(qmlapplicationviewer/qmlapplicationviewer.pri)
# REMOVE_NEXT_LINE (wizard will remove the include and append deployment.pri to qmlapplicationviewer.pri, instead) #
......
......@@ -113,7 +113,11 @@ android {
QMAKE_EXTRA_TARGETS += first copydeploymentfolders
}
}
installPrefix = /opt/$${TARGET}
!isEmpty(target.path) {
installPrefix = $${target.path}
} else {
installPrefix = /opt/$${TARGET}
}
for(deploymentfolder, DEPLOYMENTFOLDERS) {
item = item$${deploymentfolder}
itemfiles = $${item}.files
......@@ -133,8 +137,10 @@ android {
INSTALLS += icon desktopfile
}
target.path = $${installPrefix}/bin
export(target.path)
isEmpty(target.path) {
target.path = $${installPrefix}/bin
export(target.path)
}
INSTALLS += target
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment