From 5abd497a56efde2dc8f4d2e9079f677cff80cc13 Mon Sep 17 00:00:00 2001 From: Iikka Eklund Date: Thu, 21 Jan 2016 09:18:11 +0200 Subject: Update Changelog for version 2.0.2 Change-Id: Ic7900dec6db93ecab54bb60685326226127ce20a Reviewed-by: Jani Heikkinen Reviewed-by: Niels Weber --- Changelog | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/Changelog b/Changelog index a7a823618..6e2b0a706 100644 --- a/Changelog +++ b/Changelog @@ -1,4 +1,18 @@ 2.0.2 +- Doc: Remove dubious sentence from installer.calculateComponentsToUninstall(). +- Update documentation for --runoperation. +- Update the git-archive export options. +- Add alternative option where to read the installer-framework sha1. +- Add sync.profile. +- Add .qt-license-check.exclude and .qt-license-check.optional rules. +- Update license headers. +- Fix target directory check for reserved words on Windows. +- Use QQmlV4Function to correctly get empty parameters from script. (QTIFW-724) +- Fix errors when running updates in a directory requiring elevation. (QTIFW-746) +- Doc: Fix the function name in Controller Scripting page. +- Fix usage of system proxy with credentials. (QTBUG-46547) +- Unify handling of translations. QTIFW-390 +- Init all components with proper install action. (QTIFW-727) - Fix .dat file that gets deleted after multiple component changes on Windows. - Fix maintenance tool upgrade on OS X. - Fix handling of system proxy with credentials. (QTBUG-46547) -- cgit v1.2.3 From 22a0f6b682fb8ef74e11f0e7a2ffac7c8f12222b Mon Sep 17 00:00:00 2001 From: Karsten Heimrich Date: Thu, 21 Jan 2016 12:51:37 +0100 Subject: Fix compile with namespace'ed Qt. Change-Id: I9c0d399943d2f6eb9a0ab136abf24a5c8b108abb Reviewed-by: Christian Stenger --- src/libs/installer/proxycredentialsdialog.h | 2 ++ tests/auto/installer/messageboxhandler/tst_messageboxhandler.cpp | 9 --------- tools/repocompare/mainwindow.h | 3 ++- 3 files changed, 4 insertions(+), 10 deletions(-) diff --git a/src/libs/installer/proxycredentialsdialog.h b/src/libs/installer/proxycredentialsdialog.h index f4935c53d..81b2f7cef 100644 --- a/src/libs/installer/proxycredentialsdialog.h +++ b/src/libs/installer/proxycredentialsdialog.h @@ -35,7 +35,9 @@ #include +QT_BEGIN_NAMESPACE class QNetworkProxy; +QT_END_NAMESPACE namespace QInstaller { diff --git a/tests/auto/installer/messageboxhandler/tst_messageboxhandler.cpp b/tests/auto/installer/messageboxhandler/tst_messageboxhandler.cpp index 75df29949..d032b973f 100644 --- a/tests/auto/installer/messageboxhandler/tst_messageboxhandler.cpp +++ b/tests/auto/installer/messageboxhandler/tst_messageboxhandler.cpp @@ -12,15 +12,6 @@ using namespace QInstaller; -namespace QTest { - template<> - char *toString(const QMessageBox::StandardButton &button) - { - QString buttonAsString(QString::number(button)); - return qstrdup(buttonAsString.toLatin1().data()); - } -} - class tst_MessageBoxHandler : public QObject { Q_OBJECT diff --git a/tools/repocompare/mainwindow.h b/tools/repocompare/mainwindow.h index ecba780dc..ac155b0bd 100644 --- a/tools/repocompare/mainwindow.h +++ b/tools/repocompare/mainwindow.h @@ -42,10 +42,11 @@ #include #include +QT_BEGIN_NAMESPACE namespace Ui { class MainWindow; } - +QT_END_NAMESPACE class MainWindow : public QMainWindow { -- cgit v1.2.3 From 85cad029464f1209b5aeab7150b6e3df1fa1f69b Mon Sep 17 00:00:00 2001 From: Karsten Heimrich Date: Thu, 21 Jan 2016 11:40:11 +0100 Subject: Compile with Qt 5.5, 5.6. Minimum version is now 5.5. Change-Id: I60d248ea38e8176e18a9b2a642e81a0ad5fb21d3 Reviewed-by: Simon Hausmann --- installerfw.pro | 4 ++-- src/libs/installer/component.cpp | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/installerfw.pro b/installerfw.pro index 6dfca3997..c1e058830 100644 --- a/installerfw.pro +++ b/installerfw.pro @@ -13,7 +13,7 @@ BUILD_EXAMPLES = $$(BUILDEXAMPLES) isEmpty(BUILD_EXAMPLES):BUILD_EXAMPLES=$${BUILDEXAMPLES} !isEmpty(BUILD_EXAMPLES):SUBDIRS += examples -!minQtVersion(5, 4, 0) { +!minQtVersion(5, 5, 0) { message("Cannot build Qt Installer Framework with Qt version $${QT_VERSION}.") - error("Use at least Qt 5.4.0.") + error("Use at least Qt 5.5.0.") } diff --git a/src/libs/installer/component.cpp b/src/libs/installer/component.cpp index 5346aac77..d379305a8 100644 --- a/src/libs/installer/component.cpp +++ b/src/libs/installer/component.cpp @@ -1026,9 +1026,9 @@ inline bool convert(QQmlV4Function *func, QStringList *toArgs) *toArgs << val->toQString(); for (int i = 1; i < func->length(); i++) { val = (*func)[i]; - if (val->isObject() && val->asObject()->isArrayObject()) { + if (val->isObject() && val->as()->isArrayObject()) { QV4::ScopedValue valtmp(scope); - QV4::Object *array = val->asObject(); + QV4::Object *array = val->as(); uint length = array->getLength(); for (uint ii = 0; ii < length; ++ii) { valtmp = array->getIndexed(ii); -- cgit v1.2.3 From 9d4be1a53be2b643114d051332d8439bc8809e59 Mon Sep 17 00:00:00 2001 From: Katja Marttila Date: Thu, 4 Feb 2016 12:40:33 +0200 Subject: Fix crash when updating admin installation with user/temp repository Grant permission rights for writing maintenance config file Change-Id: I9364358455b8ad5e98b03c20d949c2562ba2535a Task-number: QTIFW-740 Reviewed-by: Iikka Eklund --- src/libs/installer/packagemanagercore.cpp | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/src/libs/installer/packagemanagercore.cpp b/src/libs/installer/packagemanagercore.cpp index 81fd29472..e008a220d 100644 --- a/src/libs/installer/packagemanagercore.cpp +++ b/src/libs/installer/packagemanagercore.cpp @@ -1025,8 +1025,17 @@ void PackageManagerCore::networkSettingsChanged() d->m_repoFetched = false; d->m_updateSourcesAdded = false; - if (d->isUpdater() || d->isPackageManager()) + if (d->isUpdater() || d->isPackageManager()) { + bool gainedAdminRights = false; + QTemporaryFile tempAdminFile(d->targetDir() + QStringLiteral("/XXXXXX")); + if (!tempAdminFile.open() || !tempAdminFile.isWritable()) { + gainAdminRights(); + gainedAdminRights = true; + } d->writeMaintenanceConfigFiles(); + if (gainedAdminRights) + dropAdminRights(); + } KDUpdater::FileDownloaderFactory::instance().setProxyFactory(proxyFactory()); emit coreNetworkSettingsChanged(); -- cgit v1.2.3 From e67fd518cbdf9c4ea99f88368f4c2b45e625c0c2 Mon Sep 17 00:00:00 2001 From: Katja Marttila Date: Wed, 17 Feb 2016 10:49:51 +0000 Subject: Revert "Use QQmlV4Function to correctly get empty parameters from script." This reverts commit eb574d77b0ab9a92b61e7738d089cd4ea4304e51. The change will not work with Qt5.5 as it is causing constant crashes in Qt installers. Using this change will require a fix for Qt5. As we are about to make Qt installers based on 2.0 we need to revert this change for now. Change-Id: Ia7906d02db645f2407ab07d14f5a037224574b29 Reviewed-by: Andy Shaw --- doc/scripting-api/component.qdoc | 12 ++++ src/libs/installer/component.cpp | 79 +++++++++------------- src/libs/installer/component.h | 19 ++++-- src/libs/installer/installer.pro | 3 +- .../installer/scriptengine/data/addOperation.qs | 52 -------------- tests/auto/installer/scriptengine/scriptengine.qrc | 1 - .../installer/scriptengine/tst_scriptengine.cpp | 67 ------------------ 7 files changed, 58 insertions(+), 175 deletions(-) delete mode 100644 tests/auto/installer/scriptengine/data/addOperation.qs diff --git a/doc/scripting-api/component.qdoc b/doc/scripting-api/component.qdoc index 0dcd28681..1765a1217 100644 --- a/doc/scripting-api/component.qdoc +++ b/doc/scripting-api/component.qdoc @@ -324,6 +324,18 @@ The method is typically called from within \l component::createOperations(). */ +/*! + \qmlmethod boolean component::addOperation(string operation, string parameter1 = "", string parameter2 = "", ..., string parameter10 = "") + + Convenience method for calling addOperation(string, stringlist) with up to 10 arguments. +*/ + +/*! + \qmlmethod boolean component::addElevatedOperation(string operation, string parameter1 = "", string parameter2 = "", ..., string parameter10 = "") + + Convenience method for calling addElevatedOperation(string, stringlist) with up to 10 arguments. +*/ + /*! \qmlmethod boolean component::addElevatedOperation(string operation, stringlist parameters) diff --git a/src/libs/installer/component.cpp b/src/libs/installer/component.cpp index d379305a8..ebd37a641 100644 --- a/src/libs/installer/component.cpp +++ b/src/libs/installer/component.cpp @@ -55,10 +55,6 @@ #include -#include -#include -#include - #include using namespace QInstaller; @@ -706,11 +702,11 @@ void Component::createOperationsForPath(const QString &path) if (fi.isFile()) { static const QString copy = QString::fromLatin1("Copy"); - addOperation(copy, QStringList() << fi.filePath() << target); + addOperation(copy, fi.filePath(), target); } else if (fi.isDir()) { qApp->processEvents(); static const QString mkdir = QString::fromLatin1("Mkdir"); - addOperation(mkdir, QStringList(target)); + addOperation(mkdir, target); QDirIterator it(fi.filePath()); while (it.hasNext()) @@ -750,7 +746,7 @@ void Component::createOperationsForArchive(const QString &archive) if (isZip) { // archives get completely extracted per default (if the script isn't doing other stuff) - addOperation(QLatin1String("Extract"), QStringList() << archive << QLatin1String("@TargetDir@")); + addOperation(QLatin1String("Extract"), archive, QLatin1String("@TargetDir@")); } else { createOperationsForPath(archive); } @@ -1012,44 +1008,24 @@ Operation *Component::createOperation(const QString &operationName, const QStrin return operation; } -namespace { +/*! + Convenience method for calling the operation \a operation with up to ten parameters: + \a parameter1, \a parameter2, \a parameter3, \a parameter4, \a parameter5, \a parameter6, + \a parameter7, \a parameter8, \a parameter9, and \a parameter10. -inline bool convert(QQmlV4Function *func, QStringList *toArgs) + \sa {component::addOperation}{component.addOperation} +*/ +bool Component::addOperation(const QString &operation, const QString ¶meter1, const QString ¶meter2, + const QString ¶meter3, const QString ¶meter4, const QString ¶meter5, const QString ¶meter6, + const QString ¶meter7, const QString ¶meter8, const QString ¶meter9, const QString ¶meter10) { - if (func->length() < 2) - return false; - QV4::Scope scope(func->v4engine()); - QV4::ScopedValue val(scope); - val = (*func)[0]; - - *toArgs << val->toQString(); - for (int i = 1; i < func->length(); i++) { - val = (*func)[i]; - if (val->isObject() && val->as()->isArrayObject()) { - QV4::ScopedValue valtmp(scope); - QV4::Object *array = val->as(); - uint length = array->getLength(); - for (uint ii = 0; ii < length; ++ii) { - valtmp = array->getIndexed(ii); - *toArgs << valtmp->toQStringNoThrow(); - } - } else { - *toArgs << val->toQString(); - } + if (Operation *op = createOperation(operation, parameter1, parameter2, parameter3, parameter4, parameter5, + parameter6, parameter7, parameter8, parameter9, parameter10)) { + addOperation(op); + return true; } - return true; -} -} -/*! - \internal -*/ -bool Component::addOperation(QQmlV4Function *func) -{ - QStringList args; - if (convert(func, &args)) - return addOperation(args[0], args.mid(1)); return false; } @@ -1057,8 +1033,6 @@ bool Component::addOperation(QQmlV4Function *func) Creates and adds an installation operation for \a operation. Add any number of \a parameters. The variables that the parameters contain, such as \c @TargetDir@, are replaced with their values. - - \sa {component::addOperation}{component.addOperation} */ bool Component::addOperation(const QString &operation, const QStringList ¶meters) { @@ -1071,13 +1045,23 @@ bool Component::addOperation(const QString &operation, const QStringList ¶me } /*! - \internal + Convenience method for calling the elevated operation \a operation with up to ten parameters: + \a parameter1, \a parameter2, \a parameter3, \a parameter4, \a parameter5, \a parameter6, + \a parameter7, \a parameter8, \a parameter9, and \a parameter10. + + \sa {component::addElevatedOperation}{component.addElevatedOperation} */ -bool Component::addElevatedOperation(QQmlV4Function *func) +bool Component::addElevatedOperation(const QString &operation, const QString ¶meter1, + const QString ¶meter2, const QString ¶meter3, const QString ¶meter4, const QString ¶meter5, + const QString ¶meter6, const QString ¶meter7, const QString ¶meter8, const QString ¶meter9, + const QString ¶meter10) { - QStringList args; - if (convert(func, &args)) - return addElevatedOperation(args[0], args.mid(1)); + if (Operation *op = createOperation(operation, parameter1, parameter2, parameter3, parameter4, parameter5, + parameter6, parameter7, parameter8, parameter9, parameter10)) { + addElevatedOperation(op); + return true; + } + return false; } @@ -1086,7 +1070,6 @@ bool Component::addElevatedOperation(QQmlV4Function *func) The variables that the parameters contain, such as \c @TargetDir@, are replaced with their values. The operation is executed with elevated rights. - \sa {component::addElevatedOperation}{component.addElevatedOperation} */ bool Component::addElevatedOperation(const QString &operation, const QStringList ¶meters) { diff --git a/src/libs/installer/component.h b/src/libs/installer/component.h index a075a0145..71f10c272 100644 --- a/src/libs/installer/component.h +++ b/src/libs/installer/component.h @@ -44,7 +44,6 @@ #include QT_FORWARD_DECLARE_CLASS(QDebug) -QT_FORWARD_DECLARE_CLASS(QQmlV4Function) namespace KDUpdater { class Update; @@ -131,12 +130,22 @@ public: OperationList operations() const; void addOperation(Operation *operation); - Q_INVOKABLE bool addOperation(QQmlV4Function *args); - bool addOperation(const QString &operation, const QStringList ¶meters); + Q_INVOKABLE bool addOperation(const QString &operation, const QString ¶meter1 = QString(), + const QString ¶meter2 = QString(), const QString ¶meter3 = QString(), + const QString ¶meter4 = QString(), const QString ¶meter5 = QString(), + const QString ¶meter6 = QString(), const QString ¶meter7 = QString(), + const QString ¶meter8 = QString(), const QString ¶meter9 = QString(), + const QString ¶meter10 = QString()); + Q_INVOKABLE bool addOperation(const QString &operation, const QStringList ¶meters); void addElevatedOperation(Operation *operation); - Q_INVOKABLE bool addElevatedOperation(QQmlV4Function *args); - bool addElevatedOperation(const QString &operation, const QStringList ¶meters); + Q_INVOKABLE bool addElevatedOperation(const QString &operation, + const QString ¶meter1 = QString(), const QString ¶meter2 = QString(), + const QString ¶meter3 = QString(), const QString ¶meter4 = QString(), + const QString ¶meter5 = QString(), const QString ¶meter6 = QString(), + const QString ¶meter7 = QString(), const QString ¶meter8 = QString(), + const QString ¶meter9 = QString(), const QString ¶meter10 = QString()); + Q_INVOKABLE bool addElevatedOperation(const QString &operation, const QStringList ¶meters); QStringList downloadableArchives() const; Q_INVOKABLE void addDownloadableArchive(const QString &path); diff --git a/src/libs/installer/installer.pro b/src/libs/installer/installer.pro index cfa83d08d..87af31f3c 100644 --- a/src/libs/installer/installer.pro +++ b/src/libs/installer/installer.pro @@ -34,8 +34,7 @@ QT += \ xml \ concurrent \ widgets \ - core-private \ - qml-private + core-private win32:QT += winextras HEADERS += packagemanagercore.h \ diff --git a/tests/auto/installer/scriptengine/data/addOperation.qs b/tests/auto/installer/scriptengine/data/addOperation.qs deleted file mode 100644 index d7d505a6b..000000000 --- a/tests/auto/installer/scriptengine/data/addOperation.qs +++ /dev/null @@ -1,52 +0,0 @@ -/************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: http://www.qt.io/licensing/ -** -** This file is part of the Qt Installer Framework. -** -** $QT_BEGIN_LICENSE:LGPL21$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see http://www.qt.io/terms-conditions. For further -** information use the contact form at http://www.qt.io/contact-us. -** -** GNU Lesser General Public License Usage -** Alternatively, this file may be used under the terms of the GNU Lesser -** General Public License version 2.1 or version 3 as published by the Free -** Software Foundation and appearing in the file LICENSE.LGPLv21 and -** LICENSE.LGPLv3 included in the packaging of this file. Please review the -** following information to ensure the GNU Lesser General Public License -** requirements will be met: https://www.gnu.org/licenses/lgpl.html and -** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. -** -** As a special exception, The Qt Company gives you certain additional -** rights. These rights are described in The Qt Company LGPL Exception -** version 1.1, included in the file LGPL_EXCEPTION.txt in this package. -** -** $QT_END_LICENSE$ -** -**************************************************************************/ - -function Component() -{ -} - -Component.prototype.createOperations = function () -{ - console.log("Component::createOperations()"); - component.createOperations(); - - component.addOperation("EmptyArg", "Arg", "Arg2", ""); - component.addOperation("EmptyArg", "Arg", "", "Arg3"); - component.addOperation("EmptyArg", "", "Arg2", "Arg3"); - component.addOperation("EmptyArg", ["Arg", "Arg2", ""]); - - component.addElevatedOperation("EmptyArg", "eArg", "eArg2", ""); - component.addElevatedOperation("EmptyArg", "eArg", "", "eArg3"); - component.addElevatedOperation("EmptyArg", "", "eArg2", "eArg3"); - component.addElevatedOperation("EmptyArg", ["eArg", "eArg2", ""]); -} diff --git a/tests/auto/installer/scriptengine/scriptengine.qrc b/tests/auto/installer/scriptengine/scriptengine.qrc index 9c72e686f..d630f3196 100644 --- a/tests/auto/installer/scriptengine/scriptengine.qrc +++ b/tests/auto/installer/scriptengine/scriptengine.qrc @@ -8,6 +8,5 @@ data/enteringpage.qs data/form.ui data/userinterface.qs - data/addOperation.qs diff --git a/tests/auto/installer/scriptengine/tst_scriptengine.cpp b/tests/auto/installer/scriptengine/tst_scriptengine.cpp index d2e04b513..998e91523 100644 --- a/tests/auto/installer/scriptengine/tst_scriptengine.cpp +++ b/tests/auto/installer/scriptengine/tst_scriptengine.cpp @@ -33,7 +33,6 @@ #include #include -#include #include #include #include @@ -157,30 +156,6 @@ signals: void emitted(); }; -class EmptyArgOperation : public KDUpdater::UpdateOperation -{ -public: - EmptyArgOperation() { - setName("EmptyArg"); - } - - void backup() {} - bool performOperation() { - return true; - } - bool undoOperation() { - return true; - } - bool testOperation() { - return true; - } - UpdateOperation *clone() const { - return 0; - } -}; - - -// -- tst_ScriptEngine class tst_ScriptEngine : public QObject { @@ -197,10 +172,6 @@ private slots: m_component->setValue("Default", "Script"); m_component->setValue(scName, "component.test.name"); - Component *component = new Component(&m_core); - component->setValue(scName, "component.test.addOperation"); - m_core.appendRootComponent(component); - m_scriptEngine = m_core.componentScriptEngine(); } @@ -488,44 +459,6 @@ private slots: QCOMPARE(enteringPage->invocationOrder(), expectedOrder); } - void testAddOperation_AddElevatedOperation() - { - using namespace KDUpdater; - UpdateOperationFactory &factory = UpdateOperationFactory::instance(); - factory.registerUpdateOperation(QLatin1String("EmptyArg")); - - try { - m_core.setPackageManager(); - Component *component = m_core.componentByName("component.test.addOperation"); - component->loadComponentScript(":///data/addOperation.qs"); - - setExpectedScriptOutput("\"Component::createOperations()\""); - component->createOperations(); - - const OperationList operations = component->operations(); - QCOMPARE(operations.count(), 8); - - struct { - const char* args[3]; - const char* operator[](int i) const { - return args[i]; - } - } expectedArgs[] = { - { "Arg", "Arg2", "" }, { "Arg", "", "Arg3" }, { "", "Arg2", "Arg3" }, { "Arg", "Arg2", "" }, - { "eArg", "eArg2", "" }, { "eArg", "", "eArg3" }, { "", "eArg2", "eArg3" }, { "eArg", "eArg2", "" } - }; - - for (int i = 0; i < operations.count(); ++i) { - const QStringList arguments = operations[i]->arguments(); - QCOMPARE(arguments.count(), 3); - for (int j = 0; j < 3; ++j) - QCOMPARE(arguments[j], QString(expectedArgs[i][j])); - } - } catch (const QInstaller::Error &error) { - QFAIL(qPrintable(error.message())); - } - } - private: void setExpectedScriptOutput(const char *message) { -- cgit v1.2.3 From 3388e613f2018661dced481bc9aa1c35b2e0531c Mon Sep 17 00:00:00 2001 From: Iikka Eklund Date: Mon, 21 Mar 2016 10:53:30 +0200 Subject: Update version number for 2.0.3 release Also update the Changelog. Change-Id: I2a74edd32783bdfb01d4706dcbc2d3ae78ac5069 Reviewed-by: Kai Koehne --- Changelog | 6 ++++++ dist/config/config.xml | 4 ++-- dist/packages/org.qtproject.ifw.binaries/meta/package.xml | 4 ++-- dist/packages/org.qtproject.ifw/meta/package.xml | 2 +- installerfw.pri | 4 ++-- 5 files changed, 13 insertions(+), 7 deletions(-) diff --git a/Changelog b/Changelog index 6e2b0a706..92cd9d1ad 100644 --- a/Changelog +++ b/Changelog @@ -1,3 +1,9 @@ +2.0.3 +- Revert "Use QQmlV4Function to correctly get empty parameters from script." +- Fix crash when updating admin installation with user/temp repository (QTIFW-740) +- Compile with Qt 5.5, 5.6. Minimum version is now 5.5. +- Fix compile with namespace'ed Qt. + 2.0.2 - Doc: Remove dubious sentence from installer.calculateComponentsToUninstall(). - Update documentation for --runoperation. diff --git a/dist/config/config.xml b/dist/config/config.xml index e7a665621..052c367bc 100644 --- a/dist/config/config.xml +++ b/dist/config/config.xml @@ -1,7 +1,7 @@ Qt Installer Framework - Qt Installer Framework 2.0.2 + Qt Installer Framework 2.0.3 1.0.0 Qt Project http://qt-project.org @@ -9,5 +9,5 @@ Uninstaller - @HomeDir@/Qt/QtIFW2.0.2 + @HomeDir@/Qt/QtIFW2.0.3 diff --git a/dist/packages/org.qtproject.ifw.binaries/meta/package.xml b/dist/packages/org.qtproject.ifw.binaries/meta/package.xml index 8b20b4624..9071d167e 100644 --- a/dist/packages/org.qtproject.ifw.binaries/meta/package.xml +++ b/dist/packages/org.qtproject.ifw.binaries/meta/package.xml @@ -2,7 +2,7 @@ Qt Installer Framework Binaries Installs the binaries, examples and help files. - 2.0.2 - 2015-06-16 + 2.0.3 + 2016-03-24 True diff --git a/dist/packages/org.qtproject.ifw/meta/package.xml b/dist/packages/org.qtproject.ifw/meta/package.xml index 2cf18dbc9..93e8ef326 100644 --- a/dist/packages/org.qtproject.ifw/meta/package.xml +++ b/dist/packages/org.qtproject.ifw/meta/package.xml @@ -2,7 +2,7 @@ Qt Installer Framework Installs the Qt Installer Framework. - 2.0.2 + 2.0.3 2015-06-16 diff --git a/installerfw.pri b/installerfw.pri index f5e2e0e52..f2ee3dd67 100644 --- a/installerfw.pri +++ b/installerfw.pri @@ -3,8 +3,8 @@ } IFW_PRI_INCLUDED = 1 -IFW_VERSION_STR = 2.0.2 -IFW_VERSION = 0x020002 +IFW_VERSION_STR = 2.0.3 +IFW_VERSION = 0x020003 IFW_REPOSITORY_FORMAT_VERSION = 1.0.0 IFW_NEWLINE = $$escape_expand(\\n\\t) -- cgit v1.2.3 From 39c2dadb47ab8fbe842fd968b5e86bd93e2d0110 Mon Sep 17 00:00:00 2001 From: Katja Marttila Date: Tue, 22 Mar 2016 09:19:26 +0200 Subject: Update minimum Qt version for 2.0.3 release Minimum required version is now Qt5.5 Change-Id: If000a507f0067650605987d38374bf6694eb16aa Reviewed-by: Kai Koehne --- INSTALL | 31 ++++--------------------------- doc/installerfw-getting-started.qdoc | 23 ++++------------------- tools/binarycreator/binarycreator.pro | 2 -- 3 files changed, 8 insertions(+), 48 deletions(-) diff --git a/INSTALL b/INSTALL index bef28a32c..e99fcf743 100644 --- a/INSTALL +++ b/INSTALL @@ -15,7 +15,7 @@ http://code.qt.io/cgit/installer-framework/installer-framework.git/ Build a static Qt --------------------- -Building the Qt Installer Framework from sources requires Qt (version 5.4.0 +Building the Qt Installer Framework from sources requires Qt (version 5.5 or newer). Supported compilers are MSVC 2013 or newer, GCC 4.7 or newer, and Clang 3.1 or newer. @@ -26,44 +26,21 @@ See the Qt documentation for the prerequisites and steps to build Qt from source ### Windows -For Qt 5.4, you need to adjust the respective qmake.conf to have a real stand alone -working installer. Replace -MD, -MDd with -MT, -MTD in the CFLAGS lines. - -'git diff' should show you something like: - ---- a/mkspecs/win32-msvc2013/qmake.conf -+++ b/mkspecs/win32-msvc2013/qmake.conf - QMAKE_CFLAGS = -nologo -Zm200 -Zc:wchar_t -FS - QMAKE_CFLAGS_WARN_ON = -W3 - QMAKE_CFLAGS_WARN_OFF = -W0 --QMAKE_CFLAGS_RELEASE = -O2 -MD -Zc:strictStrings --QMAKE_CFLAGS_RELEASE_WITH_DEBUGINFO += -O2 -MD -Zi -Zc:strictStrings --QMAKE_CFLAGS_DEBUG = -Zi -MDd -+QMAKE_CFLAGS_RELEASE = -O2 -MT -Zc:strictStrings -+QMAKE_CFLAGS_RELEASE_WITH_DEBUGINFO += -O2 -MT -Zi -Zc:strictStrings -+QMAKE_CFLAGS_DEBUG = -Zi -MTd - QMAKE_CFLAGS_YACC = - QMAKE_CFLAGS_LTCG = -GL - QMAKE_CFLAGS_MP = -MP - -From Qt 5.5 onwards, you can achieve the same by passing -static-runtime to -configure. - Recommended configuration options for Microsoft Windows: -configure -prefix %CD%\qtbase -release -static -target xp -accessibility -no-opengl -no-icu -no-sql-sqlite -no-qml-debug -nomake examples -nomake tests -skip qtactiveqt -skip qtenginio -skip qtlocation -skip qtmultimedia -skip qtserialport -skip qtquick1 -skip qtquickcontrols -skip qtscript -skip qtsensors -skip qtwebkit -skip qtwebsockets -skip qtxmlpatterns +configure -prefix %CD%\qtbase -release -static -static-runtime -target xp -accessibility -no-opengl -no-icu -no-sql-sqlite -no-qml-debug -nomake examples -nomake tests -skip qtactiveqt -skip qtenginio -skip qtlocation -skip qtmultimedia -skip qtserialport -skip qtquick1 -skip qtquickcontrols -skip qtscript -skip qtsensors -skip qtwebkit -skip qtwebsockets -skip qtxmlpatterns -skip qt3d ### Linux Recommended configuration options for Linux: -configure -prefix $PWD/qtbase -release -static -accessibility -qt-zlib -qt-libpng -qt-libjpeg -qt-xcb -qt-pcre -qt-freetype -no-glib -no-cups -no-sql-sqlite -no-qml-debug -no-opengl -no-egl -no-xinput -no-xinput2 -no-sm -no-icu -nomake examples -nomake tests -skip qtactiveqt -skip qtenginio -skip qtlocation -skip qtmultimedia -skip qtserialport -skip qtquick1 -skip qtquickcontrols -skip qtscript -skip qtsensors -skip qtwebkit -skip qtwebsockets -skip qtxmlpatterns +configure -prefix $PWD/qtbase -release -static -accessibility -qt-zlib -qt-libpng -qt-libjpeg -qt-xcb -qt-pcre -qt-freetype -no-glib -no-cups -no-sql-sqlite -no-qml-debug -no-opengl -no-egl -no-xinput -no-xinput2 -no-sm -no-icu -nomake examples -nomake tests -skip qtactiveqt -skip qtenginio -skip qtlocation -skip qtmultimedia -skip qtserialport -skip qtquick1 -skip qtquickcontrols -skip qtscript -skip qtsensors -skip qtwebkit -skip qtwebsockets -skip qtxmlpatterns -skip qt3d ### OS X Recommended configuration options for OS X: -configure -prefix $PWD/qtbase -release -static -accessibility -qt-zlib -qt-libpng -qt-libjpeg -no-cups -no-sql-sqlite -no-qml-debug -nomake examples -nomake tests -skip qtactiveqt -skip qtenginio -skip qtlocation -skip qtmultimedia -skip qtserialport -skip qtquick1 -skip qtquickcontrols -skip qtscript -skip qtsensors -skip qtwebkit -skip qtwebsockets -skip qtxmlpatterns +configure -prefix $PWD/qtbase -release -static -accessibility -qt-zlib -qt-libpng -qt-libjpeg -no-cups -no-sql-sqlite -no-qml-debug -nomake examples -nomake tests -skip qtactiveqt -skip qtenginio -skip qtlocation -skip qtmultimedia -skip qtserialport -skip qtquick1 -skip qtquickcontrols -skip qtscript -skip qtsensors -skip qtwebkit -skip qtwebsockets -skip qtxmlpatterns -skip qt3d Build the Framework diff --git a/doc/installerfw-getting-started.qdoc b/doc/installerfw-getting-started.qdoc index c18ccec47..9db26a992 100644 --- a/doc/installerfw-getting-started.qdoc +++ b/doc/installerfw-getting-started.qdoc @@ -67,30 +67,15 @@ you do not have to deliver Qt libraries, which enables you to distribute installers as one file. - The minimum required Qt version is 5.4.0. + The minimum required Qt version is 5.5. \section3 Configuring Qt for Windows - Usually, you want to tweak Qt to statically link in the C - runtime library. This can be done by changing the default mkspec of - your compiler (Qt 5.4) or by passing \c{-static-runtime} to configure (Qt 5.5 - and newer). - - For Qt 5.4, you need to edit - \c{mkspecs\win32-msvc2013\qmake.conf} and replace in the CFLAGS sections - '-MD' with '-MT': - - \code - QMAKE_CFLAGS_RELEASE = -O2 -MT -Zc:strictStrings - QMAKE_CFLAGS_RELEASE_WITH_DEBUGINFO += -O2 -MT -Zi -Zc:strictStrings - QMAKE_CFLAGS_DEBUG = -Zi -MTd - \endcode - We recommend that you use the following options when you configure Qt for Windows: \code - configure -prefix %CD%\qtbase -release -static -target xp -accessibility -no-opengl -no-icu -no-sql-sqlite -no-qml-debug -nomake examples -nomake tests -skip qtactiveqt -skip qtenginio -skip qtlocation -skip qtmultimedia -skip qtserialport -skip qtquick1 -skip qtquickcontrols -skip qtscript -skip qtsensors -skip qtwebkit -skip qtwebsockets -skip qtxmlpatterns + configure -prefix %CD%\qtbase -release -static -static-runtime -target xp -accessibility -no-opengl -no-icu -no-sql-sqlite -no-qml-debug -nomake examples -nomake tests -skip qtactiveqt -skip qtenginio -skip qtlocation -skip qtmultimedia -skip qtserialport -skip qtquick1 -skip qtquickcontrols -skip qtscript -skip qtsensors -skip qtwebkit -skip qtwebsockets -skip qtxmlpatterns -skip qt3d \endcode @@ -99,7 +84,7 @@ We recommend that you use the following configuration options for Linux: \code - configure -prefix $PWD/qtbase -release -static -accessibility -qt-zlib -qt-libpng -qt-libjpeg -qt-xcb -qt-pcre -qt-freetype -no-glib -no-cups -no-sql-sqlite -no-qml-debug -no-opengl -no-egl -no-xinput -no-xinput2 -no-sm -no-icu -nomake examples -nomake tests -skip qtactiveqt -skip qtenginio -skip qtlocation -skip qtmultimedia -skip qtserialport -skip qtquick1 -skip qtquickcontrols -skip qtscript -skip qtsensors -skip qtwebkit -skip qtwebsockets -skip qtxmlpatterns + configure -prefix $PWD/qtbase -release -static -accessibility -qt-zlib -qt-libpng -qt-libjpeg -qt-xcb -qt-pcre -qt-freetype -no-glib -no-cups -no-sql-sqlite -no-qml-debug -no-opengl -no-egl -no-xinput -no-xinput2 -no-sm -no-icu -nomake examples -nomake tests -skip qtactiveqt -skip qtenginio -skip qtlocation -skip qtmultimedia -skip qtserialport -skip qtquick1 -skip qtquickcontrols -skip qtscript -skip qtsensors -skip qtwebkit -skip qtwebsockets -skip qtxmlpatterns -skip qt3d \endcode \section3 Configuring Qt for OS X @@ -107,7 +92,7 @@ We recommend that you use the following configuration options for OS X: \code - configure -prefix $PWD/qtbase -release -static -accessibility -qt-zlib -qt-libpng -qt-libjpeg -no-cups -no-sql-sqlite -no-qml-debug -nomake examples -nomake tests -skip qtactiveqt -skip qtenginio -skip qtlocation -skip qtmultimedia -skip qtserialport -skip qtquick1 -skip qtquickcontrols -skip qtscript -skip qtsensors -skip qtwebkit -skip qtwebsockets -skip qtxmlpatterns + configure -prefix $PWD/qtbase -release -static -accessibility -qt-zlib -qt-libpng -qt-libjpeg -no-cups -no-sql-sqlite -no-qml-debug -nomake examples -nomake tests -skip qtactiveqt -skip qtenginio -skip qtlocation -skip qtmultimedia -skip qtserialport -skip qtquick1 -skip qtquickcontrols -skip qtscript -skip qtsensors -skip qtwebkit -skip qtwebsockets -skip qtxmlpatterns -skip qt3d \endcode \section2 Setting up Qt Installer Framework diff --git a/tools/binarycreator/binarycreator.pro b/tools/binarycreator/binarycreator.pro index 248c2439b..08c83f5a7 100644 --- a/tools/binarycreator/binarycreator.pro +++ b/tools/binarycreator/binarycreator.pro @@ -7,8 +7,6 @@ include(../../installerfw.pri) QT -= gui QT += qml xml -!minQtVersion(5,4,0): QTPLUGIN += qtaccessiblewidgets - CONFIG += console DESTDIR = $$IFW_APP_PATH SOURCES = binarycreator.cpp \ -- cgit v1.2.3 From 5707b1e5e5ec9f113332f229b34df72788d3e03a Mon Sep 17 00:00:00 2001 From: Rafael Roquetto Date: Fri, 15 Apr 2016 13:20:44 -0300 Subject: Fix MSVC2015 build. Change-Id: I502e48dea6329bd6f05a776a669093f41698a274 Reviewed-by: Karsten Heimrich --- src/libs/7zip/win/CPP/7zip/Archive/7z/7zUpdate.cpp | 2 +- src/libs/7zip/win/CPP/7zip/UI/Common/Update.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/libs/7zip/win/CPP/7zip/Archive/7z/7zUpdate.cpp b/src/libs/7zip/win/CPP/7zip/Archive/7z/7zUpdate.cpp index ee7f55c04..874e94e68 100644 --- a/src/libs/7zip/win/CPP/7zip/Archive/7z/7zUpdate.cpp +++ b/src/libs/7zip/win/CPP/7zip/Archive/7z/7zUpdate.cpp @@ -322,7 +322,7 @@ struct CSolidGroup CRecordVector Indices; }; -static wchar_t *g_ExeExts[] = +static const wchar_t *g_ExeExts[] = { L"dll", L"exe", diff --git a/src/libs/7zip/win/CPP/7zip/UI/Common/Update.cpp b/src/libs/7zip/win/CPP/7zip/UI/Common/Update.cpp index a57ec2a6b..4b9c6abac 100644 --- a/src/libs/7zip/win/CPP/7zip/UI/Common/Update.cpp +++ b/src/libs/7zip/win/CPP/7zip/UI/Common/Update.cpp @@ -902,7 +902,7 @@ HRESULT UpdateArchive( AString path = GetAnsiString(arcPath); AString name = GetAnsiString(fileName); // Warning!!! MAPISendDocuments function changes Current directory - fnSend(0, ";", (LPSTR)(LPCSTR)path, (LPSTR)(LPCSTR)name, 0); + fnSend(0, const_cast(";"), (LPSTR)(LPCSTR)path, (LPSTR)(LPCSTR)name, 0); } } #endif -- cgit v1.2.3 From 220d18b41b836a0c10ea097a6f93c3f5d204bf50 Mon Sep 17 00:00:00 2001 From: Katja Marttila Date: Wed, 30 Mar 2016 16:06:34 +0300 Subject: Make IFW compile with FreeBSD Change-Id: Ibebc25b738c843c0eb4291faa2bba7ac9836b008 Task-number: QTIFW-841 Reviewed-by: Ralf Nolden Reviewed-by: Karsten Heimrich --- src/libs/installer/adminauthorization_x11.cpp | 6 +++++- src/libs/kdtools/kdsysinfo_x11.cpp | 9 +++++++++ 2 files changed, 14 insertions(+), 1 deletion(-) diff --git a/src/libs/installer/adminauthorization_x11.cpp b/src/libs/installer/adminauthorization_x11.cpp index 97c6093ae..bf1d0c082 100644 --- a/src/libs/installer/adminauthorization_x11.cpp +++ b/src/libs/installer/adminauthorization_x11.cpp @@ -49,9 +49,13 @@ #include #include #else +#ifdef Q_OS_FREEBSD +#include +#include +#else #include #endif - +#endif #include #include #include diff --git a/src/libs/kdtools/kdsysinfo_x11.cpp b/src/libs/kdtools/kdsysinfo_x11.cpp index e47734c7c..1cdf3d4e8 100644 --- a/src/libs/kdtools/kdsysinfo_x11.cpp +++ b/src/libs/kdtools/kdsysinfo_x11.cpp @@ -36,6 +36,11 @@ #include #include +#ifdef Q_OS_FREEBSD +#include +#include +#endif + #include #include #include @@ -62,7 +67,11 @@ quint64 installedMemory() #else quint64 physmem; size_t len = sizeof physmem; +#ifdef Q_OS_FREEBSD + static int mib[2] = { CTL_HW, HW_PHYSMEM }; +#else static int mib[2] = { CTL_HW, HW_MEMSIZE }; +#endif sysctl(mib, 2, &physmem, &len, 0, 0); return quint64(physmem); #endif -- cgit v1.2.3 From 359d4846ba94f7ded8a951b3363721454632f358 Mon Sep 17 00:00:00 2001 From: Takayuki ORITO Date: Fri, 29 Apr 2016 13:37:37 +0900 Subject: Fix the exception message because missing a space. Added space between 'convert' from 'path'. Change-Id: I25f4eedc7d322d29c8c93dd7dd80fc13232de0b7 Reviewed-by: Niels Weber --- src/libs/installer/lib7z_facade.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/libs/installer/lib7z_facade.cpp b/src/libs/installer/lib7z_facade.cpp index 8f21343db..675403fe8 100644 --- a/src/libs/installer/lib7z_facade.cpp +++ b/src/libs/installer/lib7z_facade.cpp @@ -1351,7 +1351,7 @@ void Lib7z::createArchive(QFileDevice* archive, const QStringList &sourcePaths, const UString nativePath = QString2UString(cleanPath); if (UString2QString(nativePath) != cleanPath) { throw SevenZipException(QCoreApplication::translate("Lib7z", "Could not convert" - "path: %1.").arg(path)); + " path: %1.").arg(path)); } censor.AddItem(true /* always include item */, nativePath, false /* never recurse*/); } -- cgit v1.2.3 From e40b085a4f7680d452111d1bbe355cb110228fe7 Mon Sep 17 00:00:00 2001 From: Takayuki ORITO Date: Fri, 29 Apr 2016 15:37:14 +0900 Subject: Update Japanese translation (new 2). Update new 2 messages in ja.ts. Change-Id: Ifde5277b4ec968472831c46a940480471dec33dd Reviewed-by: Tasuku Suzuki Reviewed-by: Niels Weber --- src/sdk/translations/ja.ts | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/sdk/translations/ja.ts b/src/sdk/translations/ja.ts index 3f14998b6..0dee45eda 100644 --- a/src/sdk/translations/ja.ts +++ b/src/sdk/translations/ja.ts @@ -2099,6 +2099,10 @@ Do you want to continue? Password パスワード + + Proxy Credentials + プロキシ認証 + QInstaller::ServerAuthenticationDialog @@ -2402,6 +2406,10 @@ Do you want to continue? Could not create output file for writing: %1 書き込み用に出力ファイルを作成できませんでした: %1 + + Could not convert path: %1. + パスを変換できませんでした: %1 + ExtractCallbackImpl -- cgit v1.2.3 From 3cfa1c10e9f98ed85e02efa7852a231abeaf8440 Mon Sep 17 00:00:00 2001 From: Takayuki ORITO Date: Fri, 29 Apr 2016 17:07:59 +0900 Subject: Cleanup Japanese translation (12 obsolete). Remove 12 obsolete messages in ja.ts. Change-Id: I2d514b93056f5755760ff4eb1b44e36923b01f1c Reviewed-by: Katja Marttila --- src/sdk/translations/ja.ts | 71 ---------------------------------------------- 1 file changed, 71 deletions(-) diff --git a/src/sdk/translations/ja.ts b/src/sdk/translations/ja.ts index 0dee45eda..5fdd0605c 100644 --- a/src/sdk/translations/ja.ts +++ b/src/sdk/translations/ja.ts @@ -640,10 +640,6 @@ QInstaller::Component - - Could not open the requested translation file '%1'. - 要求された翻訳ファイル '%1' を開けませんでした。 - Could not open the requested UI file '%1'. Error: %2 要求された UI ファイル '%1' を開けませんでした。エラー: %2 @@ -2540,66 +2536,6 @@ Do you want to continue? - 残り時間: 不明。 - - QtPatchOperation - - Invalid arguments in %0: %1 arguments given, %2 expected%3. - %0 に無効な引数: %1個の引数が渡されましたが、必要なのは%2です%3。 - - - 3 or 4 - 3あるいは4個 - - - Needed installer object in "%1" operation is empty. - "%1" のインストーラ作成に必要な操作が見つかりません。 - - - First argument should be 'linux', 'mac' or 'windows'. No other type is supported at this time. - 最初の引数は 'linux', 'mac', 'windows' のいずれかを指定してください。それ以外はサポートしていません。 - - - Could not find the needed QmakeOutputInstallerKey(%1) value on the installer object. The ConsumeOutput operation on the valid qmake needs to be called first. - インストーラに必要な QmakeOutputInstallerKey(%1) の値を見つけることができませんでした。適切な qmake で ConsumeOutput 操作を最初に実行する必要があります。 - - - QMake from the current Qt version -(%1)is not existing. Please file a bugreport with this dialog at https://bugreports.qt-project.org. - 現在の Qt のバージョン(%1)の QMake が見つかりません。このダイアログから https://bugreports.qt-project.org へバグ報告をしてください。 - - - The output of -%1 -query -is not parseable. Please file a bugreport with this dialog https://bugreports.qt-project.org. -output: "%2" - 以下の出力がパースできません。 -%1 -query -このダイアログから https://bugreports.qt-project.org へバグ報告をしてください。 -出力: "%2" - - - Qt patch error: new Qt dir(%1) -needs to be less than 255 characters. - Qt パッチエラー: 新しい Qt のパス(%1) -は255文字以下である必要があります。 - - - Qt patch error: Can not open %1.(%2) - Qt パッチエラー: %1 を開けません。(%2) - - - The installer was not able to get the unpatched path from -%1.(maybe it is broken or removed) -It tried to patch the Qt binaries, but all other files in Qt are unpatched. -This could result in a broken Qt version. -Sometimes it helps to restart the installer with a switched off antivirus software. - インストーラはパッチ未適用時のパスを %1 から取得できませんでした。 -(おそらくファイルが壊れているか削除されています) -Qt のバイナリにパッチを適用しようとしましたが、Qt の他のすべてのファイルに対してパッチは適用されていません。 -このため、この Qt は正常な状態に無い可能性があります。 -アンチウィルスソフトウェアをオフにしてインストーラを再起動することによって改善されるかもしれません。 - - RemoteClient @@ -2626,13 +2562,6 @@ as root and then clicking OK. コマンドを送信した後、すべてのデータを読み込めませんでした: %1。想定バイト数: %2 、受信バイト数: %3。エラー: %4 - - QInstaller::RemoteServerConnection - - Could not read all data after sending command: %1. Bytes expected: %2, Bytes received: %3. Error: %4 - コマンドを送信した後、すべてのデータを読み込めませんでした: %1。想定バイト数: %2 、受信バイト数: %3。エラー: %4 - - KDLockFile -- cgit v1.2.3 From 7093049f8cd821668207fd8254437abf10665273 Mon Sep 17 00:00:00 2001 From: Katja Marttila Date: Mon, 2 May 2016 12:18:56 +0300 Subject: Update changelog Change-Id: I31ddb526ec76b4b28a457dbb95b1809fb5425395 Reviewed-by: Iikka Eklund --- Changelog | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Changelog b/Changelog index 92cd9d1ad..7fc5d902d 100644 --- a/Changelog +++ b/Changelog @@ -1,4 +1,7 @@ 2.0.3 +- Update Japanese translation. +- Make IFW compile with FreeBSD. (QTIFW-841) +- Fix MSVC2015 build. - Revert "Use QQmlV4Function to correctly get empty parameters from script." - Fix crash when updating admin installation with user/temp repository (QTIFW-740) - Compile with Qt 5.5, 5.6. Minimum version is now 5.5. -- cgit v1.2.3 From d80d903cfe22dba86cd8d0bdfd6a0e60bbbe0a41 Mon Sep 17 00:00:00 2001 From: Leena Miettinen Date: Thu, 12 May 2016 16:57:32 +0200 Subject: Doc: PackageManagerCore::ComponentType is now an enum Change the documentation accordingly. Change-Id: I2f15bf724558794b66e99eab1120dc2d224600de Reviewed-by: Katja Marttila --- src/libs/installer/packagemanagercore.cpp | 48 ++++++++++++++----------------- 1 file changed, 21 insertions(+), 27 deletions(-) diff --git a/src/libs/installer/packagemanagercore.cpp b/src/libs/installer/packagemanagercore.cpp index e008a220d..e6cd4f5a4 100644 --- a/src/libs/installer/packagemanagercore.cpp +++ b/src/libs/installer/packagemanagercore.cpp @@ -1348,34 +1348,28 @@ void PackageManagerCore::appendRootComponent(Component *component) } /*! - \class PackageManagerCore::ComponentType - \inmodule QtInstallerFramework - \brief The ComponentType class describes a component list. - - This class is used with the components() function to describe what type of \c Component - list it should return. - - \list - \li \c Root returns a list of root components. - - \li \c Descendants returns a list of all descendant components. - - \note In updater mode the list is empty, because component updates cannot have children. - - \li \c Dependencies returns a list of all available dependencies when run as updater. - - \note When running as installer, package manager, or uninstaller, this will always - result in an empty list. - - \li \c Replacements returns a list of all available replacement components relevant to the - run mode. - - \li \c AllNoReplacements returns a list of available components, including root, descendant, + \enum PackageManagerCore::ComponentType + \brief describes the type of the component list to be returned + + \value Root + Returns a list of root components. + \value Descendants + Returns a list of all descendant components. In updater mode the + list is empty, because component updates cannot have children. + \value Dependencies + Returns a list of all available dependencies when run as updater. + When running as installer, package manager, or uninstaller, this + will always result in an empty list. + \value Replacements + Returns a list of all available replacement components relevant to + the run mode. + \value AllNoReplacements + Returns a list of available components, including root, descendant, and dependency components relevant to the run mode. - - \li \c All returns a list of all available components, including root, descendant, - dependency, and replacement components relevant to the run mode. - \endlist + \value All + Returns a list of all available components, including root, + descendant, dependency, and replacement components relevant to the + run mode. */ /*! -- cgit v1.2.3 From fe9314573b4020b28697d66eba7daeb688cb1b2c Mon Sep 17 00:00:00 2001 From: Leena Miettinen Date: Fri, 13 May 2016 11:50:18 +0200 Subject: Doc: Describe return values for boolean Component functions ...to suppress QDoc warnings. Change-Id: Ib79b0392efaed37b4a52932d4f7d98327a3ad306 Reviewed-by: Katja Marttila --- src/libs/installer/component.cpp | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/src/libs/installer/component.cpp b/src/libs/installer/component.cpp index ebd37a641..1e7edf725 100644 --- a/src/libs/installer/component.cpp +++ b/src/libs/installer/component.cpp @@ -1013,6 +1013,8 @@ Operation *Component::createOperation(const QString &operationName, const QStrin \a parameter1, \a parameter2, \a parameter3, \a parameter4, \a parameter5, \a parameter6, \a parameter7, \a parameter8, \a parameter9, and \a parameter10. + Returns \c true if the operation succeeds, otherwise returns \c false. + \sa {component::addOperation}{component.addOperation} */ bool Component::addOperation(const QString &operation, const QString ¶meter1, const QString ¶meter2, @@ -1033,6 +1035,8 @@ bool Component::addOperation(const QString &operation, const QString ¶meter1 Creates and adds an installation operation for \a operation. Add any number of \a parameters. The variables that the parameters contain, such as \c @TargetDir@, are replaced with their values. + + Returns \c true if the operation succeeds, otherwise returns \c false. */ bool Component::addOperation(const QString &operation, const QStringList ¶meters) { @@ -1050,6 +1054,8 @@ bool Component::addOperation(const QString &operation, const QStringList ¶me \a parameter7, \a parameter8, \a parameter9, and \a parameter10. \sa {component::addElevatedOperation}{component.addElevatedOperation} + + Returns \c true if the operation succeeds, otherwise returns \c false. */ bool Component::addElevatedOperation(const QString &operation, const QString ¶meter1, const QString ¶meter2, const QString ¶meter3, const QString ¶meter4, const QString ¶meter5, @@ -1070,6 +1076,8 @@ bool Component::addElevatedOperation(const QString &operation, const QString &pa The variables that the parameters contain, such as \c @TargetDir@, are replaced with their values. The operation is executed with elevated rights. + Returns \c true if the operation succeeds, otherwise returns \c false. + */ bool Component::addElevatedOperation(const QString &operation, const QStringList ¶meters) { @@ -1082,8 +1090,9 @@ bool Component::addElevatedOperation(const QString &operation, const QStringList } /*! - Specifies whether operations should be automatically created when the installation starts. This - would be done by calling createOperations(). If you set this to \c false, it is completely up + Returns whether operations should be automatically created when the + installation starts and createOperations() is called. If you set this to + \c false, it is completely up to the component's script to create all operations. \sa {component::autoCreateOperations}{component.autoCreateOperations} -- cgit v1.2.3 From a5d3bbcbb37437e8499c25b4a721b18185d68783 Mon Sep 17 00:00:00 2001 From: Leena Miettinen Date: Fri, 13 May 2016 12:29:36 +0200 Subject: Doc: Fix link to Supported Platforms in Qt Reference Docs MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The module name is needed, because there is a Supported Platforms section in this Manual, too. Change-Id: I3d77c89a2afc006d6e423d21ee46e7fbfee2058b Reviewed-by: Topi Reiniö --- doc/installerfw-getting-started.qdoc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/doc/installerfw-getting-started.qdoc b/doc/installerfw-getting-started.qdoc index 9db26a992..08c5b5682 100644 --- a/doc/installerfw-getting-started.qdoc +++ b/doc/installerfw-getting-started.qdoc @@ -40,7 +40,7 @@ \section1 Supported Platforms You can use the Qt Installer Framework to create installers for all - platforms supported by \l{Desktop Platforms}{desktop Qt}. + platforms supported by \l[QtDoc]{Supported Platforms}{desktop Qt}. The installers have been tested on the following platforms: -- cgit v1.2.3 From 9bdcadbc3c189f2b2c408538066e3726820defd8 Mon Sep 17 00:00:00 2001 From: Leena Miettinen Date: Fri, 13 May 2016 13:59:35 +0200 Subject: Doc: Fix PackageManagerCore::ComponentType brief MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The \enum command \brief commands do not seem to get automatically completed during builds anymore. Change-Id: Id81aa8f3044f6151d6b4d8a441e386deb0ca4844 Reviewed-by: Topi Reiniö --- src/libs/installer/packagemanagercore.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/libs/installer/packagemanagercore.cpp b/src/libs/installer/packagemanagercore.cpp index e6cd4f5a4..b6a21be39 100644 --- a/src/libs/installer/packagemanagercore.cpp +++ b/src/libs/installer/packagemanagercore.cpp @@ -1349,7 +1349,7 @@ void PackageManagerCore::appendRootComponent(Component *component) /*! \enum PackageManagerCore::ComponentType - \brief describes the type of the component list to be returned + \brief This enum holds the type of the component list to be returned: \value Root Returns a list of root components. -- cgit v1.2.3 From ac4784ad6fb26994ae7c6502cb4ec89ae39b9103 Mon Sep 17 00:00:00 2001 From: Iikka Eklund Date: Thu, 12 May 2016 12:24:08 +0300 Subject: Do not force doc build on Linux when calling "make install" Change-Id: I7081e43810ec8c05c75f6772140e1a464dbc08ad Reviewed-by: Katja Marttila --- doc/doc.pri | 6 ------ 1 file changed, 6 deletions(-) diff --git a/doc/doc.pri b/doc/doc.pri index f23df0e26..a11a39b53 100644 --- a/doc/doc.pri +++ b/doc/doc.pri @@ -34,12 +34,6 @@ qch_docs.commands = $$HELPGENERATOR -o $$QCH_FILE $$QHP_FILE qch_docs.depends += html_docs qch_docs.files = $$QCH_FILE -unix:!macx { - qch_docs.path = $$PREFIX/doc - qch_docs.CONFIG += no_check_exist - INSTALLS += qch_docs -} - docs_online.depends = html_docs_online QMAKE_EXTRA_TARGETS += html_docs_online docs_online -- cgit v1.2.3 From 2cb5ecf0d7c7e652d1f085cb8807a1957a1df26c Mon Sep 17 00:00:00 2001 From: Katja Marttila Date: Tue, 17 May 2016 09:32:19 +0300 Subject: add missing tr for "AlreadyRunning" messagebox MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Change-Id: Icffe886597a1f18d9eaacf1e3a14f31e252919c6 Reviewed-by: Topi Reiniö Reviewed-by: Iikka Eklund --- src/sdk/installerbase.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/sdk/installerbase.cpp b/src/sdk/installerbase.cpp index 82a08411b..3c220cdba 100644 --- a/src/sdk/installerbase.cpp +++ b/src/sdk/installerbase.cpp @@ -83,8 +83,8 @@ int InstallerBase::run() // the fact that we could not create the lock file and check the running processes. if (runCheck.isRunning(KDRunOnceChecker::ConditionFlag::ProcessList)) { QInstaller::MessageBoxHandler::information(0, QLatin1String("AlreadyRunning"), - QString::fromLatin1("Waiting for %1").arg(qAppName()), - QString::fromLatin1("Another %1 instance is already running. Wait " + tr("Waiting for %1").arg(qAppName()), + tr("Another %1 instance is already running. Wait " "until it finishes, close it, or restart your system.").arg(qAppName())); return EXIT_FAILURE; } -- cgit v1.2.3 From 62c34c7e5554b3dc32c3fa3be6dcb930629eb5a4 Mon Sep 17 00:00:00 2001 From: Katja Marttila Date: Mon, 16 May 2016 12:34:21 +0300 Subject: add make install functionality with INSTALL_ROOT Change-Id: I8bad1c9bbe7b705ff0842f15fb0c9bc6c127e9bc Reviewed-by: Simon Hausmann Reviewed-by: Iikka Eklund --- src/libs/7zip/7zip.pro | 3 +++ src/libs/installer/installer.pro | 3 +++ src/sdk/sdk.pro | 3 +++ tools/archivegen/archivegen.pro | 3 +++ tools/binarycreator/binarycreator.pro | 3 +++ tools/devtool/devtool.pro | 3 +++ tools/repogen/repogen.pro | 3 +++ 7 files changed, 21 insertions(+) diff --git a/src/libs/7zip/7zip.pro b/src/libs/7zip/7zip.pro index 01b69dad2..5e1424d44 100644 --- a/src/libs/7zip/7zip.pro +++ b/src/libs/7zip/7zip.pro @@ -19,3 +19,6 @@ unix { QMAKE_CXXFLAGS += -fvisibility=hidden -w include($$7ZIP_BASE/unix.pri) #this is p7zip } + +target.path = $$[QT_INSTALL_LIBS] +INSTALLS += target diff --git a/src/libs/installer/installer.pro b/src/libs/installer/installer.pro index 87af31f3c..53daf978d 100644 --- a/src/libs/installer/installer.pro +++ b/src/libs/installer/installer.pro @@ -221,3 +221,6 @@ win32 { win32-g++*:LIBS += -lmpr -luuid win32-g++*:QMAKE_CXXFLAGS += -Wno-missing-field-initializers } + +target.path = $$[QT_INSTALL_LIBS] +INSTALLS += target diff --git a/src/sdk/sdk.pro b/src/sdk/sdk.pro index 8e78b121a..4993ad38d 100644 --- a/src/sdk/sdk.pro +++ b/src/sdk/sdk.pro @@ -142,3 +142,6 @@ win32 { } macx:include(../../no_app_bundle.pri) + +target.path = $$[QT_INSTALL_BINS] +INSTALLS += target diff --git a/tools/archivegen/archivegen.pro b/tools/archivegen/archivegen.pro index 135c34010..da4d4b2ec 100644 --- a/tools/archivegen/archivegen.pro +++ b/tools/archivegen/archivegen.pro @@ -15,3 +15,6 @@ SOURCES += archive.cpp \ HEADERS += ../common/repositorygen.h macx:include(../../no_app_bundle.pri) + +target.path = $$[QT_INSTALL_BINS] +INSTALLS += target diff --git a/tools/binarycreator/binarycreator.pro b/tools/binarycreator/binarycreator.pro index 08c83f5a7..ddde5e984 100644 --- a/tools/binarycreator/binarycreator.pro +++ b/tools/binarycreator/binarycreator.pro @@ -17,3 +17,6 @@ HEADERS = rcc/rcc.h RESOURCES += binarycreator.qrc macx:include(../../no_app_bundle.pri) + +target.path = $$[QT_INSTALL_BINS] +INSTALLS += target diff --git a/tools/devtool/devtool.pro b/tools/devtool/devtool.pro index 1ff6e6e85..0b52d7ca1 100644 --- a/tools/devtool/devtool.pro +++ b/tools/devtool/devtool.pro @@ -19,3 +19,6 @@ SOURCES += main.cpp \ binarydump.cpp osx:include(../../no_app_bundle.pri) + +target.path = $$[QT_INSTALL_BINS] +INSTALLS += target diff --git a/tools/repogen/repogen.pro b/tools/repogen/repogen.pro index e6ee4476a..f415a5988 100644 --- a/tools/repogen/repogen.pro +++ b/tools/repogen/repogen.pro @@ -15,3 +15,6 @@ SOURCES += repogen.cpp \ HEADERS += ../common/repositorygen.h macx:include(../../no_app_bundle.pri) + +target.path = $$[QT_INSTALL_BINS] +INSTALLS += target -- cgit v1.2.3 From 9b6b59cfc19dc61dd642706a24e1c5d3b6b39609 Mon Sep 17 00:00:00 2001 From: Katja Marttila Date: Tue, 24 May 2016 13:22:00 +0300 Subject: Make Execute operation work without arguments in Windows Since Qt5.5, QProcess start() needs a program to start. When using native arguments the program is empty and QProcess will fail to start. Removed the use of native arguments until QProcess supports setting program through native arguments. Task-number: QTIFW-862 Change-Id: Ia56344e1bf82fbd76e4e8f2ae8b6817e4bb2fce1 Reviewed-by: Kai Koehne --- src/libs/installer/elevatedexecuteoperation.cpp | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-) diff --git a/src/libs/installer/elevatedexecuteoperation.cpp b/src/libs/installer/elevatedexecuteoperation.cpp index 5de3c0203..cb1a8372c 100644 --- a/src/libs/installer/elevatedexecuteoperation.cpp +++ b/src/libs/installer/elevatedexecuteoperation.cpp @@ -172,16 +172,7 @@ bool ElevatedExecuteOperation::Private::run(const QStringList &arguments) } //readProcessOutput should only called from this current Thread -> Qt::DirectConnection QObject::connect(process, SIGNAL(readyRead()), q, SLOT(readProcessOutput()), Qt::DirectConnection); -#ifdef Q_OS_WIN - if (args.count() == 1) { - process->setNativeArguments(args.front()); - qDebug() << "ElevatedExecuteOperation setNativeArguments to start:" << args.front(); - process->start(QString(), QStringList()); - } else -#endif - { - process->start(args.front(), args.mid(1)); - } + process->start(args.front(), args.mid(1)); qDebug() << args.front() << "started, arguments:" << QStringList(args.mid(1)).join(QLatin1String(" ")); bool success = false; -- cgit v1.2.3 From 6a06b8adc5d6fabac4401219044b928043e7e8a9 Mon Sep 17 00:00:00 2001 From: Katja Marttila Date: Fri, 17 Jun 2016 12:16:35 +0300 Subject: Fix settings test QFile either returns 'Unknown error' or 'No such file or directory' when trying to use non-existing file. Make settings test work with both values. Change-Id: I5245b5ad0cf5b91a7eec61c17315982ce14eecfb Reviewed-by: Iikka Eklund --- tests/auto/installer/settings/tst_settings.cpp | 20 +++++++++++++------- 1 file changed, 13 insertions(+), 7 deletions(-) diff --git a/tests/auto/installer/settings/tst_settings.cpp b/tests/auto/installer/settings/tst_settings.cpp index 6deea6093..bf45f4856 100644 --- a/tests/auto/installer/settings/tst_settings.cpp +++ b/tests/auto/installer/settings/tst_settings.cpp @@ -108,15 +108,21 @@ void tst_Settings::loadEmptyConfig() void tst_Settings::loadNotExistingConfig() { - QTest::ignoreMessage(QtDebugMsg, "create Error-Exception: \"Could not open settings file " - ":/data/inexisting_config.xml for reading: " - "Unknown error\" "); + QString configFile = QLatin1String(":/data/inexisting_config.xml"); + QFile file(configFile); + QString errorString; + + if (!file.open(QIODevice::ReadOnly)) { + errorString = file.errorString(); + } + QTest::ignoreMessage(QtDebugMsg, QString::fromLatin1("create Error-Exception: \"Could not open" + " settings file %1 for reading: %2\"") + .arg(configFile).arg(errorString).toLatin1()); try { - Settings::fromFileAndPrefix(":/data/inexisting_config.xml", ":/data"); + Settings::fromFileAndPrefix(configFile, ":/data"); } catch (const Error &error) { - QCOMPARE(error.message(), QLatin1String("Could not open settings file " - ":/data/inexisting_config.xml for reading: " - "Unknown error")); + QCOMPARE(error.message(), QString::fromLatin1("Could not open settings file " + "%1 for reading: %2").arg(configFile).arg(errorString)); return; } QFAIL("No exception thrown"); -- cgit v1.2.3