From b70c1522724ff977209d2a883ed8ba75a238dca1 Mon Sep 17 00:00:00 2001 From: Martin Rotter Date: Thu, 1 Sep 2016 08:25:13 +0200 Subject: [PATCH] Custom artifacts name when WebEngine is not used. --- rssguard.pro | 17 +++++++++++++++-- src/main.cpp | 1 + src/miscellaneous/application.cpp | 4 ++-- 3 files changed, 18 insertions(+), 4 deletions(-) diff --git a/rssguard.pro b/rssguard.pro index 5c02c8fe4..7707d7f02 100755 --- a/rssguard.pro +++ b/rssguard.pro @@ -150,6 +150,11 @@ isEmpty(APP_REVISION) { APP_REVISION = "" } +equals(USE_WEBENGINE, false) { + # Add extra revision naming when building without webengine. + APP_REVISION = $$sprintf('%1-%2', $$APP_REVISION, nowebengine) +} + DEFINES += APP_REVISION='"\\\"$$APP_REVISION\\\""' message(rssguard: RSS Guard version is: \"$$APP_VERSION\".) @@ -559,8 +564,16 @@ win32 { QMAKE_EXTRA_TARGETS += seven_zip zip } -equals(USE_WEBENGINE, false) { - # Add extra file naming when building without webengine. +unix:!mac { + seven_zip.target = 7zip + seven_zip.depends = install + seven_zip.commands = 7za a -t7z $$TARGET-$$APP_VERSION-$$APP_REVISION-win32.7z $$shell_path($$PREFIX/*) + + zip.target = zip + zip.depends = install + zip.commands = 7za a -tzip $$TARGET-$$APP_VERSION-$$APP_REVISION-win32.zip $$shell_path($$PREFIX/*) + + QMAKE_EXTRA_TARGETS += seven_zip zip } # Create NSIS installer target on Windows. diff --git a/src/main.cpp b/src/main.cpp index 7144a758d..a11138349 100755 --- a/src/main.cpp +++ b/src/main.cpp @@ -38,6 +38,7 @@ #include #include + int main(int argc, char *argv[]) { for (int i = 0; i < argc; i++) { const QString str = QString::fromLocal8Bit(argv[i]); diff --git a/src/miscellaneous/application.cpp b/src/miscellaneous/application.cpp index 518fe075d..b1c86de8a 100755 --- a/src/miscellaneous/application.cpp +++ b/src/miscellaneous/application.cpp @@ -54,8 +54,8 @@ Application::Application(const QString &id, int &argc, char **argv) connect(this, SIGNAL(saveStateRequest(QSessionManager&)), this, SLOT(onSaveState(QSessionManager&))); #if defined(USE_WEBENGINE) - connect(QWebEngineProfile::defaultProfile(), SIGNAL(downloadRequested(QWebEngineDownloadItem*)), - this, SLOT(downloadRequested(QWebEngineDownloadItem*))); + connect(QWebEngineProfile::defaultProfile(), &QWebEngineProfile::downloadRequested, + this, &Application::downloadRequested); #endif }