Uploaded image for project: 'Qt Visual Studio Tools'
  1. Qt Visual Studio Tools

"New Project" wizard is not creating configuration properties correctly



    • Type: Bug
    • Status: Open
    • Priority: P3: Somewhat important
    • Resolution: Unresolved
    • Affects Version/s: 2.5.2
    • Fix Version/s: None
    • Component/s: Qt/MSBuild
    • Labels:
    • Environment:
      Visual Studio 2017
    • Platform/s:


      When creating a new (non Qt) project using the stock Visual Studio project wizard, it sets up a block of properties for every build configuration in the .vcxproj, for example:

      <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
      <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">

      When using the Qt project wizard provided by the Qt VS Tools, it only sets up a subset of these properties:

      <PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Debug|Win32'" Label="Configuration">
      <PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Release|Win32'" Label="Configuration">

      Note that "UseDebugLibraries", "CharacterSet" and "WholeProgramOptimization" are missing.

      This causes various issues:

      • "UseDebugLibraries" is used by VS to switch between Debug and Release Runtime Library and Optimization Settings, which doesn't work without this property. The Qt VS Tools work around this issue by explicitly specifying all the individual build settings like "RuntimeLibrary", "Optimization", "DebugInformationFormat", etc.. (which don't match the VS defaults in all cases). It would be much better to just use the default VS behavior by setting "UseDebugLibraries"
      • "WholeProgramOptimization" enables Link Time Code Generation for Release Builds. Because this property is missing for Qt projects, LTCG is disabled.
      • "CharacterSet" explicitly defines the Windows character set. Not so much of an issue for Qt projects.

      These inconsistencies cause various issues when maintaining a large code base with various Qt and non-Qt projects, because every Qt projects differs from all the other non-Qt projects and need to be adjusted manually.

      In conclusion: Qt VS Tools should set all the configuration properties just like the VS built-in project wizards do. On the other end, the Qt Wizard should NOT set all the individual, hand-crafted build properties (RuntimeLibrary, DebugInformationFormat, ...)  that are currently set to work-around the issue (and conflict with the VS defaults provided by Microsoft property sheets).


        No reviews matched the request. Check your Options in the drop-down menu of this sections header.



            mecfc Miguel Costa
            fgross Florian Groß
            0 Vote for this issue
            2 Start watching this issue



                Gerrit Reviews

                There are no open Gerrit changes