From b243a8d728491b8375e94407756640c9d9f931b4 Mon Sep 17 00:00:00 2001 From: Christian Kandeler Date: Thu, 3 Feb 2022 12:18:09 +0100 Subject: [PATCH] Wizards: Modernize qbs project templates Change-Id: Ib6f6315f9730425d4fd3b566f66ed26aa1718695 Reviewed-by: Reviewed-by: Christian Stenger --- .../templates/wizards/projects/consoleapp/file.qbs | 9 +-------- .../qtcreator/templates/wizards/projects/plainc/file.qbs | 7 +------ .../templates/wizards/projects/plaincpp/file.qbs | 7 +------ .../wizards/projects/qtquickapplication/app.qbs | 7 ++----- 4 files changed, 5 insertions(+), 25 deletions(-) diff --git a/share/qtcreator/templates/wizards/projects/consoleapp/file.qbs b/share/qtcreator/templates/wizards/projects/consoleapp/file.qbs index 35ce99c77ac..6406f0cb013 100644 --- a/share/qtcreator/templates/wizards/projects/consoleapp/file.qbs +++ b/share/qtcreator/templates/wizards/projects/consoleapp/file.qbs @@ -1,8 +1,6 @@ import qbs QtApplication { - cpp.cxxLanguageVersion: "c++11" - cpp.defines: [ // You can make your code fail to compile if it uses deprecated APIs. // In order to do so, uncomment the following line. @@ -10,6 +8,7 @@ QtApplication { ] consoleApplication: true + install: true files: [ "%{CppFileName}", @if %{HasTranslation} @@ -24,10 +23,4 @@ QtApplication { fileTags: "qt.core.resource_data" } @endif - - Group { // Properties for the produced executable - fileTagsFilter: "application" - qbs.install: true - qbs.installDir: "bin" - } } diff --git a/share/qtcreator/templates/wizards/projects/plainc/file.qbs b/share/qtcreator/templates/wizards/projects/plainc/file.qbs index a2bd3fb9439..0e9eb0288db 100644 --- a/share/qtcreator/templates/wizards/projects/plainc/file.qbs +++ b/share/qtcreator/templates/wizards/projects/plainc/file.qbs @@ -2,11 +2,6 @@ import qbs CppApplication { consoleApplication: true + install: true files: "%{CFileName}" - - Group { // Properties for the produced executable - fileTagsFilter: "application" - qbs.install: true - qbs.installDir: "bin" - } } diff --git a/share/qtcreator/templates/wizards/projects/plaincpp/file.qbs b/share/qtcreator/templates/wizards/projects/plaincpp/file.qbs index b07ba3fd424..6ce956cc6ee 100644 --- a/share/qtcreator/templates/wizards/projects/plaincpp/file.qbs +++ b/share/qtcreator/templates/wizards/projects/plaincpp/file.qbs @@ -2,11 +2,6 @@ import qbs CppApplication { consoleApplication: true + install: true files: "%{CppFileName}" - - Group { // Properties for the produced executable - fileTagsFilter: "application" - qbs.install: true - qbs.installDir: "bin" - } } diff --git a/share/qtcreator/templates/wizards/projects/qtquickapplication/app.qbs b/share/qtcreator/templates/wizards/projects/qtquickapplication/app.qbs index 31320cad6a9..14025b37b82 100644 --- a/share/qtcreator/templates/wizards/projects/qtquickapplication/app.qbs +++ b/share/qtcreator/templates/wizards/projects/qtquickapplication/app.qbs @@ -7,6 +7,8 @@ CppApplication { Depends { name: "Qt.quick" } @endif + install: true + // Additional import path used to resolve QML modules in Qt Creator's code model property pathList qmlImportPaths: [] @if !%{IsQt6} @@ -43,9 +45,4 @@ CppApplication { fileTags: ["qt.qml.qml", "qt.core.resource_data"] } @endif - Group { // Properties for the produced executable - fileTagsFilter: "application" - qbs.install: true - qbs.installDir: "bin" - } }