Building Boost.Build engine 'cl' is not re

2019-06-17 06:20发布

问题:

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>

回答1:

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



回答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.



回答3:

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



标签: boost