[Insight-users] wrapitk maintenance branch r527 still results in /bigobj errors on win64, vs 2008 SP1

Charl Botha c.p.botha at tudelft.nl
Sat Feb 19 02:56:00 EST 2011


On Fri, Feb 18, 2011 at 21:20, Charl Botha <c.p.botha at tudelft.nl> wrote:
> # on visual studio 2005 and later, we need to use /bigobj as the
> # generated wrappings take up more than 65535 sections in some
> # objects.
> IF(CMAKE_COMPILER_2005)
>  ADD_DEFINITIONS(/bigobj)
> ENDIF(CMAKE_COMPILER_2005)
>
> (I contributed this patch some months ago)

It seems that somehow CMAKE_COMPILER_2005 does not evaluate to true on
my VS 2008 SP1 setup, although the documentation says that it should
on VS 2005 and newer. In any case, this code *does* work (/bigobj is
added to the project command-lines), and is better because it's only
triggered on Win64 with MS where the problem occurs:

# With MS compilers on Win64, we need the /bigobj switch, else generated
# code results in objects with number of sections exceeding object file
# format.
# see http://msdn.microsoft.com/en-us/library/ms173499.aspx
IF(CMAKE_CL_64)
  ADD_DEFINITIONS(/bigobj)
ENDIF(CMAKE_CL_64)

On to the next build problem... :)


More information about the Insight-users mailing list