Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. fatal error C1060: compiler is out of heap space (again)

fatal error C1060: compiler is out of heap space (again)

Scheduled Pinned Locked Moved Solved General and Desktop
24 Posts 5 Posters 643 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • SprezzaturaS Sprezzatura

    I'm converting a project that compiles without error under Qt 5, to Qt 6. I'm getting the

    Compiler out of heap space
    

    error.
    I've researched the other posts about this error, and they don't fix the problem.
    I've added "/Zm2000" to the compiler options. No go.
    This error does not occur when compiling with Qt 5.
    It fails with VS 2019 and VS 2022, Qt 6.6, and Qt 6.9.
    There are no egregiously large .CPP files. The largest .CPP source file is 141KB or 4,412 lines.
    The .QRC file includes fifteen .PNG files totalling 176KB.
    I have 32GB of RAM.

    Any suggestions?

    Christian EhrlicherC Offline
    Christian EhrlicherC Offline
    Christian Ehrlicher
    Lifetime Qt Champion
    wrote last edited by
    #2

    @Sprezzatura said in fatal error C1060: compiler is out of heap space (again):

    Any suggestions?

    Use a 64bit compiler even when you compile for 32bits.

    Qt Online Installer direct download: https://download.qt.io/official_releases/online_installers/
    Visit the Qt Academy at https://academy.qt.io/catalog

    SprezzaturaS 1 Reply Last reply
    1
    • Christian EhrlicherC Christian Ehrlicher

      @Sprezzatura said in fatal error C1060: compiler is out of heap space (again):

      Any suggestions?

      Use a 64bit compiler even when you compile for 32bits.

      SprezzaturaS Offline
      SprezzaturaS Offline
      Sprezzatura
      wrote last edited by Sprezzatura
      #3

      @Christian-Ehrlicher I am using a 64-bit compiler. Compiling for 64-bit executable.

      Christian EhrlicherC 1 Reply Last reply
      0
      • SprezzaturaS Sprezzatura

        I'm converting a project that compiles without error under Qt 5, to Qt 6. I'm getting the

        Compiler out of heap space
        

        error.
        I've researched the other posts about this error, and they don't fix the problem.
        I've added "/Zm2000" to the compiler options. No go.
        This error does not occur when compiling with Qt 5.
        It fails with VS 2019 and VS 2022, Qt 6.6, and Qt 6.9.
        There are no egregiously large .CPP files. The largest .CPP source file is 141KB or 4,412 lines.
        The .QRC file includes fifteen .PNG files totalling 176KB.
        I have 32GB of RAM.

        Any suggestions?

        I Online
        I Online
        IgKh
        wrote last edited by
        #4

        @Sprezzatura said in fatal error C1060: compiler is out of heap space (again):

        There are no egregiously large .CPP files.

        During the compilation of which file does the error happen? Or does it happen during the link phase?

        SprezzaturaS 1 Reply Last reply
        0
        • I IgKh

          @Sprezzatura said in fatal error C1060: compiler is out of heap space (again):

          There are no egregiously large .CPP files.

          During the compilation of which file does the error happen? Or does it happen during the link phase?

          SprezzaturaS Offline
          SprezzaturaS Offline
          Sprezzatura
          wrote last edited by
          #5

          @IgKh said in fatal error C1060: compiler is out of heap space (again):

          During the compilation of which file does the error happen?

          Strangely, the error messages all point to Qt header files, which or course I have not altered or modified in any way:

          C:\Qt\6.9.0\msvc2022_64\include\QtCore/qabstracteventdispatcher.h(18): fatal error C1060: compiler is out of heap space
          C:\Qt\6.9.0\msvc2022_64\include\QtGui/qbrush.h(116): fatal error C1060: compiler is out of heap space
          C:\Qt\6.9.0\msvc2022_64\include\QtCore/qabstracteventdispatcher.h(18): fatal error C1060: compiler is out of heap space
          C:\Qt\6.9.0\msvc2022_64\include\QtWidgets/qwidget.h(717): fatal error C1060: compiler is out of heap space
          C:\Qt\6.9.0\msvc2022_64\include\QtCore/qhash.h(2699): fatal error C1060: compiler is out of heap space
          C:\Qt\6.9.0\msvc2022_64\include\QtCore/qvariant.h(333): fatal error C1060: compiler is out of heap space
          C:\Qt\6.9.0\msvc2022_64\include\QtWidgets/qabstractbutton.h(24): fatal error C1060: compiler is out of heap space
          C:\Qt\6.9.0\msvc2022_64\include\QtCore/qabstracteventdispatcher.h(18): fatal error C1060: compiler is out of heap space
          C:\Qt\6.9.0\msvc2022_64\include\QtCore/qdebug.h(703): fatal error C1060: compiler is out of heap space
          C:\Qt\6.9.0\msvc2022_64\include\QtCore/qdebug.h(507): fatal error C1060: compiler is out of heap space
          C:\Qt\6.9.0\msvc2022_64\include\QtCore/qttypetraits.h(29): fatal error C1060: compiler is out of heap space
          C:\Qt\6.9.0\msvc2022_64\include\QtCore/qdebug.h(320): fatal error C1060: compiler is out of heap space
          C:\Qt\6.9.0\msvc2022_64\include\QtCore/qdebug.h(602): fatal error C1060: compiler is out of heap space
          C:\Qt\6.9.0\msvc2022_64\include\QtCore/qdebug.h(320): fatal error C1060: compiler is out of heap space
          C:\Qt\6.9.0\msvc2022_64\include\QtCore/qbytearrayview.h(41): fatal error C1060: compiler is out of heap space
          C:\Qt\6.9.0\msvc2022_64\include\QtWidgets/qwidget.h(787): fatal error C1060: compiler is out of heap space
          C:\Qt\6.9.0\msvc2022_64\include\QtCore/qsharedpointer_impl.h(1060): fatal error C1060: compiler is out of heap space
          C:\Qt\6.9.0\msvc2022_64\include\QtCore/qhash.h(863): fatal error C1060: compiler is out of heap space
          C:\Qt\6.9.0\msvc2022_64\include\QtCore/qabstracteventdispatcher.h(18): fatal error C1060: compiler is out of heap space
          C:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\MSVC\14.43.34808\include\optional(94): fatal error C1060: compiler is out of heap space
          
          I 1 Reply Last reply
          0
          • SprezzaturaS Sprezzatura

            @IgKh said in fatal error C1060: compiler is out of heap space (again):

            During the compilation of which file does the error happen?

            Strangely, the error messages all point to Qt header files, which or course I have not altered or modified in any way:

            C:\Qt\6.9.0\msvc2022_64\include\QtCore/qabstracteventdispatcher.h(18): fatal error C1060: compiler is out of heap space
            C:\Qt\6.9.0\msvc2022_64\include\QtGui/qbrush.h(116): fatal error C1060: compiler is out of heap space
            C:\Qt\6.9.0\msvc2022_64\include\QtCore/qabstracteventdispatcher.h(18): fatal error C1060: compiler is out of heap space
            C:\Qt\6.9.0\msvc2022_64\include\QtWidgets/qwidget.h(717): fatal error C1060: compiler is out of heap space
            C:\Qt\6.9.0\msvc2022_64\include\QtCore/qhash.h(2699): fatal error C1060: compiler is out of heap space
            C:\Qt\6.9.0\msvc2022_64\include\QtCore/qvariant.h(333): fatal error C1060: compiler is out of heap space
            C:\Qt\6.9.0\msvc2022_64\include\QtWidgets/qabstractbutton.h(24): fatal error C1060: compiler is out of heap space
            C:\Qt\6.9.0\msvc2022_64\include\QtCore/qabstracteventdispatcher.h(18): fatal error C1060: compiler is out of heap space
            C:\Qt\6.9.0\msvc2022_64\include\QtCore/qdebug.h(703): fatal error C1060: compiler is out of heap space
            C:\Qt\6.9.0\msvc2022_64\include\QtCore/qdebug.h(507): fatal error C1060: compiler is out of heap space
            C:\Qt\6.9.0\msvc2022_64\include\QtCore/qttypetraits.h(29): fatal error C1060: compiler is out of heap space
            C:\Qt\6.9.0\msvc2022_64\include\QtCore/qdebug.h(320): fatal error C1060: compiler is out of heap space
            C:\Qt\6.9.0\msvc2022_64\include\QtCore/qdebug.h(602): fatal error C1060: compiler is out of heap space
            C:\Qt\6.9.0\msvc2022_64\include\QtCore/qdebug.h(320): fatal error C1060: compiler is out of heap space
            C:\Qt\6.9.0\msvc2022_64\include\QtCore/qbytearrayview.h(41): fatal error C1060: compiler is out of heap space
            C:\Qt\6.9.0\msvc2022_64\include\QtWidgets/qwidget.h(787): fatal error C1060: compiler is out of heap space
            C:\Qt\6.9.0\msvc2022_64\include\QtCore/qsharedpointer_impl.h(1060): fatal error C1060: compiler is out of heap space
            C:\Qt\6.9.0\msvc2022_64\include\QtCore/qhash.h(863): fatal error C1060: compiler is out of heap space
            C:\Qt\6.9.0\msvc2022_64\include\QtCore/qabstracteventdispatcher.h(18): fatal error C1060: compiler is out of heap space
            C:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\MSVC\14.43.34808\include\optional(94): fatal error C1060: compiler is out of heap space
            
            I Online
            I Online
            IgKh
            wrote last edited by
            #6

            @Sprezzatura That's not what I asked. I didn't ask which file the error message points to, but rather during the compilation of which of your project files does the error happen? In C++ each project source file is compiled separately as a different compilation unit, re-parsing the header files (unless using pch).

            Just post the entire build output if you don't know.

            SprezzaturaS 1 Reply Last reply
            0
            • I IgKh

              @Sprezzatura That's not what I asked. I didn't ask which file the error message points to, but rather during the compilation of which of your project files does the error happen? In C++ each project source file is compiled separately as a different compilation unit, re-parsing the header files (unless using pch).

              Just post the entire build output if you don't know.

              SprezzaturaS Offline
              SprezzaturaS Offline
              Sprezzatura
              wrote last edited by Sprezzatura
              #7

              @IgKh Sorry, it looks like the error arises when compiling the first 21 .CPP files. Then the next 7 .CPP don't have the error. Then I see:

              jom: C:\Progeny\CC_Qt\build\Desktop_Qt_6_9_0_MSVC2022_64bit-Debug\Makefile.Debug [debug\PG065.obj] Error 2
              jom: C:\Progeny\CC_Qt\build\Desktop_Qt_6_9_0_MSVC2022_64bit-Debug\Makefile.Debug [debug\PG013.obj] Error 2
              jom: C:\Progeny\CC_Qt\build\Desktop_Qt_6_9_0_MSVC2022_64bit-Debug\Makefile.Debug [debug\PG034.obj] Error 2
              jom: C:\Progeny\CC_Qt\build\Desktop_Qt_6_9_0_MSVC2022_64bit-Debug\Makefile.Debug [debug\PG_IOPL.obj] Error 2
              jom: C:\Progeny\CC_Qt\build\Desktop_Qt_6_9_0_MSVC2022_64bit-Debug\Makefile.Debug [debug\PG021.obj] Error 2
              jom: C:\Progeny\CC_Qt\build\Desktop_Qt_6_9_0_MSVC2022_64bit-Debug\Makefile.Debug [debug\PG028.obj] Error 2
              jom: C:\Progeny\CC_Qt\build\Desktop_Qt_6_9_0_MSVC2022_64bit-Debug\Makefile.Debug [debug\PG030.obj] Error 2
              jom: C:\Progeny\CC_Qt\build\Desktop_Qt_6_9_0_MSVC2022_64bit-Debug\Makefile.Debug [debug\PG031.obj] Error 2
              jom: C:\Progeny\CC_Qt\build\Desktop_Qt_6_9_0_MSVC2022_64bit-Debug\Makefile.Debug [debug\PG059.obj] Error 2
              jom: C:\Progeny\CC_Qt\build\Desktop_Qt_6_9_0_MSVC2022_64bit-Debug\Makefile.Debug [debug\PG078.obj] Error 2
              jom: C:\Progeny\CC_Qt\build\Desktop_Qt_6_9_0_MSVC2022_64bit-Debug\Makefile.Debug [debug\PG093.obj] Error 2
              jom: C:\Progeny\CC_Qt\build\Desktop_Qt_6_9_0_MSVC2022_64bit-Debug\Makefile.Debug [debug\PG093B.obj] Error 2
              jom: C:\Progeny\CC_Qt\build\Desktop_Qt_6_9_0_MSVC2022_64bit-Debug\Makefile.Debug [debug\PG093C.obj] Error 2
              jom: C:\Progeny\CC_Qt\build\Desktop_Qt_6_9_0_MSVC2022_64bit-Debug\Makefile.Debug [debug\PG096.obj] Error 2
              jom: C:\Progeny\CC_Qt\build\Desktop_Qt_6_9_0_MSVC2022_64bit-Debug\Makefile.Debug [debug\PG096W.obj] Error 2
              jom: C:\Progeny\CC_Qt\build\Desktop_Qt_6_9_0_MSVC2022_64bit-Debug\Makefile.Debug [debug\PG106.obj] Error 2
              jom: C:\Progeny\CC_Qt\build\Desktop_Qt_6_9_0_MSVC2022_64bit-Debug\Makefile.Debug [debug\PG121.obj] Error 2
              jom: C:\Progeny\CC_Qt\build\Desktop_Qt_6_9_0_MSVC2022_64bit-Debug\Makefile.Debug [debug\PG125.obj] Error 2
              jom: C:\Progeny\CC_Qt\build\Desktop_Qt_6_9_0_MSVC2022_64bit-Debug\Makefile.Debug [debug\PG129.obj] Error 2
              jom: C:\Progeny\CC_Qt\build\Desktop_Qt_6_9_0_MSVC2022_64bit-Debug\Makefile.Debug [debug\PG131.obj] Error 2
              jom: C:\Progeny\CC_Qt\build\Desktop_Qt_6_9_0_MSVC2022_64bit-Debug\Makefile [debug] Error 2
              

              Here's a typical error message:

              PG065.CPP
              C:\Qt\6.9.0\msvc2022_64\include\QtCore/qabstracteventdispatcher.h(18): fatal error C1060: compiler is out of heap space
              	cl -c -nologo -Zc:wchar_t -FS -std:c++17 -Zc:__cplusplus -permissive- /Zm2000 -Zi -MDd -utf-8 -W0 /Fddebug\CC9.vc.pdb -DUNICODE -D_UNICODE -DWIN32 -D_ENABLE_EXTENDED_ALIGNED_STORAGE -DWIN64 -DCC_MATE -DQT_WIDGETS_LIB -DQT_HELP_LIB -DQT_PRINTSUPPORT_LIB -DQT_UITOOLS_LIB -DS4STAND_ALONE -DVERSION_MAJOR=9 -DVERSION_MINOR=0 -DVERSION_BUILD=7 -D_CRT_SECURE_NO_WARNINGS -DWIN32 -DS4WIN32 -D_MBCS -DS4FOX -DQT_QML_DEBUG -DQT_HELP_LIB -DQT_UITOOLS_LIB -DQT_OPENGLWIDGETS_LIB -DQT_PRINTSUPPORT_LIB -DQT_WIDGETS_LIB -DQT_OPENGL_LIB -DQT_GUI_LIB -DQT_SQL_LIB -DQT_NETWORK_LIB -DQT_XML_LIB -DQT_CORE_LIB -Fodebug\PG_IOPL.obj C:\---\sandbox\CodeBase6\PG_IOPL.CPP
              
              1 Reply Last reply
              0
              • hskoglundH Online
                hskoglundH Online
                hskoglund
                wrote last edited by
                #8

                If you compile in release mode, do you still get the same compiler error?
                (Also, when compiling in debug mode, try removing that -FS option.)

                SprezzaturaS 1 Reply Last reply
                0
                • SprezzaturaS Sprezzatura

                  @Christian-Ehrlicher I am using a 64-bit compiler. Compiling for 64-bit executable.

                  Christian EhrlicherC Offline
                  Christian EhrlicherC Offline
                  Christian Ehrlicher
                  Lifetime Qt Champion
                  wrote last edited by
                  #9

                  @Sprezzatura said in fatal error C1060: compiler is out of heap space (again):

                  I am using a 64-bit compiler. Compiling for 64-bit executable.

                  Then you will not get this error.
                  What does 'where cl' prints out?

                  Qt Online Installer direct download: https://download.qt.io/official_releases/online_installers/
                  Visit the Qt Academy at https://academy.qt.io/catalog

                  SprezzaturaS 3 Replies Last reply
                  1
                  • hskoglundH hskoglund

                    If you compile in release mode, do you still get the same compiler error?
                    (Also, when compiling in debug mode, try removing that -FS option.)

                    SprezzaturaS Offline
                    SprezzaturaS Offline
                    Sprezzatura
                    wrote last edited by
                    #10

                    @hskoglund I get the same errors in Release mode.

                    The "/FS" is generated by Qt, not sure how to suppress it.
                    "/FS-"?

                    1 Reply Last reply
                    0
                    • Christian EhrlicherC Christian Ehrlicher

                      @Sprezzatura said in fatal error C1060: compiler is out of heap space (again):

                      I am using a 64-bit compiler. Compiling for 64-bit executable.

                      Then you will not get this error.
                      What does 'where cl' prints out?

                      SprezzaturaS Offline
                      SprezzaturaS Offline
                      Sprezzatura
                      wrote last edited by Sprezzatura
                      #11

                      @Christian-Ehrlicher Not sure where to enter "where cl". The Terminal Window returns:

                      INFO: Could not find files for the given pattern(s)
                      

                      The compiler I am using, according to the "Manake Kits" section, is:

                      Microsoft Visual C++ Compiler 17.12.35527.113 (amd64)

                      Not (x86), not (amd64_x86), not (x86_amd64), nor anything containing "arm".

                      To reiterate, it compiles successfully under Qt 5.15 + VS 2019.

                      BTW thank you for your help and patience :o)

                      1 Reply Last reply
                      0
                      • Christian EhrlicherC Christian Ehrlicher

                        @Sprezzatura said in fatal error C1060: compiler is out of heap space (again):

                        I am using a 64-bit compiler. Compiling for 64-bit executable.

                        Then you will not get this error.
                        What does 'where cl' prints out?

                        SprezzaturaS Offline
                        SprezzaturaS Offline
                        Sprezzatura
                        wrote last edited by
                        #12

                        @Christian-Ehrlicher Here's the output from "vswhere":

                        instanceId: 1b580a97
                        installDate: 12 Apr 2025 9:53:45 AM
                        installationName: VisualStudio/15.9.78+36631.12
                        installationPath: C:\Program Files (x86)\Microsoft Visual Studio\2017\Professional
                        installationVersion: 15.9.36631.12
                        productId: Microsoft.VisualStudio.Product.Professional
                        productPath: C:\Program Files (x86)\Microsoft Visual Studio\2017\Professional\Common7\IDE\devenv.exe
                        state: 7
                        isComplete: 0
                        isLaunchable: 1
                        isPrerelease: 0
                        isRebootRequired: 0
                        displayName: Visual Studio Professional 2017
                        description: Professional developer tools and services for small teams
                        channelId: VisualStudio.15.Release
                        channelUri: https://aka.ms/vs/15/release/channel
                        enginePath: C:\Program Files (x86)\Microsoft Visual Studio\Installer\resources\app\ServiceHub\Services\Microsoft.VisualStudio.Setup.Service
                        installChannelUri: https://aka.ms/vs/15/release/0e24fba09_-593026118/channel
                        installedChannelId: VisualStudio.15.Release
                        installedChannelUri: https://aka.ms/vs/15/release/channel
                        releaseNotes: https://go.microsoft.com/fwlink/?LinkId=660692#15.9.78
                        resolvedInstallationPath: C:\Program Files (x86)\Microsoft Visual Studio\2017\Professional
                        thirdPartyNotices: https://go.microsoft.com/fwlink/?LinkId=660708
                        updateDate: 2026-01-07T12:09:16.4473894Z
                        catalog_buildBranch: d15.9
                        catalog_buildVersion: 15.9.36631.12
                        catalog_id: VisualStudio/15.9.78+36631.12
                        catalog_localBuild: build-lab
                        catalog_manifestName: VisualStudio
                        catalog_manifestType: installer
                        catalog_productDisplayVersion: 15.9.78
                        catalog_productLine: Dev15
                        catalog_productLineVersion: 2017
                        catalog_productMilestone: RTW
                        catalog_productMilestoneIsPreRelease: False
                        catalog_productName: Visual Studio
                        catalog_productPatchVersion: 78
                        catalog_productPreReleaseMilestoneSuffix: 1.0
                        catalog_productRelease: RTW
                        catalog_productSemanticVersion: 15.9.78+36631.12
                        catalog_requiredEngineVersion: 1.18.1063.29791
                        properties_appLocalWPF: false
                        properties_campaignId:
                        properties_channelManifestId: VisualStudio.15.Release/15.9.78+36631.12
                        properties_includeRecommended: 0
                        properties_nickname:
                        properties_setupEngineFilePath: C:\Program Files (x86)\Microsoft Visual Studio\Installer\setup.exe
                        
                        instanceId: 6e3ad4c1
                        installDate: 15 Dec 2024 11:42:02 AM
                        installationName: VisualStudio/16.11.42+35425.106
                        installationPath: C:\Program Files (x86)\Microsoft Visual Studio\2019\Community
                        installationVersion: 16.11.35425.106
                        productId: Microsoft.VisualStudio.Product.Community
                        productPath: C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\Common7\IDE\devenv.exe
                        state: 4294967295
                        isComplete: 1
                        isLaunchable: 1
                        isPrerelease: 0
                        isRebootRequired: 0
                        displayName: Visual Studio Community 2019
                        description: Powerful IDE, free for students, open-source contributors, and individuals
                        channelId: VisualStudio.16.Release
                        channelUri: https://aka.ms/vs/16/release/channel
                        enginePath: C:\Program Files (x86)\Microsoft Visual Studio\Installer\resources\app\ServiceHub\Services\Microsoft.VisualStudio.Setup.Service
                        installedChannelId: VisualStudio.16.Release
                        installedChannelUri: https://aka.ms/vs/16/release/channel
                        releaseNotes: https://docs.microsoft.com/en-us/visualstudio/releases/2019/release-notes-v16.11#16.11.42
                        resolvedInstallationPath: C:\Program Files (x86)\Microsoft Visual Studio\2019\Community
                        thirdPartyNotices: https://go.microsoft.com/fwlink/?LinkId=660909
                        updateDate: 2024-12-15T15:42:02.8085868Z
                        catalog_buildBranch: d16.11
                        catalog_buildVersion: 16.11.35425.106
                        catalog_id: VisualStudio/16.11.42+35425.106
                        catalog_localBuild: build-lab
                        catalog_manifestName: VisualStudio
                        catalog_manifestType: installer
                        catalog_productDisplayVersion: 16.11.42
                        catalog_productLine: Dev16
                        catalog_productLineVersion: 2019
                        catalog_productMilestone: RTW
                        catalog_productMilestoneIsPreRelease: False
                        catalog_productName: Visual Studio
                        catalog_productPatchVersion: 42
                        catalog_productPreReleaseMilestoneSuffix: 1.0
                        catalog_productSemanticVersion: 16.11.42+35425.106
                        catalog_requiredEngineVersion: 2.11.72.18200
                        properties_campaignId:
                        properties_channelManifestId: VisualStudio.16.Release/16.11.42+35425.106
                        properties_includeRecommended: 0
                        properties_nickname:
                        properties_setupEngineFilePath: C:\Program Files (x86)\Microsoft Visual Studio\Installer\setup.exe
                        
                        instanceId: a3aac630
                        installDate: 03 Jul 2024 6:57:14 PM
                        installationName: VisualStudio/17.13.6+35931.197
                        installationPath: C:\Program Files\Microsoft Visual Studio\2022\Community
                        installationVersion: 17.13.35931.197
                        productId: Microsoft.VisualStudio.Product.Community
                        productPath: C:\Program Files\Microsoft Visual Studio\2022\Community\Common7\IDE\devenv.exe
                        state: 4294967295
                        isComplete: 1
                        isLaunchable: 1
                        isPrerelease: 0
                        isRebootRequired: 0
                        displayName: Visual Studio Community 2022
                        description: Powerful IDE, free for students, open-source contributors, and individuals
                        channelId: VisualStudio.17.Release
                        channelUri: https://aka.ms/vs/17/release/channel
                        enginePath: C:\Program Files (x86)\Microsoft Visual Studio\Installer\resources\app\ServiceHub\Services\Microsoft.VisualStudio.Setup.Service
                        installedChannelId: VisualStudio.17.Release
                        installedChannelUri: https://aka.ms/vs/17/release/channel
                        releaseNotes: https://docs.microsoft.com/en-us/visualstudio/releases/2022/release-notes-v17.13#17.13.6
                        resolvedInstallationPath: C:\Program Files\Microsoft Visual Studio\2022\Community
                        thirdPartyNotices: https://go.microsoft.com/fwlink/?LinkId=661288
                        updateDate: 2025-04-10T19:20:01.9041268Z
                        catalog_buildBranch: d17.13
                        catalog_buildVersion: 17.13.35931.197
                        catalog_id: VisualStudio/17.13.6+35931.197
                        catalog_localBuild: build-lab
                        catalog_manifestName: VisualStudio
                        catalog_manifestType: installer
                        catalog_productDisplayVersion: 17.13.6
                        catalog_productLine: Dev17
                        catalog_productLineVersion: 2022
                        catalog_productMilestone: RTW
                        catalog_productMilestoneIsPreRelease: False
                        catalog_productName: Visual Studio
                        catalog_productPatchVersion: 6
                        catalog_productPreReleaseMilestoneSuffix: 1.0
                        catalog_productSemanticVersion: 17.13.6+35931.197
                        catalog_requiredEngineVersion: 3.13.2069.59209
                        properties_campaignId: 3650:2f3f9e4bc13b4b84bacc669e2109a308
                        properties_channelManifestId: VisualStudio.17.Release/17.13.6+35931.197
                        properties_includeRecommended: 1
                        properties_nickname:
                        properties_setupEngineFilePath: C:\Program Files (x86)\Microsoft Visual Studio\Installer\setup.exe
                        
                        instanceId: bd038e2e
                        installDate: 12 Apr 2025 11:50:29 AM
                        installationName: VisualStudio/15.9.78+36631.12
                        installationPath: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community
                        installationVersion: 15.9.36631.12
                        productId: Microsoft.VisualStudio.Product.Community
                        productPath: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\Common7\IDE\devenv.exe
                        state: 4294967295
                        isComplete: 1
                        isLaunchable: 1
                        isPrerelease: 0
                        isRebootRequired: 0
                        displayName: Visual Studio Community 2017
                        description: Free, fully-featured IDE for students, open-source and individual developers
                        channelId: VisualStudio.15.Release
                        channelUri: https://aka.ms/vs/15/release/channel
                        enginePath: C:\Program Files (x86)\Microsoft Visual Studio\Installer\resources\app\ServiceHub\Services\Microsoft.VisualStudio.Setup.Service
                        installedChannelId: VisualStudio.15.Release
                        installedChannelUri: https://aka.ms/vs/15/release/channel
                        releaseNotes: https://go.microsoft.com/fwlink/?LinkId=660692#15.9.78
                        resolvedInstallationPath: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community
                        thirdPartyNotices: https://go.microsoft.com/fwlink/?LinkId=660708
                        updateDate: 2026-01-05T21:23:36.7680071Z
                        catalog_buildBranch: d15.9
                        catalog_buildVersion: 15.9.36631.12
                        catalog_id: VisualStudio/15.9.78+36631.12
                        catalog_localBuild: build-lab
                        catalog_manifestName: VisualStudio
                        catalog_manifestType: installer
                        catalog_productDisplayVersion: 15.9.78
                        catalog_productLine: Dev15
                        catalog_productLineVersion: 2017
                        catalog_productMilestone: RTW
                        catalog_productMilestoneIsPreRelease: False
                        catalog_productName: Visual Studio
                        catalog_productPatchVersion: 78
                        catalog_productPreReleaseMilestoneSuffix: 1.0
                        catalog_productRelease: RTW
                        catalog_productSemanticVersion: 15.9.78+36631.12
                        catalog_requiredEngineVersion: 1.18.1063.29791
                        properties_appLocalWPF: false
                        properties_campaignId:
                        properties_channelManifestId: VisualStudio.15.Release/15.9.78+36631.12
                        properties_includeRecommended: 0
                        properties_nickname: 2
                        properties_setupEngineFilePath: C:\Program Files (x86)\Microsoft Visual Studio\Installer\setup.exe
                        
                        1 Reply Last reply
                        0
                        • Christian EhrlicherC Christian Ehrlicher

                          @Sprezzatura said in fatal error C1060: compiler is out of heap space (again):

                          I am using a 64-bit compiler. Compiling for 64-bit executable.

                          Then you will not get this error.
                          What does 'where cl' prints out?

                          SprezzaturaS Offline
                          SprezzaturaS Offline
                          Sprezzatura
                          wrote last edited by
                          #13
                          This post is deleted!
                          1 Reply Last reply
                          0
                          • Christian EhrlicherC Offline
                            Christian EhrlicherC Offline
                            Christian Ehrlicher
                            Lifetime Qt Champion
                            wrote last edited by
                            #14

                            Sorry I meant where cl.exe

                            Qt Online Installer direct download: https://download.qt.io/official_releases/online_installers/
                            Visit the Qt Academy at https://academy.qt.io/catalog

                            SprezzaturaS 2 Replies Last reply
                            0
                            • Christian EhrlicherC Christian Ehrlicher

                              Sorry I meant where cl.exe

                              SprezzaturaS Offline
                              SprezzaturaS Offline
                              Sprezzatura
                              wrote last edited by
                              #15

                              @Christian-Ehrlicher

                              where cl.exe
                              INFO: Could not find files for the given pattern(s).
                              
                              1 Reply Last reply
                              0
                              • Christian EhrlicherC Christian Ehrlicher

                                Sorry I meant where cl.exe

                                SprezzaturaS Offline
                                SprezzaturaS Offline
                                Sprezzatura
                                wrote last edited by
                                #16

                                @Christian-Ehrlicher I've found the culprit. If I include the following in the .PRO file:

                                QMAKE_CFLAGS += -Zc:__cplusplus
                                QMAKE_CFLAGS += -permissive-
                                

                                It compiles successfully with Qt 5.15
                                However, when I include this to the .PRO file:

                                QMAKE_CFLAGS += -std:c++17
                                QMAKE_CFLAGS += -Zc:__cplusplus
                                QMAKE_CFLAGS += -permissive-
                                

                                even Qt 5.15 fails with the "Out of Heap Space" error.
                                If I remove this line and try to compile with Qt 6.9, I get:

                                QMAKE_CFLAGS += -std:c++17

                                "Qt requires a C++17 compiler, and a suitable value for __cplusplus. On MSVC, you must pass the /Zc:__cplusplus option to the compiler"
                                

                                Why would this option cause the Out of Heap Space error? Are there other options I need to add?

                                1 Reply Last reply
                                0
                                • Christian EhrlicherC Offline
                                  Christian EhrlicherC Offline
                                  Christian Ehrlicher
                                  Lifetime Qt Champion
                                  wrote last edited by Christian Ehrlicher
                                  #17

                                  You have to call it in the console where you build you Qt... you are using a 32bit compiler.

                                  λ where cl
                                  C:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\MSVC\14.44.35207\bin\Hostx64\x64\cl.exe
                                  

                                  Qt Online Installer direct download: https://download.qt.io/official_releases/online_installers/
                                  Visit the Qt Academy at https://academy.qt.io/catalog

                                  SprezzaturaS 1 Reply Last reply
                                  0
                                  • Christian EhrlicherC Christian Ehrlicher

                                    You have to call it in the console where you build you Qt... you are using a 32bit compiler.

                                    λ where cl
                                    C:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\MSVC\14.44.35207\bin\Hostx64\x64\cl.exe
                                    
                                    SprezzaturaS Offline
                                    SprezzaturaS Offline
                                    Sprezzatura
                                    wrote last edited by Sprezzatura
                                    #18

                                    @Christian-Ehrlicher
                                    [1] Here's what is displayed in the Compile Output window when I delete the "-nologo" option:

                                    Microsoft (R) C/C++ Optimizing Compiler Version 19.43.34810 for x64
                                    Copyright (C) Microsoft Corporation.  All rights reserved.
                                    

                                    Note the "x64".

                                    [2] My .PRO file contains:

                                    contains(QT_ARCH, i386) {
                                        message("32-bit" $$QT_ARCH $$QT_VERSION)
                                    }
                                    contains(QT_ARCH, x86_64) {
                                        message("64-bit" $$QT_ARCH $$QT_VERSION)
                                    }
                                    

                                    This is displayed in the Compile Output window:

                                    Project MESSAGE: 64-bit x86_64 6.9.0
                                    

                                    [3] I tried creating a new Kit and adding a 32-bit compiler. Qt flat out rejected it.

                                    [4] What does the "λ" lambda mean in your example?
                                    When you say "the console where you build your Qt", do you mean the Terminal window in Qt Creator?
                                    When I do that, I get:

                                    >where cl
                                    INFO: Could not find files for the given pattern(s).
                                    

                                    I'm using Windows.

                                    Christian EhrlicherC 1 Reply Last reply
                                    0
                                    • SprezzaturaS Sprezzatura

                                      @Christian-Ehrlicher
                                      [1] Here's what is displayed in the Compile Output window when I delete the "-nologo" option:

                                      Microsoft (R) C/C++ Optimizing Compiler Version 19.43.34810 for x64
                                      Copyright (C) Microsoft Corporation.  All rights reserved.
                                      

                                      Note the "x64".

                                      [2] My .PRO file contains:

                                      contains(QT_ARCH, i386) {
                                          message("32-bit" $$QT_ARCH $$QT_VERSION)
                                      }
                                      contains(QT_ARCH, x86_64) {
                                          message("64-bit" $$QT_ARCH $$QT_VERSION)
                                      }
                                      

                                      This is displayed in the Compile Output window:

                                      Project MESSAGE: 64-bit x86_64 6.9.0
                                      

                                      [3] I tried creating a new Kit and adding a 32-bit compiler. Qt flat out rejected it.

                                      [4] What does the "λ" lambda mean in your example?
                                      When you say "the console where you build your Qt", do you mean the Terminal window in Qt Creator?
                                      When I do that, I get:

                                      >where cl
                                      INFO: Could not find files for the given pattern(s).
                                      

                                      I'm using Windows.

                                      Christian EhrlicherC Offline
                                      Christian EhrlicherC Offline
                                      Christian Ehrlicher
                                      Lifetime Qt Champion
                                      wrote last edited by
                                      #19

                                      @Sprezzatura said in fatal error C1060: compiler is out of heap space (again):

                                      where cl
                                      INFO: Could not find files for the given pattern(s).

                                      Again: execute this on the command line where you also compiled your Qt. Execatly where you did 'cl -nologo'
                                      You are using a 32bit compiler which creates 64 bit executables. Or you have very low ram on your system which I doubt.

                                      Qt Online Installer direct download: https://download.qt.io/official_releases/online_installers/
                                      Visit the Qt Academy at https://academy.qt.io/catalog

                                      SprezzaturaS 2 Replies Last reply
                                      0
                                      • hskoglundH Online
                                        hskoglundH Online
                                        hskoglund
                                        wrote last edited by
                                        #20

                                        In my VS2002 installation there are 4 different cl.exe versions:
                                        c:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\MSVC\14.43.34808\bin\Hostx86\x86\cl.exe
                                        c:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\MSVC\14.43.34808\bin\Hostx86\x64\cl.exe
                                        c:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\MSVC\14.43.34808\bin\Hostx64\x86\cl.exe
                                        c:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\MSVC\14.43.34808\bin\Hostx64\x64\cl.exe

                                        Two of them (the ..\Hostx86\x64\cl.exe and the ..\Hostx64\x64\cl.exe will show the same output:
                                        "Microsoft (R) C/C++ Optimizing Compiler Version 19.43.34810 for x64" and both will compile and build 64 bit ..exe files for Qt6.

                                        So you have a 50% chance of running the correct compiler, i.e. the cl.exe in the subdirectory ..\Hostx64\x64

                                        1 Reply Last reply
                                        2
                                        • Christian EhrlicherC Christian Ehrlicher

                                          @Sprezzatura said in fatal error C1060: compiler is out of heap space (again):

                                          where cl
                                          INFO: Could not find files for the given pattern(s).

                                          Again: execute this on the command line where you also compiled your Qt. Execatly where you did 'cl -nologo'
                                          You are using a 32bit compiler which creates 64 bit executables. Or you have very low ram on your system which I doubt.

                                          SprezzaturaS Offline
                                          SprezzaturaS Offline
                                          Sprezzatura
                                          wrote last edited by
                                          #21

                                          @Christian-Ehrlicher I'm not launching this from the command line. I'm using Qt Creator, which automatically creates a stream of commands, including launching cl.exe, followed by a ton of parameters.
                                          The output appears in the "Compile Output" window of the Qt Creator IDE.

                                          1 Reply Last reply
                                          0

                                          • Login

                                          • Login or register to search.
                                          • First post
                                            Last post
                                          0
                                          • Categories
                                          • Recent
                                          • Tags
                                          • Popular
                                          • Users
                                          • Groups
                                          • Search
                                          • Get Qt Extensions
                                          • Unsolved