diff --git a/src/app/app.pro b/src/app/app.pro index 58dca7ba050..1414e7d7fca 100644 --- a/src/app/app.pro +++ b/src/app/app.pro @@ -20,6 +20,12 @@ QT_BREAKPAD_ROOT_PATH = $$(QT_BREAKPAD_ROOT_PATH) include($$QT_BREAKPAD_ROOT_PATH/qtbreakpad.pri) } win32 { + # We need the version in two separate formats for the .rc file + # RC_VERSION=4,3,82,0 (quadruple) + # RC_VERSION_STRING="4.4.0-beta1" (free text) + DEFINES += RC_VERSION=$$replace(QTCREATOR_VERSION, "\\.", ","),0 \ + RC_VERSION_STRING=\\\"$${QTCREATOR_DISPLAY_VERSION}\\\" \ + RC_COPYRIGHT='"\\\"2008-$${QTCREATOR_COPYRIGHT_YEAR} The Qt Company Ltd\\\""' RC_FILE = qtcreator.rc } else:macx { LIBS += -framework CoreFoundation diff --git a/src/app/app.qbs b/src/app/app.qbs index 0af41ca20d9..b3023fcbe74 100644 --- a/src/app/app.qbs +++ b/src/app/app.qbs @@ -41,7 +41,6 @@ QtcProduct { "Info.plist", "main.cpp", "qtcreator.xcassets", - "qtcreator.rc", "../shared/qtsingleapplication/qtsingleapplication.h", "../shared/qtsingleapplication/qtsingleapplication.cpp", "../shared/qtsingleapplication/qtlocalpeer.h", @@ -51,6 +50,16 @@ QtcProduct { "../tools/qtcreatorcrashhandler/crashhandlersetup.h" ] + Group { + // We need the version in two separate formats for the .rc file + // RC_VERSION=4,3,82,0 (quadruple) + // RC_VERSION_STRING="4.4.0-beta1" (free text) + cpp.defines: outer.concat(["RC_VERSION=" + qtc.qtcreator_version.replace(/\./g, ",") + ",0", + "RC_VERSION_STRING=\"" + qtc.qtcreator_display_version + "\"", + "RC_COPYRIGHT=\"2008-" + qtc.qtcreator_copyright_year + " The Qt Company Ltd\""]) + files: "qtcreator.rc" + } + Group { name: "qtcreator.sh" condition: qbs.targetOS.contains("unix") && !qbs.targetOS.contains("macos") diff --git a/src/app/qtcreator.rc b/src/app/qtcreator.rc index b23a85f3222..89f03c4708c 100644 --- a/src/app/qtcreator.rc +++ b/src/app/qtcreator.rc @@ -1,3 +1,5 @@ +#include + IDI_ICON1 ICON DISCARDABLE "qtcreator.ico" IDI_ICON2 ICON DISCARDABLE "winicons/c.ico" IDI_ICON3 ICON DISCARDABLE "winicons/cpp.ico" @@ -6,3 +8,25 @@ IDI_ICON5 ICON DISCARDABLE "winicons/ui.ico" IDI_ICON6 ICON DISCARDABLE "winicons/pro.ico" IDI_ICON7 ICON DISCARDABLE "winicons/pri.ico" IDI_ICON8 ICON DISCARDABLE "winicons/qml.ico" + +VS_VERSION_INFO VERSIONINFO + FILEVERSION RC_VERSION + PRODUCTVERSION RC_VERSION +{ + BLOCK "StringFileInfo" + { + // U.S. English - Windows, Multilingual + BLOCK "040904E4" + { + VALUE "FileDescription", "Qt Creator" + VALUE "FileVersion", RC_VERSION_STRING + VALUE "ProductName", "Qt Creator" + VALUE "ProductVersion", RC_VERSION_STRING + VALUE "LegalCopyright", RC_COPYRIGHT + } + } + BLOCK "VarFileInfo" + { + VALUE "Translation", 0x409, 1252 // 1252 = 0x04E4 + } +}