Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to set compile flag /bigobj in visual studio?

I have a cpp file that contains a huge array.

I get a fatal error (exceeded object file format limit) and the suggestion to compile with the flag /bigobj

Where do I set this flag in visual studio?

like image 811
ragnarius Avatar asked Nov 22 '11 10:11

ragnarius


2 Answers

According to MSDN and /bigobj (Increase Number of Sections in .Obj file):

To set this compiler option in the Visual Studio development environment

  1. Open the project's Property Pages dialog box. For details, see How to: Open Project Property Pages.
  2. Click the C/C++ folder.
  3. Click the Command Line property page.
  4. Type the compiler option in the Additional Options box.
like image 159
jww Avatar answered Sep 19 '22 13:09

jww


On the Command Line property page as described here.

like image 26
Hans Olsson Avatar answered Sep 22 '22 13:09

Hans Olsson