Re: [Boost-users] bjam with mingw

27 views
Skip to first unread message

Brewer, Christopher

unread,
Sep 7, 2004, 10:45:43 AM9/7/04
to boost...@lists.boost.org
Angus-

I had similar problems with bjam under MinGW. By experimentation,
I discovered that I could make bjam work under MinGW by moving it
from it's previous location at 'c:/msys/1.0/bin' to
'c:/msys/1.0/mingw/bin'.

FYI, you can find this thread starting at Boost-users Digest,
Vol 250, Issue 1, and ending (successully :) at Boost-users Digest,
Vol 253, Issue 1.

HTH,

Chris Brewer

_______________________________________________
Boost-users mailing list
Boost...@lists.boost.org
http://lists.boost.org/mailman/listinfo.cgi/boost-users

Daniel Schlyder

unread,
Sep 7, 2004, 11:15:24 AM9/7/04
to boost...@lists.boost.org
Brewer, Christopher:
> I had similar problems with bjam under MinGW. By experimentation,
> I discovered that I could make bjam work under MinGW by moving it
> from it's previous location at 'c:/msys/1.0/bin' to
> 'c:/msys/1.0/mingw/bin'.

> FYI, you can find this thread starting at Boost-users Digest,
> Vol 250, Issue 1, and ending (successully :) at Boost-users Digest,
> Vol 253, Issue 1.

Maybe that didn't work because

"Msys will convert POSIX paths that are used as arguments to Win32 paths.
This is done for any executable not in /bin and /usr/bin." [MSYS readme]

--
Daniel Schlyder
http://bitblaze.com/

Angus Leeming

unread,
Sep 7, 2004, 10:10:47 AM9/7/04
to boost...@lists.boost.org
Brewer, Christopher wrote:
> Angus-
>
> I had similar problems with bjam under MinGW. By experimentation,
> I discovered that I could make bjam work under MinGW by moving it
> from it's previous location at 'c:/msys/1.0/bin' to
> 'c:/msys/1.0/mingw/bin'.

It does indeed. Many, many thanks, Chris.

> FYI, you can find this thread starting at Boost-users Digest,
> Vol 250, Issue 1, and ending (successully :) at Boost-users Digest,
> Vol 253, Issue 1.

Mea culpa. I now see you posted the solution on 16 Jun.

Regards,
Angus

Angus Leeming

unread,
Sep 7, 2004, 9:38:14 AM9/7/04
to boost...@lists.boost.org
Daniel Schlyder wrote:

Hi, Daniel.

> I've never tried compiling Boost under MSYS, but running
>
> bjam -sMINGW_ROOT_DIRECTORY=d:\mingw -sTOOLS=mingw
>
> from the top level Boost directory under Windows CLI should work. Sorry if
> you already tried MINGW_ROOT_DIRECTORY and TOOLS in combination; I couldn't
> tell from your mail.

Yes, this works. Thank you.

However, I'd really like to do this under MSYS. Am I asking for the
impossible?

Angus Leeming

unread,
Sep 7, 2004, 7:50:06 AM9/7/04
to boost...@lists.boost.org
Please forgive the newbie questions, but I am trying and failing to
build boost with MinGW.

I've grabbed the CVS sources of boost from the sourceforge anonymous mirror.
I've installed MinGW and MinSYS.
The MinGW tools are in my path.

From the MinSYS console:

$ cd ~/boostcvs
$ which which c++
/mingw/bin/c++
$ c++ --version
c++.exe (GCC) 3.2.3 (mingw special 20030504-1)

Just to check that the tools are working:

$ cd libs/spirit/phoenix/test
$ c++ -I$HOME/boostcvs -o new_test new_test.cpp
$ ./new_test
///////////////////////////////////////////////////////////////////////////////
Tests concluded
SUCCESS!!!
///////////////////////////////////////////////////////////////////////////////

Now trying to do something similar using bjam:

$ cd ~/boostcvs/libs/test/build
$ bjam '-sTOOLS=mgw'

CALL "C:\Program Files\Microsoft Visual Studio .NET
2003\VC7\bin\VCVARS32.BAT" >nul
"C:\Program Files\Microsoft Visual Studio .NET 2003\VC7\bin\cl"
/Zm800 -nologo /EHsc -c -DBOOST_TEST_NO_AUTO_LINK=1 /Z7 /Od /Ob0 /EHsc
/GR /MTd /Op /Zc:forScope /Zc:wchar_t
-I"..\..\..\bin\boost\libs\test\build"
-I"d:\MinSYS\1.0\home\Angus\boost_cvs"
-Fo"..\..\..\bin\boost\libs\test\build\libboost_unit_test_framework.lib\vc7.1\debug\runtime-link-static\threading-multi\unit_test_main.obj"

-Tp"d:\MinSYS\1.0\home\Angus\boost_cvs\libs\test\build\../src/unit_test_main.cpp"


....failed vc-C++
...\..\..\bin\boost\libs\test\build\libboost_unit_test_framework.lib\vc7.1\debug\runtime-link-static\threading-multi\unit_test_main.obj...
vc-C++
...\..\..\bin\boost\libs\test\build\libboost_unit_test_framework.lib\vc7.1\debug\runtime-link-static\threading-multi\supplied_log_formatters.obj
The system cannot find the path specified.
The system cannot find the path specified.

[ snip all other, similar messages ]

For the life of me I can't see why bjam is trying to build the VC++
target. I can't even run

$ bjam --help

because it just does the same thing, trying and failing to build stuff
with VC++.

I have also tried running from the top level boost directory and with
the '-sMINGW_ROOT_DIRECTORY=/d/mingw' command line option to bjam, all
to no avail. (From my understanding of the docs at
http://www.boost.org/tools/build/v1/mingw-tools.html, that shouldn't be
necessary.) I have changed the TOOLS name to 'mingw' rather than 'mgw'.
Again , no dice.

Finally, in desperation, opening up a DOS prompt and repeating the
exercise. Nope. Same result.

Can anyone help me out?
Regards,

Daniel Schlyder

unread,
Sep 7, 2004, 9:42:09 AM9/7/04
to boost...@lists.boost.org
Angus Leeming:
[snip]
> Now trying to do something similar using bjam:

> $ cd ~/boostcvs/libs/test/build
> $ bjam '-sTOOLS=mgw'

The correct value is 'mingw'.

[snip]
> For the life of me I can't see why bjam is trying to build the VC++
> target. I can't even run

> $ bjam --help

> because it just does the same thing, trying and failing to build stuff
> with VC++.

Try "bjam -help". :)

> I have also tried running from the top level boost directory and with
> the '-sMINGW_ROOT_DIRECTORY=/d/mingw' command line option to bjam, all
> to no avail. (From my understanding of the docs at
> http://www.boost.org/tools/build/v1/mingw-tools.html, that shouldn't be
> necessary.) I have changed the TOOLS name to 'mingw' rather than 'mgw'.
> Again , no dice.

> Finally, in desperation, opening up a DOS prompt and repeating the
> exercise. Nope. Same result.

I've never tried compiling Boost under MSYS, but running

bjam -sMINGW_ROOT_DIRECTORY=d:\mingw -sTOOLS=mingw

from the top level Boost directory under Windows CLI should work. Sorry if
you already tried MINGW_ROOT_DIRECTORY and TOOLS in combination; I couldn't
tell from your mail.

--
Daniel Schlyder
http://bitblaze.com/

Reply all
Reply to author
Forward
0 new messages