forked from qt-creator/qt-creator
qbs: apply compiler and linker flags from GCC toolchains.
Change-Id: I27ce0b11238a2a0c9e5f2f1f8d9e5ecfa3cc51f9 Reviewed-by: Christian Kandeler <christian.kandeler@theqtcompany.com>
This commit is contained in:
@@ -27,6 +27,7 @@
|
||||
#include "qbsconstants.h"
|
||||
|
||||
#include <projectexplorer/abi.h>
|
||||
#include <projectexplorer/gcctoolchain.h>
|
||||
#include <projectexplorer/kit.h>
|
||||
#include <projectexplorer/kitinformation.h>
|
||||
#include <projectexplorer/toolchain.h>
|
||||
@@ -255,6 +256,11 @@ QVariantMap DefaultPropertyProvider::autoGeneratedProperties(const ProjectExplor
|
||||
}
|
||||
data.insert(QLatin1String(CPP_TOOLCHAINPATH), cxxFileInfo.absolutePath());
|
||||
|
||||
if (ProjectExplorer::GccToolChain *gcc = dynamic_cast<ProjectExplorer::GccToolChain *>(tc)) {
|
||||
data.insert(QLatin1String(CPP_PLATFORMCOMMONCOMPILERFLAGS), gcc->platformCodeGenFlags());
|
||||
data.insert(QLatin1String(CPP_PLATFORMLINKERFLAGS), gcc->platformLinkerFlags());
|
||||
}
|
||||
|
||||
// TODO: Remove this once compiler version properties are set for MSVC
|
||||
if (targetAbi.osFlavor() == ProjectExplorer::Abi::WindowsMsvc2013Flavor
|
||||
|| targetAbi.osFlavor() == ProjectExplorer::Abi::WindowsMsvc2015Flavor) {
|
||||
|
||||
Reference in New Issue
Block a user