Compiler out of heap space error on MSVC build
I am seeing frequent "Compiler out of heap space" errors when building with MSVC 2022. It happens reliably on a Github CI host but not always locally -
- I can build from the MSVC 2022 developer tools command prompt
- Building from a bash prompt with the MSVC tools available results in a C1060 error.
It seems to be related to the translation targets, though I tried disabling the xgettext
and msgfmt
tools from the Git Bash prompt to no avail. Relevant log attached -
FAILED: gtk/libgtk.a.p/meson-generated_.._gtkresources.c.obj
"cl" ... "/MD" "/nologo" "/showIncludes" "/utf-8" "/W2" "/O2" "/Gw" "-DG_LOG_USE_STRUCTURED=1" "-DGLIB_DISABLE_DEPRECATION_WARNINGS" "-DGTK_VERSION=\"4.8.0\"" "-D_GNU_SOURCE" "-DG_DISABLE_CAST_CHECKS" "-DG_DISABLE_ASSERT" "-FImsvc_recommended_pragmas.h" "-utf-8" "-O2" "-Ob2" "-MD" "-DLIBXML_STATIC" "-DNDEBUG" "-DLZMA_API_STATIC" "-DLIBJPEG_STATIC" "-DFRIBIDI_LIB_STATIC" "-DXML_STATIC" "-DFFI_BUILDING" "-DPCRE_STATIC=1" "-DGTK_COMPILATION" "-DG_LOG_DOMAIN=\"Gtk\"" "-DGTK_PRINT_BACKEND_ENABLE_UNSUPPORTED" "-DGTK_BINARY_VERSION=\"4.0.0\"" "-DGTK_HOST=\"windows\"" "-DGTK_DATA_PREFIX=\"C:\\.conan\\62c182\\1\"" "-DGTK_PRINT_BACKENDS=\"file,lpr\"" "-FImsvc_recommended_pragmas.h" "-D_USE_MATH_DEFINES" "-utf-8" "/Fdgtk\libgtk.a.p\meson-generated_.._gtkresources.c.pdb" /Fogtk/libgtk.a.p/meson-generated_.._gtkresources.c.obj "/c" gtk/gtkresources.c
gtk/gtkresources.c(29246): fatal error C1060: compiler is out of heap space
I was wondering if it's possible to split the gtkresources
object file up, if that would help and where in the build system I should look.
Thanks.