diff --git a/src/plugins/ios/iosrunfactories.h b/src/plugins/ios/iosrunfactories.h index d45bd47069a0721f647bc874e3c148766fd1b0d0..5b63620e6b65d6f08ea8ba3cad74464f1a2c3727 100644 --- a/src/plugins/ios/iosrunfactories.h +++ b/src/plugins/ios/iosrunfactories.h @@ -31,7 +31,7 @@ #include <projectexplorer/runconfiguration.h> #include <qt4projectmanager/qmakerunconfigurationfactory.h> -#include <qcompilerdetection.h> +#include <utils/qtcoverride.h> namespace ProjectExplorer { class RunControl; @@ -50,25 +50,25 @@ class IosRunConfigurationFactory : public Qt4ProjectManager::QmakeRunConfigurati public: explicit IosRunConfigurationFactory(QObject *parent = 0); - Q_DECL_OVERRIDE QString displayNameForId(const Core::Id id) const; - Q_DECL_OVERRIDE QList<Core::Id> availableCreationIds(ProjectExplorer::Target *parent) const; + QString displayNameForId(const Core::Id id) const QTC_OVERRIDE; + QList<Core::Id> availableCreationIds(ProjectExplorer::Target *parent) const QTC_OVERRIDE; - Q_DECL_OVERRIDE bool canCreate(ProjectExplorer::Target *parent, const Core::Id id) const; - Q_DECL_OVERRIDE ProjectExplorer::RunConfiguration *create(ProjectExplorer::Target *parent, - const Core::Id id); + bool canCreate(ProjectExplorer::Target *parent, const Core::Id id) const QTC_OVERRIDE; + ProjectExplorer::RunConfiguration *create(ProjectExplorer::Target *parent, + const Core::Id id) QTC_OVERRIDE; - Q_DECL_OVERRIDE bool canRestore(ProjectExplorer::Target *parent, const QVariantMap &map) const; - Q_DECL_OVERRIDE ProjectExplorer::RunConfiguration *restore(ProjectExplorer::Target *parent, - const QVariantMap &map); + bool canRestore(ProjectExplorer::Target *parent, const QVariantMap &map) const QTC_OVERRIDE; + ProjectExplorer::RunConfiguration *restore(ProjectExplorer::Target *parent, + const QVariantMap &map) QTC_OVERRIDE; - Q_DECL_OVERRIDE bool canClone(ProjectExplorer::Target *parent, - ProjectExplorer::RunConfiguration *source) const; - Q_DECL_OVERRIDE ProjectExplorer::RunConfiguration *clone(ProjectExplorer::Target *parent, - ProjectExplorer::RunConfiguration *source); + bool canClone(ProjectExplorer::Target *parent, + ProjectExplorer::RunConfiguration *source) const QTC_OVERRIDE; + ProjectExplorer::RunConfiguration *clone(ProjectExplorer::Target *parent, + ProjectExplorer::RunConfiguration *source) QTC_OVERRIDE; - Q_DECL_OVERRIDE bool canHandle(ProjectExplorer::Target *t) const; - Q_DECL_OVERRIDE QList<ProjectExplorer::RunConfiguration *> runConfigurationsForNode(ProjectExplorer::Target *t, - ProjectExplorer::Node *n); + bool canHandle(ProjectExplorer::Target *t) const QTC_OVERRIDE; + QList<ProjectExplorer::RunConfiguration *> runConfigurationsForNode(ProjectExplorer::Target *t, + ProjectExplorer::Node *n) QTC_OVERRIDE; private: ProjectExplorer::RunConfiguration *doCreate(ProjectExplorer::Target *parent, const Core::Id id); ProjectExplorer::RunConfiguration *doRestore(ProjectExplorer::Target *parent, diff --git a/src/tools/3rdparty/iossim/iossim.pro b/src/tools/3rdparty/iossim/iossim.pro index b613d7046e9866a18b92ad19c74cb5b248114e63..77f1604db54381bd0df2afb1521f782544a2674c 100644 --- a/src/tools/3rdparty/iossim/iossim.pro +++ b/src/tools/3rdparty/iossim/iossim.pro @@ -7,7 +7,7 @@ include(../../../../qtcreator.pri) # Prevent from popping up in the dock when launched. # We embed the Info.plist file, so the application doesn't need to # be a bundle. -QMAKE_LFLAGS += -sectcreate __TEXT __info_plist $$shell_quote($$PWD/Info.plist) \ +QMAKE_LFLAGS += -sectcreate __TEXT __info_plist \"$$PWD/Info.plist\" \ -fobjc-link-runtime LIBS += \ diff --git a/src/tools/3rdparty/iossim/main.mm b/src/tools/3rdparty/iossim/main.mm index 1f6d7ba41234e45d10f8da2952a6a548dc70054f..29b67c5c33d2e471ab598f4e64add3f4c55b0165 100644 --- a/src/tools/3rdparty/iossim/main.mm +++ b/src/tools/3rdparty/iossim/main.mm @@ -8,7 +8,11 @@ #import <AppKit/AppKit.h> #import "iphonesimulator.h" #include <QLibrary> +#if QT_VERSION < QT_VERSION_CHECK(5, 0, 0) +#include <QApplication> +#else #include <QGuiApplication> +#endif #include <QString> #include <QStringList> @@ -21,7 +25,12 @@ * Runs the iPhoneSimulator backed by a main runloop. */ int main (int argc, char *argv[]) { +#if QT_VERSION < QT_VERSION_CHECK(5, 0, 0) + QApplication a(argc, argv); +#else QGuiApplication a(argc, argv); +#endif + //NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init]; diff --git a/src/tools/iostool/iosdevicemanager.h b/src/tools/iostool/iosdevicemanager.h index 81fa64606125e26aec166b0e0b8e7fddaf9a79e4..4616d461261dbfee26481f7acea3ff04868731bf 100644 --- a/src/tools/iostool/iosdevicemanager.h +++ b/src/tools/iostool/iosdevicemanager.h @@ -41,6 +41,7 @@ namespace Ios { namespace Internal { +class DevInfoSession; class IosDeviceManagerPrivate; } // namespace Internal @@ -84,6 +85,7 @@ private slots: void checkPendingLookups(); private: friend class Internal::IosDeviceManagerPrivate; + friend class Internal::DevInfoSession; IosDeviceManager(QObject *parent = 0); Internal::IosDeviceManagerPrivate *d; }; diff --git a/src/tools/iostool/iostool.pro b/src/tools/iostool/iostool.pro index 1e503887e2f875842aacb0d1a1e5acdf1caf38ce..fe3392c667803e5838f808ac933dc6c336614e2d 100644 --- a/src/tools/iostool/iostool.pro +++ b/src/tools/iostool/iostool.pro @@ -8,7 +8,7 @@ CONFIG += console # Prevent from popping up in the dock when launched. # We embed the Info.plist file, so the application doesn't need to # be a bundle. -QMAKE_LFLAGS += -sectcreate __TEXT __info_plist $$shell_quote($$PWD/Info.plist) +QMAKE_LFLAGS += -sectcreate __TEXT __info_plist \"$$PWD/Info.plist\" CONFIG -= app_bundle LIBS += -framework CoreFoundation -framework CoreServices -framework IOKit -lssl -lbz2 -framework Security -framework SystemConfiguration diff --git a/src/tools/iostool/main.cpp b/src/tools/iostool/main.cpp index 44136fc3169c0f4c7b90bbced0235d667951dbf2..1cfab9d581b68922ad743846ffda00649909ffe7 100644 --- a/src/tools/iostool/main.cpp +++ b/src/tools/iostool/main.cpp @@ -26,7 +26,12 @@ ** version 1.1, included in the file LGPL_EXCEPTION.txt in this package. ** ****************************************************************************/ +#include <qglobal.h> +#if QT_VERSION < QT_VERSION_CHECK(5, 0, 0) +#include <QApplication> +#else #include <QGuiApplication> +#endif #include <QTextStream> #include <QDebug> #include <QXmlStreamWriter> @@ -81,7 +86,11 @@ IosTool::IosTool(QObject *parent): outFile(), out(&outFile) { +#if QT_VERSION < QT_VERSION_CHECK(5, 0, 0) + outFile.open(stdout, QIODevice::WriteOnly, QFile::DontCloseHandle); +#else outFile.open(stdout, QIODevice::WriteOnly, QFileDevice::DontCloseHandle); +#endif out.setAutoFormatting(true); out.setCodec("UTF-8"); } @@ -376,7 +385,11 @@ void IosTool::errorMsg(const QString &msg) int main(int argc, char *argv[]) { +#if QT_VERSION < QT_VERSION_CHECK(5, 0, 0) + QApplication a(argc, argv); +#else QGuiApplication a(argc, argv); +#endif IosTool tool; tool.run(QCoreApplication::arguments()); int res = a.exec();