[boost] bootstrap.bat broken for MinGW since 1.55

579 views
Skip to first unread message

Björn Pollex

unread,
Dec 3, 2013, 9:12:04 AM12/3/13
to bo...@lists.boost.org
I have just tried to bootstrap Boost 1.55 for use with 32 bit MinGW on
Windows 7. Here is what I get:

C:\Users\pollexb\git_repositories\modular-boost>bootstrap.bat
Building Boost.Build engine
'"VCVARS32.BAT"' is not recognized as an internal or external command
operable program or batch file.
'"VCVARS32.BAT"' is not recognized as an internal or external command
operable program or batch file.
'"VCVARS32.BAT"' is not recognized as an internal or external command
operable program or batch file.
'"VCVARS32.BAT"' is not recognized as an internal or external command
operable program or batch file.
'cl' is not recognized as an internal or external command,
operable program or batch file.

Failed to build Boost.Build engine.
Please consult bootstrap.log for furter diagnostics.

You can try to obtain a prebuilt binary from

http://sf.net/project/showfiles.php?group_id=7586&package_id=72941

Also, you can file an issue at http://svn.boost.org
Please attach bootstrap.log in that case.

The log file has the following contents:

###
### Using 'msvc' toolset.
###


C:\Users\pollexb\git_repositories\modular-boost\tools\build\v2\engine>if
exist bootstrap rd /S /Q bootstrap


C:\Users\pollexb\git_repositories\modular-boost\tools\build\v2\engine>md
bootstrap


C:\Users\pollexb\git_repositories\modular-boost\tools\build\v2\engine>cl
/nologo /GZ /Zi /MLd /Fobootstrap/ /Fdbootstrap/ -DNT -DYYDEBUG
kernel32.lib advapi32.lib user32.lib /Febootstrap\jam0 command.c compile.c
constants.c debug.c execcmd.c execnt.c filent.c frames.c function.c glob.c
hash.c hdrmacro.c headers.c jam.c jambase.c jamgram.c lists.c make.c
make1.c object.c option.c output.c parse.c pathnt.c pathsys.c regexp.c
rules.c scan.c search.c subst.c timestamp.c variable.c modules.c strings.c
filesys.c builtins.c md5.c class.c cwd.c w32_getreg.c native.c
modules/set.c modules/path.c modules/regex.c modules/property-set.c
modules/sequence.c modules/order.c

For some reason it simply ignores the option I pass in and tries to use
msvc instead. I recall that there was some discussion about boostrap.sh
prior to the 1.55 release, but could not find anything there that affected
bootstrap.bat.

I have tried with the source archive downloaded from Sourceforge, and with
the master branch from Github, both times I get the same error. It works
fine with Boost 1.54.

Does anyone know what change could have caused this?

Regards,

Björn Pollex

_______________________________________________
Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost

niXman

unread,
Dec 3, 2013, 9:37:22 AM12/3/13
to bo...@lists.boost.org
Björn Pollex писал 2013-12-03 18:12:

Before the release of boost-1.55, I warned the developers about that.
But they preferred to ignore me instead of fix it.

--
Regards, niXman
___________________________________________________
Dual-target(32 & 64-bit) MinGW-W64 compilers for 32 and 64-bit Windows:
http://sourceforge.net/projects/mingw-w64/
___________________________________________________
Another online IDE: http://liveworkspace.org/

Björn Pollex

unread,
Dec 3, 2013, 9:39:51 AM12/3/13
to bo...@lists.boost.org
On Tue, Dec 3, 2013 at 3:12 PM, Björn Pollex
<bjoern...@googlemail.com>wrote:

> I have just tried to bootstrap Boost 1.55 for use with 32 bit MinGW on
> Windows 7. Here is what I get:
>
>
I just realized that I used the wrong command line in this example (the
"mingw" parameter is missing). This is a copy/paste mistake. Using
"boostrap.bat mingw" produces the exact same output.

Jim Bell

unread,
Dec 3, 2013, 12:09:12 PM12/3/13
to bo...@lists.boost.org

On 2013-12-03 8:39 AM, Björn Pollex wrote:
> On Tue, Dec 3, 2013 at 3:12 PM, Björn Pollex
> <bjoern...@googlemail.com>wrote:
>
>> I have just tried to bootstrap Boost 1.55 for use with 32 bit MinGW on
>> Windows 7. Here is what I get:
>>
>>
> ... Using
> "boostrap.bat mingw" produces the exact same output.
>

This should bootstrap MinGW:

bash
cd BOOST_ROOT/tools/build/v2/engine
./build.sh mingw
cd BOOST_ROOT
./tools/build/v2/engine/bin.ntx86/bjam.exe ...

niXman

unread,
Dec 4, 2013, 2:21:20 AM12/4/13
to bo...@lists.boost.org
Jim Bell 2013-12-03 21:09:
> This should bootstrap MinGW:
>
> bash
> cd BOOST_ROOT/tools/build/v2/engine
> ./build.sh mingw
> cd BOOST_ROOT
> ./tools/build/v2/engine/bin.ntx86/bjam.exe ...

Ie from version 1.55, in order to build boost using MinGW, I should
install Cygwin/MSYS? I'm just curious, this was intentional? And if so -
is there any objective reason for this?


--
Regards, niXman
___________________________________________________
Dual-target(32 & 64-bit) MinGW-W64 compilers for 32 and 64-bit Windows:
http://sourceforge.net/projects/mingw-w64/
___________________________________________________
Another online IDE: http://liveworkspace.org/

Vladimir Prus

unread,
Dec 4, 2013, 2:49:18 AM12/4/13
to bo...@lists.boost.org
On 03.12.2013 18:37, niXman wrote:

>> I have tried with the source archive downloaded from Sourceforge, and with
>> the master branch from Github, both times I get the same error. It works
>> fine with Boost 1.54.
>>
>> Does anyone know what change could have caused this?
>
> Before the release of boost-1.55, I warned the developers about that. But they preferred to ignore me instead of fix it.

I'm am sorry that you feel like you've being ignored, but nobody in the world likes to hack .bat files. Also, this
is partially a known problem, see:

https://github.com/boostorg/boost/blob/master/bootstrap.bat#L34

Patches are appreciated!

Thanks,
Volodya

Alan Birtles

unread,
Dec 4, 2013, 8:47:53 AM12/4/13
to bo...@lists.boost.org
The following trick can be used to pass variables out from a setlocal block

SETLOCAL
set my_variable=1234
( ENDLOCAL
REM pass my_variable though the ENDLOCAL
set my_variable=%my_variable%
)
echo my_variable

Jim Bell

unread,
Dec 4, 2013, 10:36:04 AM12/4/13
to bo...@lists.boost.org

On 2013-12-04 1:21 AM, niXman wrote:
> Jim Bell 2013-12-03 21:09:
>> This should bootstrap MinGW:
>>
>> bash
>> cd BOOST_ROOT/tools/build/v2/engine
>> ./build.sh mingw
>> cd BOOST_ROOT
>> ./tools/build/v2/engine/bin.ntx86/bjam.exe ...
>
> Ie from version 1.55, in order to build boost using MinGW, I should
> install Cygwin/MSYS? I'm just curious, this was intentional? And if so
> - is there any objective reason for this?

MSYS is part of MinGW (or at least joined at the hip). Requiring it
surely isn't intentional, but seems (to me) to go with the grain of
MinGW. And my build instructions are a hack for determined users, not
official boost or intentional policy.

http://sourceforge.net/apps/trac/mingw-w64/wiki/MSYS
http://mingw.org/wiki/msys

niXman

unread,
Dec 4, 2013, 11:01:16 AM12/4/13
to bo...@lists.boost.org
Jim Bell 2013-12-04 19:36:

> MSYS is part of MinGW (or at least joined at the hip).

I don't know about MinGW from mingw.org, but MinGW-W64 from
sourceforge.net/projects/mingw-w64/ and MSYS - are absolutely different
projects and there is no tie-up between them.
The MinGW-w64 is native win32/win64 compiler, but MSYS - is posix
emulator.


--
Regards, niXman
___________________________________________________
Dual-target(32 & 64-bit) MinGW-W64 compilers for 32 and 64-bit Windows:
http://sourceforge.net/projects/mingw-w64/
___________________________________________________
Another online IDE: http://liveworkspace.org/

Eric Niebler

unread,
Dec 4, 2013, 2:45:45 PM12/4/13
to bo...@lists.boost.org
On 12/03/2013 11:49 PM, Vladimir Prus wrote:
> On 03.12.2013 18:37, niXman wrote:
>
>>> I have tried with the source archive downloaded from Sourceforge, and
>>> with
>>> the master branch from Github, both times I get the same error. It works
>>> fine with Boost 1.54.
>>>
>>> Does anyone know what change could have caused this?
>>
>> Before the release of boost-1.55, I warned the developers about that.
>> But they preferred to ignore me instead of fix it.
>
> I'm am sorry that you feel like you've being ignored, but nobody in the
> world likes to hack .bat files. Also, this
> is partially a known problem, see:
>
> https://github.com/boostorg/boost/blob/master/bootstrap.bat#L34
>
> Patches are appreciated!

I have this partially implemented over here. I hope to finish it up
later today.

Eric

spom

unread,
Dec 5, 2013, 11:48:41 AM12/5/13
to bo...@lists.boost.org
I had the same problem today but found a workaround:

Adding an empty!! new line in

$BOOSTDIR/tools/build/v2/engine/build.bat

in line 93 right before:
:Guess_Toolset

After that

cmd /c 'bootstrap.bat mingw'

Works as expected again in msys command environment.

I have no clue to *.bat scripts so I have no idea why this hack works, but I
hope this can help fixing the bootstrap problem in a more elegant way.

Best regards,
Spom.



--
View this message in context: http://boost.2283326.n4.nabble.com/bootstrap-bat-broken-for-MinGW-since-1-55-tp4655733p4655944.html
Sent from the Boost - Dev mailing list archive at Nabble.com.

Eric Niebler

unread,
Dec 6, 2013, 7:43:21 PM12/6/13
to bo...@lists.boost.org
On 12/4/2013 11:45 AM, Eric Niebler wrote:
> On 12/03/2013 11:49 PM, Vladimir Prus wrote:
>> On 03.12.2013 18:37, niXman wrote:
>>
>>>> I have tried with the source archive downloaded from Sourceforge, and
>>>> with
>>>> the master branch from Github, both times I get the same error. It works
>>>> fine with Boost 1.54.
>>>>
>>>> Does anyone know what change could have caused this?
>>>
>>> Before the release of boost-1.55, I warned the developers about that.
>>> But they preferred to ignore me instead of fix it.
>>
>> I'm am sorry that you feel like you've being ignored, but nobody in the
>> world likes to hack .bat files. Also, this
>> is partially a known problem, see:
>>
>> https://github.com/boostorg/boost/blob/master/bootstrap.bat#L34
>>
>> Patches are appreciated!
>
> I have this partially implemented over here. I hope to finish it up
> later today.

I submitted a pull request that hopefully addresses this issue:
https://github.com/boostorg/boost/pull/5

With this patch, you should be able to do:
> bootstrap.bat --with-toolset=mingw

... and it should do the right thing. It would be great if someone could
try it out.

--
Eric Niebler
Boost.org
http://www.boost.org
Reply all
Reply to author
Forward
0 new messages