c++ - windows下配置Boost提示'cl' 不是内部或外部命令,也不是可运行的程序 或批处理文件。
巴扎黑
巴扎黑 2017-04-17 13:43:31
0
4
1641

我在windows10下配置Boost,按照网上的教程,运行批处理bootstrap.bat
下面是报错内容:

请问要如何正确配置?(我试过在VS2013的命令行下执行也是一样,直接双击bootstrap.bat 闪退
求解

巴扎黑
巴扎黑

reply all(4)
洪涛

1) cl.exe is the compilation and connection tool that comes with Visual studio. The default installation path on my machine is located at C:Program Files (x86)Microsoft Visual Studio 11.0VCbinamd64cl.exe. Note that the version of Visual Studio you install must be It is consistent with the required environment of boost. For compilation of many new features of boost, choose the C++ version. If it is still not found after installation, you can try adding the directory of cl.exe to the system environment variable PATH
2) Compiled A good boost is available for download. It is recommended that novices use that one directly. It is not recommended to compile the boost by yourself

大家讲道理

Open VS2013 Developer Command Prompt before executing the build operation.
Also, boost is basically header-only. Please check the documentation to see if your part needs to be compiled

Ty80

【Transfer】http://tieba.baidu.com/p/1061836534
Before use
Open the console (CTRL+R>cmd); type cl and press Enter; if the following prompt appears: 'cl ' is not recognized as an internal or external command, operable program or batch file. It means that VS is not installed or the environment variable is set incorrectly. You can follow the following steps to set it:

  1. Make sure that VS has been installed, and type set in the console
    Check whether there is an environment variable similar to the following format VSXXCOMNTOOLSVS90COMNTOOLS=D:Program FilesMicrosoft Visual Studio 9.0Common7Tools where XX is related to the VS version:

a) VS2003 corresponds to VS71COMNTOOLS
b) VS2005 corresponds to VS80COMNTOOLS
c) VS2008 corresponds to VS90COMNTOOLS. If not, proceed to step 2; otherwise, proceed to step 32. In My Computer>Properties>Advanced>Environment Variables >Create a new static variable in the system variable
Variable name: VSXXCOMNTOOLS
Variable value: VS installation directory Common7Tools
Repeat step 13. Type

in the console

call "%VS90COMNTOOLS%" vsvars32.bat <==Set some environment variables when cl is running
cl Make sure there are no errors; otherwise repeat step 1

Peter_Zhu

Use the command prompt of VS, then jump to the corresponding directory and execute bootstrap.bat

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template