First, download the source code here. Also download zlib and bzip2. Extract them to separate directories and open a command prompt in the directory of Boost. Run
bootstrap gcc
b2 -s ZLIB_SOURCE=ZLIB_SOURCE -s BZIP2_SOURCE=BZIP2_SOURCE variant=debug,release link=shared,static threading=single,multi address-model=32,64 toolset=gcc
That will build all variants. Of course, you can pick and only build what you need.