Linux.com

Home Linux Community Community Blogs General Linux How to Build Boost using MinGW for windows OS including Windows 7

How to Build Boost using MinGW for windows OS including Windows 7

Follow these steps:

1. Download Boost from Boost WebSite
2. Extract it to the folder e.g. D:/Program Files/Boost_1_45_0
3. build bjam tool

run the below command on the command line from the path(given below) where you have extracted the Boost

Go to the folder where files has been extracted, eg D:/Program Files/Boost_1_45_0, then

cd tools/build/v2/engine/src
build.bat mingw    (mingw should be at path C:MinGW)


bjam will be created in: D:/Program Files/Boost_1_45_0/tools/build/v2/engine/src/in.ntx86

4. now copy the newly created bjam from D:/Program Files/Boost_1_45_0/tools/build/v2/engine/src/in.ntx86 to the boost root directory, D:/Program Files/Boost_1_45_0

5. Now to build boost libraries

go to D:/Program Files/Boost_1_45_0

bjam - -toolset=gcc   OR

bjam - -toolset=gcc - -build-type=complete stage


This will take time so wait-----

After all the targets build, the include header files are located in the D:/Program Files/Boost_1_45_0/boost and the libraries are located in the D:/Program Files/Boost_1_45_0/stage/lib

enjoy-----------:::::)))

Now your C++ code is ready to use boost with g++

 

Comments

Subscribe to Comments Feed
  • diki Said:

    BEASTLY!!! Thanks dude, this is the ONLY guide on compiling boost with mingw on the internet that actually works!!

Upcoming Linux Foundation Courses

  1. LFD331 Developing Linux Device Drivers
    25 Aug » 29 Aug - Virtual
    Details
  2. LFD411 Embedded Linux Development
    25 Aug » 29 Aug - Santa Clara, CA
    Details
  3. LFS422 High Availability Linux Architecture
    08 Sep » 11 Sep - Raleigh, NC
    Details

View All Upcoming Courses


Who we are ?

The Linux Foundation is a non-profit consortium dedicated to the growth of Linux.

More About the foundation...

Frequent Questions

Join / Linux Training / Board