10

Can someone tell me why bootstrap.bat failed?

Platform:
Windows 10
Boost boost_1_63_0

C:\Boost\boost_1_63_0>bootstrap.bat
Building Boost.Build engine
'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 further 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.

C:\Boost\boost_1_63_0>
Pang
  • 9,564
  • 146
  • 81
  • 122
Kurt VanderKoi
  • 111
  • 1
  • 1
  • 4

4 Answers4

32

As in my answer found in Build boost with msvc 14.1 ( VS2017 RC)

You need to use Visual Studio 2017's Developer Command Prompt!

It's found in Start - All Programs - Visual Studio 2017 - Visual Studio Tools - Developer Command Prompt for VS 2017

Community
  • 1
  • 1
manuel saraiva
  • 601
  • 6
  • 5
  • 2
    `Developer Command Prompt for VS2017` compile-c-c++ bin.v2\libs\system\build\msvc-14.1\debug\address-model-64\threadin g-multi\error_code.obj 'cl' is not recognized as an internal or external command, operable program or batch file. – user3673 Dec 10 '17 at 17:33
  • I was apparently mislead into specifying 14.1 when I had 14.0 installed. Here is the 14.1 "advice" https://stackoverflow.com/questions/43946538/how-to-build-boost-1-64-in-64-bits – user3673 Dec 10 '17 at 17:47
  • 1
    you might need to run it as Administrator (right click, 'run as administrator') – user2723494 Feb 04 '18 at 07:10
  • 1
    You can activate the developer command prompt in any command window by executing `C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\Common7\Tools\VsDevCmd.bat` – JoseOrtiz3 Oct 06 '18 at 08:36
2

The error says that the compiler is not found. The most likely reasons are:

  • The compiler is not installed or installed in a non-standard path.
  • Your compiler is Visual Studio 2017, which is not supported by Boost 1.63 and can't be found automatically because of the changes made by Microsoft.

If you are using Visual Studio you can try running bootstrap from the compiler command line prompt.

Andrey Semashev
  • 10,046
  • 1
  • 17
  • 27
  • 1
    for VS2015, the shortcuts you should use to launch the command prompt are located in: `C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Visual Studio 2015\Visual Studio Tools\Windows Desktop Command Prompts` (On my system anyway, but I'm pretty sure I installed with a default configuration) – bfair Mar 15 '17 at 17:13
1

I have solved it installing Visual Studio and adding the path C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.23.28105\bin\Hostx64\x64 to the environment vairlables. Look at this page click here

0

I found the following discussion around this issue including both Microsoft and Boost teams. It's spread out across the Github issue and mailing list:

https://github.com/boostorg/build/issues/157

https://lists.boost.org/Archives/boost/2017/03/234024.php

solvingJ
  • 1,321
  • 1
  • 19
  • 30