linux GCC环境,boost在编译时未加-fPIC参数,导致如果有共享库使用boost静态库,会报如下错误:relocation R_X86_64_32 against `a local symbol' can not be used when making a shared object; recompile with -fPIC如果使用automake编译,可以通过CPPFLAGS将-fPIC加进去.针对boost_1_53_0版本,修改tools/build/v2/tools/gcc
------------buildboost.bat-------------- @REM Used to build boost lib.@REM by Rock Wang @transoft 20070807 set msvc_home=C:\Program Files\Microsoft Visual Studio 8\VC call "%msvc_home%\bin\vcvars32.bat" bjam.exe -sTOOLS=vc-8_0 "-sBUILD=debu
cd boost_1_64_0/tools/build ./bootstrap.sh --with-toolset=gcc 输出: -n Bootstrapping the build engine with toolset gcc... engine/bin.macosxx86_64/b2 Bootstrapping is done. To build and install, run: ./b2 install --prefix=<DIR> ./b2 install --prefix=/u