Search code examples
visual-studio-2010boostcmakebjamogre

Building Boost for Ogre 64 bit


Needing to add the 64 bit version of the Ogre graphics engine (latest at the time of writing this post, i.e. 1.8.0), I've followed their hints and opened a visual c++ x64 command prompt and typed this:

  bjam --build-dir=vc10 --toolset=msvc-10.0 --address_model=64 --with-thread --with-date_time --build-type=complete stage

This is as far as I got with convincing boost to build lib objects for a 64 bit windows compiler. I am using Visual Studio 2010 Premium and the CMake tools to compile Ogre from sources. This is where things get nasty:

 Error  276 error LNK1104: cannot open file '..\..\lib\Debug\OgreMain_d.lib'    
 Error  119 error LNK1112: module machine type 'X86' conflicts with target machine type 'x64'   

I fear I won't make it pass this issue any time soon as I'm totally unaccustomed to working with big code bases that rely heavily on dependencies that I have to, also, build from scratch. Could you please provide a hint or a link to something I might have missed? Thanks..

UPDATE There is a website containing the already built libraries, but it would be nice to learn why the --address-model and --address-space flags don't work. How else should one use bjam to build the libraries?


Solution

  • There are a couple of errors in the bjam command. You don't want a -- in front of toolset or address-model, and address-model has a hyphen, not an underscore.

    So the command you probably were aiming for is:

    bjam --build-dir=vc10 toolset=msvc-10.0 address-model=64 --with-thread --with-date_time --build-type=complete stage