$ g++ -fPIC -c -o main.o main.cpp -I/usr/include/boost-1_37/ && g++ -o test.so main.o -sharedThis works since main.cpp is being compiled to main.o with PIC. However, Boost is not involved here so it proves nothing about Boost.
It does prove something about Boost to me - as soon as I add the Boost libraries to the above program I get the error, which implies that something isn't compiled with -fPIC. Since Boost was the only thing added, Boost must have been compiled without -fPIC.
Cheers, Adam.