diff --git a/src/plugins/qt4projectmanager/qt-maemo/maemodeployablelistmodel.cpp b/src/plugins/qt4projectmanager/qt-maemo/maemodeployablelistmodel.cpp index 2f78a954fae..2e7186598cf 100644 --- a/src/plugins/qt4projectmanager/qt-maemo/maemodeployablelistmodel.cpp +++ b/src/plugins/qt4projectmanager/qt-maemo/maemodeployablelistmodel.cpp @@ -45,7 +45,8 @@ MaemoDeployableListModel::MaemoDeployableListModel(const Qt4ProFileNode *proFile : QAbstractTableModel(parent), m_proFileNode(proFileNode), m_modified(false), - m_proFileWrapper(new MaemoProFileWrapper(m_proFileNode->path(), proFileOption)) + m_proFileWrapper(new MaemoProFileWrapper(m_proFileNode->path(), + m_proFileNode->buildDir(), proFileOption)) { buildModel(); } @@ -59,8 +60,8 @@ bool MaemoDeployableListModel::buildModel() const MaemoProFileWrapper::InstallsList &installs = m_proFileWrapper->installs(); if (installs.targetPath.isEmpty()) { const QString remoteDir = m_proFileNode->projectType() == LibraryTemplate - ? QLatin1String("/usr/local/lib") - : QLatin1String("/usr/local/bin"); + ? QLatin1String("/usr/lib") + : QLatin1String("/usr/bin"); m_deployables.prepend(MaemoDeployable(localExecutableFilePath(), remoteDir)); QFile projectFile(m_proFileNode->path()); diff --git a/src/plugins/qt4projectmanager/qt-maemo/maemoprofilewrapper.cpp b/src/plugins/qt4projectmanager/qt-maemo/maemoprofilewrapper.cpp index b9ca3677537..fdce039d9a4 100644 --- a/src/plugins/qt4projectmanager/qt-maemo/maemoprofilewrapper.cpp +++ b/src/plugins/qt4projectmanager/qt-maemo/maemoprofilewrapper.cpp @@ -27,9 +27,9 @@ namespace { MaemoProFileWrapper::MaemoProFileWrapper(const QString &proFileName, - const QSharedPointer &proFileOption) + const QString &buildDir, const QSharedPointer &proFileOption) : m_proFileName(proFileName), m_proDir(QFileInfo(m_proFileName).dir()), - m_proFileOption(proFileOption) + m_buildDir(buildDir), m_proFileOption(proFileOption) { parseProFile(ParseFromFile); } @@ -223,6 +223,7 @@ QString MaemoProFileWrapper::absFilePath(const QString &relFilePath) const void MaemoProFileWrapper::parseProFile(ParseType type) const { m_proFileReader.reset(new ProFileReader(m_proFileOption.data())); + m_proFileReader->setOutputDir(m_buildDir); m_proFileReader->setCumulative(false); // TODO: Set output dir to build dir? if (type == ParseFromLines) { diff --git a/src/plugins/qt4projectmanager/qt-maemo/maemoprofilewrapper.h b/src/plugins/qt4projectmanager/qt-maemo/maemoprofilewrapper.h index 9a0f12f9174..58480fa3e26 100644 --- a/src/plugins/qt4projectmanager/qt-maemo/maemoprofilewrapper.h +++ b/src/plugins/qt4projectmanager/qt-maemo/maemoprofilewrapper.h @@ -19,7 +19,7 @@ class ProFileReader; class MaemoProFileWrapper { public: - MaemoProFileWrapper(const QString &proFileName, + MaemoProFileWrapper(const QString &proFileName, const QString &buildDir, const QSharedPointer &proFileOption); ~MaemoProFileWrapper(); @@ -68,6 +68,7 @@ private: const QString m_proFileName; const QDir m_proDir; + const QString m_buildDir; const QSharedPointer m_proFileOption; mutable QStringList m_proFileContents; mutable QScopedPointer m_proFileReader;