Qt Forum

    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Unsolved

    Update: Forum Guidelines & Code of Conduct

    Error when compiling Application in Release mode with MinGW Compiler (out of memory allocating 20479 bytes)

    Installation and Deployment
    2
    4
    2429
    Loading More Posts
    • 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.
    • Z
      Zain last edited by

      Hello all,

      When I am trying to compile my desktop application in release mode using MinGW getting the only error is: "cc1plus.exe:-1: error: out of memory allocating 20479 bytes".

      Application is properly compiling and running in debug mode.

      I am using Windows7 and Qt 4.8.1 version.

      Please help me to resolve this memory issue in release mode.

      Thanks in Advance
      Zain

      1 Reply Last reply Reply Quote 0
      • K
        koahnig last edited by

        Which version of MinGW are you using?
        IIRC there have similar reports here at devnet. I might help to update to newest MinGW distribution. However, this means also that may have to recompile Qt.

        Vote the answer(s) that helped you to solve your issue(s)

        1 Reply Last reply Reply Quote 0
        • Z
          Zain last edited by

          Thanks Koahnig for quick reply.

          Sorry but I am new in QT and not much aware with MinGW. Can you please tell me from where I can get version of MinGW?

          I got this following info in mingw folder's manifest file.
          @
          binutils-2.19.1-mingw32-bin
          mingwrt-3.15.2-mingw32-dev
          mingwrt-3.15.2-mingw32-dll
          w32api-3.13-mingw32-dev

          gcc-core-4.4.0-mingw32-bin
          gcc-core-4.4.0-mingw32-dll
          gcc-c++-4.4.0-mingw32-bin
          gcc-c++-4.4.0-mingw32-dll
          gmp-4.2.4-mingw32-dll
          libiconv-1.13-mingw32-dll-2
          mingw32-make-3.81-20080326-3
          mpfr-2.4.1-mingw32-dll
          pthreads-w32-2.8.0-mingw32-dll
          gdb and libexpat-1.dll
          @

          One thing I would like to share that in my application is containing 5 classes of size 2-3 MB of each.Could it be cause of this problem?

          And Is it possible to make deployment build of my application in debug mode using MinGW?
          I made build debug mode but giving Qtcored4.dll error while I have added this dll in that folder.

          1 Reply Last reply Reply Quote 0
          • K
            koahnig last edited by

            It seems to be MinGW 4.4 based on your list. Possibly there is a mix, but I do not know all the details of MinGW myself. You can check the version of MinGW on the command prompt with "g++ --version".

            MinGW 4.4 is outdated already for some time. Even though it has been used for the latest pre-build of Qt 4.8.4 available from the download page.

            If you think of using Qt4 "here is wiki page":http://qt-project.org/wiki/Building_Qt_Desktop_for_Windows_with_MinGW helping in building Qt libs.
            The "wiki on MinGW":http://qt-project.org/wiki/MinGW tells how to get the newest compiler.

            It looks that you are starting with Qt. You might want to have a look at the alternative of using the "new Qt5 SDK":http://download.qt-project.org/official_releases/qt/5.0/5.0.2/qt-windows-opensource-5.0.2-mingw47_32-x86-offline.exe. It comes with Qt creator and also the newest MinGW compiler. This might save a bit of hazzle for you.

            Vote the answer(s) that helped you to solve your issue(s)

            1 Reply Last reply Reply Quote 0
            • First post
              Last post