Commit 592b44e9 authored by dt's avatar dt Committed by con
Browse files

Qt4ProjectManager: Force a qmake run on change in the deploy folder

On a change to the deployment folder, we need to run qmake again to
recreate the pkg file, we do that by setting a flag on all qmakesteps
for symbian and saving/restoring that flag.

Reviewed-By: hunger
parent 48f3e4cd
......@@ -54,6 +54,7 @@ namespace {
const char * const QMAKE_BS_ID("QtProjectManager.QMakeBuildStep");
const char * const QMAKE_ARGUMENTS_KEY("QtProjectManager.QMakeBuildStep.QMakeArguments");
const char * const QMAKE_FORCED_KEY("QtProjectManager.QMakeBuildStep.QMakeForced");
QMakeStep::QMakeStep(BuildStepList *bsl) :
......@@ -72,7 +73,7 @@ QMakeStep::QMakeStep(BuildStepList *bsl, const QString &id) :
QMakeStep::QMakeStep(BuildStepList *bsl, QMakeStep *bs) :
AbstractProcessStep(bsl, bs),
......@@ -302,13 +303,14 @@ QVariantMap QMakeStep::toMap() const
QVariantMap map(AbstractProcessStep::toMap());
map.insert(QLatin1String(QMAKE_ARGUMENTS_KEY), m_userArgs);
map.insert(QLatin1String(QMAKE_FORCED_KEY), m_forced);
return map;
bool QMakeStep::fromMap(const QVariantMap &map)
m_userArgs = map.value(QLatin1String(QMAKE_ARGUMENTS_KEY)).toStringList();
m_forced = map.value(QLatin1String(QMAKE_FORCED_KEY), false).toBool();
return BuildStep::fromMap(map);
......@@ -722,6 +722,24 @@ void Qt4PriFileNode::folderChanged(const QString &folder)
contents.updateSubFolders(this, this);
// The files to be packaged are listed inside the symbian build system.
// We need to regenerate that list by running qmake
// Other platforms do not have a explicit list of files to package, but package
// directories
foreach (ProjectExplorer::Target *target, m_project->targets()) {
if (target->id() == Constants::S60_DEVICE_TARGET_ID) {
foreach (ProjectExplorer::BuildConfiguration *bc, target->buildConfigurations()) {
Qt4BuildConfiguration *qt4bc = qobject_cast<Qt4BuildConfiguration *>(bc);
if (qt4bc) {
QMakeStep *qmakeStep = qt4bc->qmakeStep();
if (qmakeStep)
bool Qt4PriFileNode::deploysFolder(const QString &folder) const
Supports Markdown
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