Boost logo

Boost Users :

Subject: [Boost-users] problems with 32-bit Boost libs on Linux 64-bit with multilib gcc
From: Damien Hocking (damien_at_[hidden])
Date: 2009-03-01 19:29:24


Hi all,

I'm having some problems with building a 32-bit Boost on a 64-bit Linux. I'm building 1.38 and I need 64 and 32-bit version of the libraries. The compiler is gcc 4.3.2 with the multilibs installed (Ubuntu 8.10). My builds go through successfully, but when I link my 32-bit version of my application to what should be 32-bit Boost libraries, I get the "skipping incompatible" warning from the linker, which means that the address model is wrong. For example:
 
/usr/bin/ld: skipping incompatible 3rdparty/boost/linux/x86/debug/libboost_serialization-gcc43-mt-d-1_38.so

The 64-bit libraries are fine and the application links and runs correctly. I noticed in gcc.jam there's a comment about not being able to build a clean 32-bit binary with a 64-bit compiler. This is my bjam command for a 32-bit Boost build:

  bjam --build-dir=./build32 address-model=32 --build-type=complete --stagedir=./stage32 stage

Do I need a -m32 in a config file or something extra on that command line?

Damien



Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net