forked from qt-creator/qt-creator
Merge remote-tracking branch 'origin/3.1'
Conflicts: src/plugins/winrt/winrtruncontrol.cpp src/plugins/winrt/winrtruncontrol.h Change-Id: Idad0558e53e23debee8523586b681af4705e97f6
This commit is contained in:
File diff suppressed because it is too large
Load Diff
@@ -9,22 +9,18 @@ QtcPlugin {
|
||||
property var externalQbsIncludes: project.useExternalQbs
|
||||
? [project.qbs_install_dir + "/include/qbs"] : []
|
||||
property var externalQbsLibraryPaths: project.useExternalQbs
|
||||
? [project.qbs_install_dir + "/lib"] : []
|
||||
property var externalQbsRPaths: project.useExternalQbs
|
||||
? [project.qbs_install_dir + "/lib"] : []
|
||||
? [project.qbs_install_dir + '/' + project.libDirName] : []
|
||||
property var externalQbsDynamicLibraries: {
|
||||
var libs = []
|
||||
if (!project.useExternalQbs)
|
||||
return libs;
|
||||
var suffix = "";
|
||||
if (qbs.targetOS.contains("windows")) {
|
||||
libs.push("shell32")
|
||||
if (qbs.enableDebugCode)
|
||||
libs.push("qbscored")
|
||||
else
|
||||
libs.push("qbscore")
|
||||
} else {
|
||||
libs.push("qbscore")
|
||||
suffix = "d";
|
||||
}
|
||||
libs.push("qbscore" + suffix, "qbsqtprofilesetup" + suffix);
|
||||
return libs
|
||||
}
|
||||
|
||||
@@ -61,7 +57,7 @@ QtcPlugin {
|
||||
])
|
||||
cpp.includePaths: base.concat(externalQbsIncludes)
|
||||
cpp.libraryPaths: base.concat(externalQbsLibraryPaths)
|
||||
cpp.rpaths: base.concat(externalQbsRPaths)
|
||||
cpp.rpaths: base.concat(externalQbsLibraryPaths)
|
||||
cpp.dynamicLibraries: base.concat(externalQbsDynamicLibraries)
|
||||
|
||||
files: [
|
||||
|
@@ -197,7 +197,7 @@ static int extractDeviceId(QByteArray *line)
|
||||
|
||||
static IDevice::MachineType machineTypeFromLine(const QByteArray &line)
|
||||
{
|
||||
return line.startsWith("Emulator ") ? IDevice::Emulator : IDevice::Hardware;
|
||||
return line.contains("Emulator ") ? IDevice::Emulator : IDevice::Hardware;
|
||||
}
|
||||
|
||||
/*
|
||||
@@ -206,6 +206,19 @@ static IDevice::MachineType machineTypeFromLine(const QByteArray &line)
|
||||
* Available devices:
|
||||
* Appx:
|
||||
* 0 local
|
||||
* Phone:
|
||||
* 0 Device
|
||||
* 1 Emulator 8.1 WVGA 4 inch 512MB
|
||||
* 2 Emulator 8.1 WVGA 4 inch
|
||||
* 3 Emulator 8.1 WXGA 4 inch
|
||||
* 4 Emulator 8.1 720P 4.7 inch
|
||||
* 5 Emulator 8.1 1080P 5.5 inch
|
||||
* 6 Emulator 8.1 1080P 6 inch
|
||||
* 7 WE8.1H Emulator WVGA 512MB
|
||||
* 8 WE8.1H Emulator WVGA
|
||||
* 9 WE8.1H Emulator WXGA
|
||||
* 10 WE8.1H Emulator 720P
|
||||
* 11 WE8.1H Emulator 1080P
|
||||
* Xap:
|
||||
* 0 Device
|
||||
* 1 Emulator WVGA 512MB
|
||||
@@ -216,7 +229,7 @@ static IDevice::MachineType machineTypeFromLine(const QByteArray &line)
|
||||
void WinRtDeviceFactory::parseRunnerOutput(const QByteArray &output) const
|
||||
{
|
||||
ProjectExplorer::DeviceManager *deviceManager = ProjectExplorer::DeviceManager::instance();
|
||||
enum State { StartState, AppxState, XapState };
|
||||
enum State { StartState, AppxState, PhoneState, XapState };
|
||||
State state = StartState;
|
||||
int numFound = 0;
|
||||
int numSkipped = 0;
|
||||
@@ -224,6 +237,8 @@ void WinRtDeviceFactory::parseRunnerOutput(const QByteArray &output) const
|
||||
line = line.trimmed();
|
||||
if (line == "Appx:") {
|
||||
state = AppxState;
|
||||
} else if (line == "Phone:") {
|
||||
state = PhoneState;
|
||||
} else if (line == "Xap:") {
|
||||
state = XapState;
|
||||
} else {
|
||||
@@ -239,6 +254,13 @@ void WinRtDeviceFactory::parseRunnerOutput(const QByteArray &output) const
|
||||
internalName += QStringLiteral("appx.");
|
||||
deviceType = Constants::WINRT_DEVICE_TYPE_LOCAL;
|
||||
name = tr("Windows Runtime local UI");
|
||||
} else if (state == PhoneState) {
|
||||
internalName += QStringLiteral("phone.");
|
||||
name = QString::fromLocal8Bit(line);
|
||||
if (machineType == IDevice::Emulator)
|
||||
deviceType = Constants::WINRT_DEVICE_TYPE_EMULATOR;
|
||||
else
|
||||
deviceType = Constants::WINRT_DEVICE_TYPE_PHONE;
|
||||
} else if (state == XapState) {
|
||||
internalName += QStringLiteral("xap.");
|
||||
name = QString::fromLocal8Bit(line);
|
||||
|
@@ -71,15 +71,15 @@ bool WinRtPackageDeploymentStep::init()
|
||||
if (!qt)
|
||||
return false;
|
||||
|
||||
m_isWinPhone = (qt->type() == QLatin1String(Constants::WINRT_WINPHONEQT));
|
||||
|
||||
QString args = QtcProcess::quoteArg(QDir::toNativeSeparators(targetPath));
|
||||
args += QLatin1Char(' ') + m_args;
|
||||
if (m_isWinPhone) {
|
||||
m_manifestFileName = QLatin1String("WMAppManifest");
|
||||
|
||||
m_manifestFileName = QStringLiteral("AppxManifest");
|
||||
|
||||
if (qt->type() == QLatin1String(Constants::WINRT_WINPHONEQT)
|
||||
&& qt->mkspec().toString().contains(QLatin1String("msvc2012"))) {
|
||||
m_createMappingFile = true;
|
||||
} else {
|
||||
m_manifestFileName = QLatin1String("AppxManifest");
|
||||
m_manifestFileName = QStringLiteral("WMAppManifest");
|
||||
}
|
||||
|
||||
if (m_createMappingFile) {
|
||||
|
@@ -61,7 +61,6 @@ private:
|
||||
QString m_executablePathInManifest;
|
||||
QString m_mappingFileContent;
|
||||
QString m_manifestFileName;
|
||||
bool m_isWinPhone;
|
||||
bool m_createMappingFile;
|
||||
};
|
||||
|
||||
|
@@ -83,7 +83,6 @@ bool WinRtRunnerHelper::init(WinRtRunConfiguration *runConfiguration, QString *e
|
||||
return false;
|
||||
}
|
||||
|
||||
m_isWinPhone = (qt->type() == QLatin1String(Constants::WINRT_WINPHONEQT));
|
||||
m_runnerFilePath = qt->binPath().toString() + QStringLiteral("/winrtrunner.exe");
|
||||
if (!QFile::exists(m_runnerFilePath)) {
|
||||
*errorMessage = tr("Cannot find winrtrunner.exe in \"%1\".").arg(
|
||||
@@ -181,8 +180,6 @@ void WinRtRunnerHelper::startWinRtRunner(const RunConf &conf)
|
||||
{
|
||||
using namespace Utils;
|
||||
QString runnerArgs;
|
||||
QtcProcess::addArg(&runnerArgs, QStringLiteral("--profile"));
|
||||
QtcProcess::addArg(&runnerArgs, m_isWinPhone ? QStringLiteral("xap") : QStringLiteral("appx"));
|
||||
if (m_device) {
|
||||
QtcProcess::addArg(&runnerArgs, QStringLiteral("--device"));
|
||||
QtcProcess::addArg(&runnerArgs, QString::number(m_device->deviceId()));
|
||||
|
@@ -89,7 +89,6 @@ private:
|
||||
QString m_debuggerArguments;
|
||||
QString m_arguments;
|
||||
bool m_uninstallAfterStop;
|
||||
bool m_isWinPhone;
|
||||
Utils::QtcProcess *m_process;
|
||||
};
|
||||
|
||||
|
@@ -196,17 +196,17 @@ QMakeEvaluator::~QMakeEvaluator()
|
||||
{
|
||||
}
|
||||
|
||||
void QMakeEvaluator::initFrom(const QMakeEvaluator &other)
|
||||
void QMakeEvaluator::initFrom(const QMakeEvaluator *other)
|
||||
{
|
||||
Q_ASSERT_X(&other, "QMakeEvaluator::visitProFile", "Project not prepared");
|
||||
m_functionDefs = other.m_functionDefs;
|
||||
m_valuemapStack = other.m_valuemapStack;
|
||||
Q_ASSERT_X(other, "QMakeEvaluator::visitProFile", "Project not prepared");
|
||||
m_functionDefs = other->m_functionDefs;
|
||||
m_valuemapStack = other->m_valuemapStack;
|
||||
m_valuemapInited = true;
|
||||
m_qmakespec = other.m_qmakespec;
|
||||
m_qmakespecName = other.m_qmakespecName;
|
||||
m_mkspecPaths = other.m_mkspecPaths;
|
||||
m_featureRoots = other.m_featureRoots;
|
||||
m_dirSep = other.m_dirSep;
|
||||
m_qmakespec = other->m_qmakespec;
|
||||
m_qmakespecName = other->m_qmakespecName;
|
||||
m_mkspecPaths = other->m_mkspecPaths;
|
||||
m_featureRoots = other->m_featureRoots;
|
||||
m_dirSep = other->m_dirSep;
|
||||
}
|
||||
|
||||
//////// Evaluator tools /////////
|
||||
@@ -1354,7 +1354,7 @@ QMakeEvaluator::VisitReturn QMakeEvaluator::visitProFile(
|
||||
return ReturnFalse;
|
||||
#endif
|
||||
|
||||
initFrom(*baseEnv->evaluator);
|
||||
initFrom(baseEnv->evaluator);
|
||||
} else {
|
||||
if (!m_valuemapInited)
|
||||
loadDefaults();
|
||||
|
@@ -155,7 +155,7 @@ public:
|
||||
bool prepareProject(const QString &inDir);
|
||||
bool loadSpecInternal();
|
||||
bool loadSpec();
|
||||
void initFrom(const QMakeEvaluator &other);
|
||||
void initFrom(const QMakeEvaluator *other);
|
||||
void setupProject();
|
||||
void evaluateCommand(const QString &cmds, const QString &where);
|
||||
void applyExtraConfigs();
|
||||
|
Reference in New Issue
Block a user