forked from qt-creator/qt-creator
Merge remote-tracking branch 'origin/3.0'
Conflicts: qtcreator.pri src/plugins/qnx/qnxutils.cpp Change-Id: I019ad21fb4c128eb736c8ab2d09310757e3be037
This commit is contained in:
@@ -255,6 +255,8 @@ void GenericProject::refresh(RefreshOptions options)
|
||||
part->displayName = displayName();
|
||||
part->projectFile = projectFilePath();
|
||||
|
||||
part->includePaths += projectIncludePaths();
|
||||
|
||||
Kit *k = activeTarget() ? activeTarget()->kit() : KitManager::defaultKit();
|
||||
if (ToolChain *tc = ToolChainKitInformation::toolChain(k)) {
|
||||
QStringList cxxflags; // FIXME: Can we do better?
|
||||
@@ -263,7 +265,6 @@ void GenericProject::refresh(RefreshOptions options)
|
||||
}
|
||||
|
||||
part->cxxVersion = CppTools::ProjectPart::CXX11; // assume C++11
|
||||
part->includePaths += allIncludePaths();
|
||||
part->defines += m_defines;
|
||||
|
||||
// ### add _defines.
|
||||
@@ -337,15 +338,6 @@ QStringList GenericProject::processEntries(const QStringList &paths,
|
||||
return absolutePaths;
|
||||
}
|
||||
|
||||
QStringList GenericProject::allIncludePaths() const
|
||||
{
|
||||
QStringList paths;
|
||||
paths += m_includePaths;
|
||||
paths += m_projectIncludePaths;
|
||||
paths.removeDuplicates();
|
||||
return paths;
|
||||
}
|
||||
|
||||
QStringList GenericProject::projectIncludePaths() const
|
||||
{
|
||||
return m_projectIncludePaths;
|
||||
@@ -356,16 +348,6 @@ QStringList GenericProject::files() const
|
||||
return m_files;
|
||||
}
|
||||
|
||||
QStringList GenericProject::includePaths() const
|
||||
{
|
||||
return m_includePaths;
|
||||
}
|
||||
|
||||
void GenericProject::setIncludePaths(const QStringList &includePaths)
|
||||
{
|
||||
m_includePaths = includePaths;
|
||||
}
|
||||
|
||||
QByteArray GenericProject::defines() const
|
||||
{
|
||||
return m_defines;
|
||||
@@ -425,8 +407,6 @@ bool GenericProject::fromMap(const QVariantMap &map)
|
||||
t->addRunConfiguration(new QtSupport::CustomExecutableRunConfiguration(t));
|
||||
}
|
||||
|
||||
setIncludePaths(allIncludePaths());
|
||||
|
||||
refresh(Everything);
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -85,7 +85,6 @@ public:
|
||||
void setIncludePaths(const QStringList &includePaths);
|
||||
|
||||
QByteArray defines() const;
|
||||
QStringList allIncludePaths() const;
|
||||
QStringList projectIncludePaths() const;
|
||||
QStringList files() const;
|
||||
|
||||
@@ -111,7 +110,6 @@ private:
|
||||
QStringList m_rawFileList;
|
||||
QStringList m_files;
|
||||
QHash<QString, QString> m_rawListEntries;
|
||||
QStringList m_includePaths;
|
||||
QStringList m_projectIncludePaths;
|
||||
QByteArray m_defines;
|
||||
|
||||
|
||||
@@ -163,11 +163,15 @@ Core::GeneratedFiles GenericProjectWizard::generateFiles(const QWizard *w,
|
||||
|
||||
QStringList includePaths;
|
||||
foreach (const QString &path, paths) {
|
||||
QFileInfo fileInfo(dir, path);
|
||||
QFileInfo fileInfo(path);
|
||||
QDir thisDir(fileInfo.absoluteFilePath());
|
||||
|
||||
if (! thisDir.entryList(nameFilters, QDir::Files).isEmpty())
|
||||
includePaths.append(path);
|
||||
if (! thisDir.entryList(nameFilters, QDir::Files).isEmpty()) {
|
||||
QString relative = dir.relativeFilePath(path);
|
||||
if (relative.isEmpty())
|
||||
relative = QLatin1String(".");
|
||||
includePaths.append(relative);
|
||||
}
|
||||
}
|
||||
|
||||
Core::GeneratedFile generatedCreatorFile(creatorFileName);
|
||||
|
||||
Reference in New Issue
Block a user