diff options
author | Katja Marttila <katja.marttila@qt.io> | 2016-09-14 13:15:05 +0000 |
---|---|---|
committer | Katja Marttila <katja.marttila@qt.io> | 2016-09-15 07:01:05 +0000 |
commit | 49201fdb99ee6ca7f6bee296f51f5036345017c6 (patch) | |
tree | 392f84e474b15eb60faf477cec226571b4ad728e /tools | |
parent | fc0b26f4d202776456ceca1be4206739a8be9247 (diff) |
Revert "Allow signing maintenancetool in Windows"
This reverts commit 76fd6e8f2953347ea0bf7a57b643968784bc9acc.
The change caused that two installation files were needed -
one executable and one dat file. Many users did not find it acceptable.
We need to figure out something else.
Change-Id: Ief12cd47f9897cee8a234d8611a5c18296d42b1c
Reviewed-by: Iikka Eklund <iikka.eklund@qt.io>
Diffstat (limited to 'tools')
-rw-r--r-- | tools/binarycreator/binarycreator.cpp | 9 | ||||
-rw-r--r-- | tools/devtool/main.cpp | 11 |
2 files changed, 3 insertions, 17 deletions
diff --git a/tools/binarycreator/binarycreator.cpp b/tools/binarycreator/binarycreator.cpp index 23261211d..1a6a10471 100644 --- a/tools/binarycreator/binarycreator.cpp +++ b/tools/binarycreator/binarycreator.cpp @@ -241,12 +241,10 @@ static int assemble(Input input, const QInstaller::Settings &settings, const QSt QTemporaryFile out; QString targetName = input.outputPath; -#if defined Q_OS_OSX || defined Q_OS_WIN - QDir resourcePath(QFileInfo(input.outputPath).dir()); #ifdef Q_OS_OSX + QDir resourcePath(QFileInfo(input.outputPath).dir()); resourcePath.cdUp(); resourcePath.cd(QLatin1String("Resources")); -#endif targetName = resourcePath.filePath(QLatin1String("installer.dat")); #endif @@ -264,10 +262,7 @@ static int assemble(Input input, const QInstaller::Settings &settings, const QSt QInstaller::openForWrite(&out); QFile exe(input.installerExePath); -#if defined Q_OS_OSX || defined Q_OS_WIN - // remove the target - if (QFile::exists(input.outputPath)) - QFile::remove(input.outputPath); +#ifdef Q_OS_OSX if (!exe.copy(input.outputPath)) { throw Error(QString::fromLatin1("Cannot copy %1 to %2: %3").arg(exe.fileName(), input.outputPath, exe.errorString())); diff --git a/tools/devtool/main.cpp b/tools/devtool/main.cpp index 27c459ecc..c9aaab71c 100644 --- a/tools/devtool/main.cpp +++ b/tools/devtool/main.cpp @@ -173,11 +173,6 @@ int main(int argc, char *argv[]) if (QInstaller::isInBundle(path, &bundlePath)) path = QDir(bundlePath).filePath(QLatin1String("Contents/Resources/installer.dat")); -#ifdef Q_OS_WIN - QDir resourcePath(path); - resourcePath.cdUp(); - path = resourcePath.filePath(QLatin1String("installer.dat")); -#endif int result = EXIT_FAILURE; QVector<QByteArray> resourceMappings; quint64 cookie = QInstaller::BinaryContent::MagicCookie; @@ -196,12 +191,8 @@ int main(int argc, char *argv[]) QFileInfo fi(path); if (QInstaller::isInBundle(fi.absoluteFilePath(), &bundlePath)) fi.setFile(bundlePath); -#ifdef Q_OS_WIN - QFileInfo appName = arguments.first(); - path = fi.absoluteDir().filePath(appName.baseName() + QLatin1String(".dat")); -#else path = fi.absolutePath() + QLatin1Char('/') + fi.baseName() + QLatin1String(".dat"); -#endif + tmp.close(); tmp.setFileName(path); QInstaller::openForRead(&tmp); |