Building mongodb with custom boost library using linux. Client C++ driver too &:)

In fact it is much more a memory for myself than some tutorial. But as I have not found any (actual) reference of it.
By the way, I tested during 2.5.x development cicle. Probably it can change. (And will. (As it did.))

Just the commands.

Download boost, unzip it, go to the folder:

./bootstrap.sh
./b2 variant=debug link=static  threading=multi  --with-system --with-thread --with-date_time --with-regex --with-serialization   --with-system --with-program_options --with-filesystem stage
mkdir /opt/boost
./b2 install --prefix=/opt/boost

For mongo:

cd ~
mkdir mongo
cd mongo
git clone https://github.com/mongodb/mongo.git
mkdir /opt/mongo
scons --full -j 64 --prefix=/opt/mongo/ --cpppath=/opt/boost --libpath=/epidb/opt/boost/

It takes some time because it builds *everything*.

Done!

For testing:

cd ~
mkdir db
/opt/mongo/mongod --dbpath db

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s