Number of sections exceeded object file format limit: compile with /bigobj
Solved
General and Desktop
-
While compiling a Github project with Qt, I got this error:
D:\Project\myproject\src\projectplugins\filter\somefile.cpp:-1: error: C1128: number of sections exceeded object file format limit: compile with /bigobj
Where can I setup this flag, bigobj ? I have tried to put this line:
QMAKE_CXXFLAGS += -bigobj
in the ending of CMakeLists.txt file, but didn't worked. My compiler is VS2017 64 bit, but I have no file.sln file to setup this option. Can you help me a little bit ?
-
add_compile_options(/bigobj)
https://cmake.org/cmake/help/latest/command/add_compile_options.html