Boost logo

Boost Users :

From: Delfin Rojas (drojas_at_[hidden])
Date: 2005-12-21 17:48:38


> Hi,
> I have used a few boost libraries that did not require me to use bjam
> (just
> templates) but now I am trying to use bjam to build some examples in
> boost.
>
> I have an environment like:
> set BOOST_ROOT=C:\scott\boost\boost_1_33_1
>
> REM because asio documentation said it needed to be defined set
> BOOST_DATE_TIME_NO_LIB=value_does_not_matter
>

I think you are confusing preprocessor defines with environment defines.
BOOST_DATE_TIME_NO_LIB is a preprocessor define and needs to be passed to
bjam directly.

> REM trying to avoid this warning
> REM Please define _WIN32_WINNT or _WIN32_WINDOWS appropriately
> REM Assuming _WIN32_WINNT=0x0500 (i.e. Windows 2000 target)
> REM windows XP = 0x0501
> set _WIN32_WINNT=0x0501
>

Same here, _WIN32_WINNT is preprocessor define and needs to be passed to
bjam

> REM Boost Build requirements
> set VC71_ROOT=C:\Program Files\Microsoft Visual Studio .NET 2003\Vc7
> set PATH=%VC71_ROOT%\bin;C:\scott\boost\bin;%PATH%
>
> vcvars32.bat
>
>
> Some questions:
> 1) How do I avoid the following warning output when building with bjam?
>
> Please define _WIN32_WINNT or _WIN32_WINDOWS appropriately
> Assuming _WIN32_WINNT=0x0500 (i.e. Windows 2000 target)
>

See my bjam command line call at the end of this message

> 2) I am used to having solution and project files for Microsoft
> Development Environment (MDE) using Visual C++.
> bjam apparently does not create these files.
> Can I get bjam to create project files?
>
> How does one use the debugger in MDE without project files?
> It would be inconvenient to have to always attached to a running
> process.
>

Visual C++ solutions and project files contain the settings for your project
(how to build it). Bjam uses its own type of "project files", which are
located in the build directory of each boost library. All you need to do is
call bjam in the right directory so it can find those files.

You will be able to use the debugger just fine. When you build the boost
libraries you will get a debug version and a release version. By default
boost will link to the right library for you (or you can do it manually) and
then, as you are debugging, your debugger will step into the appropriate
boost library you linked against.

Anyway, here is a sample of a bjam call that defines _WIN32_WINNT for you.
You should run this at the root of boost, which for you seems to be
C:\scott\boost\boost_1_33_1.

bjam "-sTOOLS=vc7_1" "-sBUILD=<define>_WIN32_WINNT=0x0501" install

The above command should build all boost libraries in debug and release mode
and put them into the bin folder located at the boost root.

Hope this helps. Once you get used to it bjam is a nice and very flexible
building tool. Also the "Getting Started" page at
http://www.boost.org/more/getting_started.html contains a lot of the
information you need to build.

-delfin


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net