简体   繁体   中英

Boost installation issue in windows

I am installing boost_1_60_0 based on directions given in official website for Windows.

Below is the command I am running to install boost for my project in C++.

boost_1_60_0>b2 -j8 --toolset=gcc  --build-dir=C:\mycode\src\threadsupport\boost_1_60_0\build  --build-type=complete  stage

This gives me some Python-related error even though I have installed Python 2.7.11.

Below are the error logs:

boost_1_60_0\build\boost\bin.v2\libs\python\build\gcc-mingw-4.8.1\release\numeric.o:numeric.cpp:(.text+0x20f9): undefined reference to `_imp__PyInt_FromLong'
boost_1_60_0\build\boost\bin.v2\libs\python\build\gcc-mingw-4.8.1\release\numeric.o:numeric.cpp:(.text+0x2138): undefined reference to `_imp__PyEval_CallFunction'
boost_1_60_0\build\boost\bin.v2\libs\python\build\gcc-mingw-4.8.1\release\numeric.o:numeric.cpp:(.text+0x228b): undefined reference to `_imp__PyString_FromStringAndSize'
boost_1_60_0\build\boost\bin.v2\libs\python\build\gcc-mingw-4.8.1\release\numeric.o:numeric.cpp:(.text+0x22ad): undefined reference to `_imp__PyImport_Import'

There are a lot of similar type of errors coming. Any help regarding this will be much appreciated.

Had a lot of problems as well, these simple steps fixed it for me.

Step1:

bootstrap.bat

Step2:

b2 toolset=msvc link=shared threading=multi --build-type=complete stage

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM