C++ 编译CMake C++;在azure管道上运行的Windows上的Boost

C++ 编译CMake C++;在azure管道上运行的Windows上的Boost,c++,boost,cmake,azure-pipelines,C++,Boost,Cmake,Azure Pipelines,尽管查阅了大量关于windows上Boost的类似提要,但它并没有找到一个有效的解决方案 我想使用AUBST编译一个CGED C++项目,需要在Azure流水线上做一些CiWork的非头文件Boost组件。 < /P> 我所做的: 克隆此存储库 运行此脚本 请参见此处的输出: 我错过了哪些额外的步骤?在Azure流水线上有一个快速CI设置的方法,这样我就不会在构建Boost上比构建我的ActualC++项目更长吗?< /P>你使用的是哪种代理OS?Windows还是Linux?如果在本地机

尽管查阅了大量关于windows上Boost的类似提要,但它并没有找到一个有效的解决方案

<强>我想使用AUBST编译一个CGED C++项目,需要在Azure流水线上做一些CiWork的非头文件Boost组件。<强> < /P> 我所做的:

  • 克隆此存储库
  • 运行此脚本 请参见此处的输出:

我错过了哪些额外的步骤?在Azure流水线上有一个快速CI设置的方法,这样我就不会在构建Boost上比构建我的ActualC++项目更长吗?< /P>你使用的是哪种代理OS?Windows还是Linux?如果在本地机器上运行脚本来设置环境,结果会怎样?
2021-05-03T15:36:36.6078839Z ##[section]Starting: Windows: Install Boost
2021-05-03T15:36:36.6243678Z ==============================================================================
2021-05-03T15:36:36.6244064Z Task         : Command line
2021-05-03T15:36:36.6244412Z Description  : Run a command line script using Bash on Linux and macOS and cmd.exe on Windows
2021-05-03T15:36:36.6244756Z Version      : 2.182.0
2021-05-03T15:36:36.6245001Z Author       : Microsoft Corporation
2021-05-03T15:36:36.6245370Z Help         : https://docs.microsoft.com/azure/devops/pipelines/tasks/utility/command-line
2021-05-03T15:36:36.6245773Z ==============================================================================
2021-05-03T15:36:38.4691222Z Cloning into 'boost-root'...
2021-05-03T15:36:38.4693425Z Generating script.
2021-05-03T15:36:38.4694881Z Script contents:
2021-05-03T15:36:38.4698214Z .\extern\boost-ci\ci\azure-pipelines\install.bat
2021-05-03T15:36:38.4698840Z ========================== Starting Command Output ===========================
2021-05-03T15:36:38.4701655Z ##[command]"C:\Windows\system32\cmd.exe" /D /E:ON /V:OFF /S /C "CALL "D:\a\_temp\83b19988-8043-4d96-8886-43b3f4a01a17.cmd""
2021-05-03T15:36:38.4702565Z 
2021-05-03T15:36:38.5270045Z D:\a\1\s>setlocal enabledelayedexpansion 
2021-05-03T15:36:38.5271425Z 
2021-05-03T15:36:38.5867732Z D:\a\1\s>IF NOT DEFINED SELF (
2021-05-03T15:36:38.5868570Z SET SELF=My_Github_username/my_repo_name  
2021-05-03T15:36:38.5869256Z  FOR /F "tokens=2 delims=/" %a in ("!SELF!") DO SET SELF=%a 
2021-05-03T15:36:38.5869774Z ) 
2021-05-03T15:36:38.5869918Z 
2021-05-03T15:36:38.5870389Z D:\a\1\s>SET SELF=my_repo_name 
2021-05-03T15:36:38.5870708Z 
2021-05-03T15:36:38.5871174Z D:\a\1\s>SET BOOST_CI_TARGET_BRANCH=my_branch 
2021-05-03T15:36:38.5871359Z 
2021-05-03T15:36:38.5871854Z D:\a\1\s>SET BOOST_CI_SRC_FOLDER=D:\a\1\s 
2021-05-03T15:36:38.5872211Z 
2021-05-03T15:36:38.5874433Z D:\a\1\s>call D:\a\1\s\extern\boost-ci\ci\azure-pipelines\\..\common_install.bat 
2021-05-03T15:36:38.5874924Z 
2021-05-03T15:36:38.5875394Z D:\a\1\s>REM Generic install script for Windows 
2021-05-03T15:36:38.5875582Z 
2021-05-03T15:36:38.5876001Z D:\a\1\s>REM The following CI specific environment variables need to be set: 
2021-05-03T15:36:38.5876271Z 
2021-05-03T15:36:38.5877328Z D:\a\1\s>REM - SELF 
2021-05-03T15:36:38.5877653Z 
2021-05-03T15:36:38.5878097Z D:\a\1\s>REM - BOOST_CI_TARGET_BRANCH 
2021-05-03T15:36:38.5878269Z 
2021-05-03T15:36:38.5878704Z D:\a\1\s>REM - BOOST_CI_SRC_FOLDER 
2021-05-03T15:36:38.5916151Z 
2021-05-03T15:36:38.5918133Z D:\a\1\s>cd ..   || EXIT /B 1 
2021-05-03T15:36:38.5919726Z 
2021-05-03T15:36:38.5920292Z D:\a\1>REM BOOST_BRANCH is the superproject branch we check out and build against 
2021-05-03T15:36:38.5920558Z 
2021-05-03T15:36:38.5920892Z D:\a\1>if "" == "" (
2021-05-03T15:36:38.5921424Z set BOOST_BRANCH=develop  
2021-05-03T15:36:38.5922000Z  if "my_branch" == "master" set BOOST_BRANCH=master 
2021-05-03T15:36:38.5923039Z ) 
2021-05-03T15:36:38.5923278Z 
2021-05-03T15:36:38.5923903Z D:\a\1>git clone -b develop --depth 1 https://github.com/boostorg/boost.git boost-root   || EXIT /B 1 
2021-05-03T15:36:38.9449733Z 
2021-05-03T15:36:38.9450849Z D:\a\1>cd boost-root   || EXIT /B 1 
2021-05-03T15:36:38.9458085Z 
2021-05-03T15:36:38.9459089Z D:\a\1\boost-root>git submodule update -q --init tools/boostdep   || EXIT /B 1 
2021-05-03T15:36:41.3394213Z 
2021-05-03T15:36:41.3395549Z D:\a\1\boost-root>xcopy /s /e /q /I D:\a\1\s libs\my_repo_name   || EXIT /B 1 
2021-05-03T15:36:43.5550241Z 2592 File(s) copied
2021-05-03T15:36:43.5582063Z 
2021-05-03T15:36:43.5582986Z D:\a\1\boost-root>REM Old configs expect boost in source folder 
2021-05-03T15:36:43.5584708Z 
2021-05-03T15:36:43.5585616Z D:\a\1\boost-root>cd .. 
2021-05-03T15:36:43.5594318Z 
2021-05-03T15:36:43.5595424Z D:\a\1>move boost-root  D:\a\1\s\ 
2021-05-03T15:36:43.5636645Z         1 dir(s) moved.
2021-05-03T15:36:43.5639541Z 
2021-05-03T15:36:43.5640618Z D:\a\1>set BOOST_ROOT=D:\a\1\s\boost-root 
2021-05-03T15:36:43.5653088Z 
2021-05-03T15:36:43.5653750Z D:\a\1>cd D:\a\1\s\boost-root 
2021-05-03T15:36:43.5678656Z 
2021-05-03T15:36:43.5679836Z D:\a\1\s\boost-root>python tools/boostdep/depinst/depinst.py --include benchmark --include example --include examples --include tools  my_repo_name   || EXIT /B 1 
2021-05-03T15:38:07.4453587Z Installing: config, headers, ../tools/boost_install, ../tools/build, ../tools/cmake
2021-05-03T15:38:07.4454897Z Installing: regex
2021-05-03T15:38:07.4455691Z Installing: concept_check, type_traits, static_assert, config, assert, predef, throw_exception, container_hash, integer, mpl, smart_ptr, core, iterator
2021-05-03T15:38:07.4457072Z Installing: preprocessor, detail, utility, move, function_types, optional, fusion, conversion
2021-05-03T15:38:07.4457882Z Installing: io, winapi, typeof, tuple
2021-05-03T15:38:07.4550744Z 
2021-05-03T15:38:07.4552427Z D:\a\1\s\boost-root>REM Bootstrap is not expecting B2_CXXFLAGS content so we zero it out for the bootstrap only 
2021-05-03T15:38:07.4553110Z 
2021-05-03T15:38:07.4553937Z D:\a\1\s\boost-root>SET OLD_B2_CXXFLAGS= 
2021-05-03T15:38:07.4561757Z 
2021-05-03T15:38:07.4587373Z D:\a\1\s\boost-root>SET B2_CXXFLAGS= 
2021-05-03T15:38:07.4593821Z 
2021-05-03T15:38:07.4602944Z D:\a\1\s\boost-root>cmd /c bootstrap 
2021-05-03T15:38:07.4813711Z Building Boost.Build engine
2021-05-03T15:38:07.5415184Z LOCALAPPDATA=C:\Users\VssAdministrator\AppData\Local
2021-05-03T15:38:08.6531537Z Found with vswhere C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise
2021-05-03T15:38:09.1071687Z Found with vswhere C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise
2021-05-03T15:38:09.1178011Z Call_If_Exists "C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\Tools\..\..\VC\Auxiliary\Build\vcvarsall.bat"  AMD64
2021-05-03T15:38:09.6166564Z **********************************************************************
2021-05-03T15:38:09.6168629Z ** Visual Studio 2019 Developer Command Prompt v16.9.4
2021-05-03T15:38:09.6169220Z ** Copyright (c) 2021 Microsoft Corporation
2021-05-03T15:38:09.6169662Z **********************************************************************
2021-05-03T15:38:11.7352721Z [vcvarsall.bat] Environment initialized for: 'x64'
2021-05-03T15:38:11.7921952Z ###
2021-05-03T15:38:11.7923653Z ### Using 'vc142' toolset.
2021-05-03T15:38:11.7943713Z ###
2021-05-03T15:38:11.8136413Z 
2021-05-03T15:38:11.8139884Z D:\a\1\s\boost-root\tools\build\src\engine>"cl" /nologo /MP /MT /TP /Feb2 /wd4996 /O2 /GL /EHsc   -DNDEBUG  builtins.cpp class.cpp command.cpp compile.cpp constants.cpp cwd.cpp debug.cpp debugger.cpp execcmd.cpp execnt.cpp filent.cpp filesys.cpp frames.cpp function.cpp glob.cpp hash.cpp hcache.cpp hdrmacro.cpp headers.cpp jam.cpp jamgram.cpp lists.cpp make.cpp make1.cpp md5.cpp mem.cpp modules.cpp native.cpp object.cpp option.cpp output.cpp parse.cpp pathnt.cpp pathsys.cpp regexp.cpp rules.cpp scan.cpp search.cpp jam_strings.cpp startup.cpp subst.cpp sysinfo.cpp timestamp.cpp variable.cpp w32_getreg.cpp modules/order.cpp modules/path.cpp modules/property-set.cpp modules/regex.cpp modules/sequence.cpp modules/set.cpp /link kernel32.lib advapi32.lib user32.lib 
2021-05-03T15:38:11.9801748Z builtins.cpp
2021-05-03T15:38:11.9946880Z class.cpp
2021-05-03T15:38:11.9975046Z command.cpp
2021-05-03T15:38:11.9976481Z compile.cpp
2021-05-03T15:38:16.1472846Z constants.cpp
2021-05-03T15:38:16.7632181Z cwd.cpp
2021-05-03T15:38:17.1782861Z debug.cpp
2021-05-03T15:38:17.4671890Z debugger.cpp
2021-05-03T15:38:17.6063153Z execcmd.cpp
2021-05-03T15:38:17.6336904Z execnt.cpp
2021-05-03T15:38:18.5183745Z filent.cpp
2021-05-03T15:38:18.8996688Z filesys.cpp
2021-05-03T15:38:18.9952330Z frames.cpp
2021-05-03T15:38:19.0596031Z function.cpp
2021-05-03T15:38:19.4325215Z glob.cpp
2021-05-03T15:38:19.8443368Z hash.cpp
2021-05-03T15:38:19.9511551Z hcache.cpp
2021-05-03T15:38:20.2492673Z hdrmacro.cpp
2021-05-03T15:38:20.4461308Z headers.cpp
2021-05-03T15:38:21.1002666Z jam.cpp
2021-05-03T15:38:21.2326278Z jamgram.cpp
2021-05-03T15:38:21.4962250Z lists.cpp
2021-05-03T15:38:21.8152124Z make.cpp
2021-05-03T15:38:22.4553267Z make1.cpp
2021-05-03T15:38:22.5354262Z md5.cpp
2021-05-03T15:38:22.5530620Z mem.cpp
2021-05-03T15:38:22.8341825Z modules.cpp
2021-05-03T15:38:22.9844391Z native.cpp
2021-05-03T15:38:22.9861913Z object.cpp
2021-05-03T15:38:23.4211619Z option.cpp
2021-05-03T15:38:23.7432119Z output.cpp
2021-05-03T15:38:23.8834482Z parse.cpp
2021-05-03T15:38:24.1671776Z pathnt.cpp
2021-05-03T15:38:24.3608524Z pathsys.cpp
2021-05-03T15:38:24.4132651Z regexp.cpp
2021-05-03T15:38:24.9321328Z rules.cpp
2021-05-03T15:38:25.1359735Z scan.cpp
2021-05-03T15:38:25.6568088Z search.cpp
2021-05-03T15:38:25.6661577Z jam_strings.cpp
2021-05-03T15:38:26.1251952Z startup.cpp
2021-05-03T15:38:26.2250082Z subst.cpp
2021-05-03T15:38:26.3053582Z sysinfo.cpp
2021-05-03T15:38:26.6395653Z timestamp.cpp
2021-05-03T15:38:26.6991558Z variable.cpp
2021-05-03T15:38:27.0261605Z w32_getreg.cpp
2021-05-03T15:38:28.9906409Z order.cpp
2021-05-03T15:38:29.0079859Z path.cpp
2021-05-03T15:38:29.0080638Z property-set.cpp
2021-05-03T15:38:29.0081093Z regex.cpp
2021-05-03T15:38:29.0081616Z sequence.cpp
2021-05-03T15:38:29.0082030Z set.cpp
2021-05-03T15:38:30.0099464Z Generating code
2021-05-03T15:38:36.1746464Z Finished generating code
2021-05-03T15:38:36.3953950Z 
2021-05-03T15:38:36.3955477Z D:\a\1\s\boost-root\tools\build\src\engine>dir *.exe 
2021-05-03T15:38:36.3963425Z  Volume in drive D is Temp
2021-05-03T15:38:36.3964359Z  Volume Serial Number is 92EE-8E72
2021-05-03T15:38:36.3964555Z 
2021-05-03T15:38:36.3965061Z  Directory of D:\a\1\s\boost-root\tools\build\src\engine
2021-05-03T15:38:36.3965419Z 
2021-05-03T15:38:36.3966068Z 05/03/2021  03:38 PM           531,456 b2.exe
2021-05-03T15:38:36.3967564Z                1 File(s)        531,456 bytes
2021-05-03T15:38:36.3968337Z                0 Dir(s)  14,529,425,408 bytes free
2021-05-03T15:38:36.3972255Z 
2021-05-03T15:38:36.3973535Z D:\a\1\s\boost-root\tools\build\src\engine>copy /b .\b2.exe .\bjam.exe 
2021-05-03T15:38:36.4017467Z         1 file(s) copied.
2021-05-03T15:38:36.4204488Z 
2021-05-03T15:38:36.4209785Z Generating Boost.Build configuration in project-config.jam for msvc...
2021-05-03T15:38:36.4419743Z 
2021-05-03T15:38:36.4420926Z Bootstrapping is done. To build, run:
2021-05-03T15:38:36.4445340Z 
2021-05-03T15:38:36.4452319Z     .\b2
2021-05-03T15:38:36.4475849Z 
2021-05-03T15:38:36.4510771Z     To generate header files, run:
2021-05-03T15:38:36.4511142Z 
2021-05-03T15:38:36.4513288Z     .\b2 headers
2021-05-03T15:38:36.4513666Z 
2021-05-03T15:38:36.4522145Z To adjust configuration, edit 'project-config.jam'.
2021-05-03T15:38:36.4527984Z Further information:
2021-05-03T15:38:36.4563303Z 
2021-05-03T15:38:36.4572929Z     - Command line help:
2021-05-03T15:38:36.4607733Z     .\b2 --help
2021-05-03T15:38:36.4619224Z      
2021-05-03T15:38:36.4623255Z     - Getting started guide: 
2021-05-03T15:38:36.4627866Z     http://boost.org/more/getting_started/windows.html
2021-05-03T15:38:36.4657154Z      
2021-05-03T15:38:36.4662302Z     - Boost.Build documentation:
2021-05-03T15:38:36.4666393Z     http://www.boost.org/build/
2021-05-03T15:38:36.4693884Z 
2021-05-03T15:38:36.4813664Z 
2021-05-03T15:38:36.4815561Z D:\a\1\s\boost-root>IF NOT 0 == 0 (
2021-05-03T15:38:36.4817388Z type bootstrap.log  
2021-05-03T15:38:36.4818953Z  EXIT /B 1 
2021-05-03T15:38:36.4819254Z ) 
2021-05-03T15:38:36.4819361Z 
2021-05-03T15:38:36.4819682Z D:\a\1\s\boost-root>SET B2_CXXFLAGS= 
2021-05-03T15:38:36.4819849Z 
2021-05-03T15:38:36.4820131Z D:\a\1\s\boost-root>b2 headers 
2021-05-03T15:38:41.6572692Z Performing configuration checks
2021-05-03T15:38:41.6573151Z 
2021-05-03T15:38:41.6573763Z     - default address-model    : 64-bit [1]
2021-05-03T15:38:42.6934210Z     - default architecture     : x86 [1]
2021-05-03T15:38:42.7496071Z     - symlinks supported       : yes
2021-05-03T15:38:43.1554088Z 
2021-05-03T15:38:43.1557037Z [1] msvc-14.2
2021-05-03T15:38:43.1746498Z ...found 325 targets...
2021-05-03T15:38:43.1747209Z ...updating 151 targets...
2021-05-03T15:38:43.1747564Z mklink-or-dir boost
2021-05-03T15:38:43.1942437Z mklink-or-dir boost\assert
2021-05-03T15:38:43.1948244Z symbolic link created for boost\assert <<===>> ..\libs\assert\include\boost\assert
[...]
2021-05-03T15:38:44.0359562Z ...updated 151 targets...
2021-05-03T15:38:44.0412956Z 
2021-05-03T15:38:44.0413767Z D:\a\1\s\boost-root>if DEFINED B2_CI_VERSION (
2021-05-03T15:38:44.0414425Z REM Go back to lib folder to allow ci\build.bat to work  
2021-05-03T15:38:44.0415044Z  cd libs\my_repo_name 
2021-05-03T15:38:44.0415620Z ) 
2021-05-03T15:38:44.0421295Z 
2021-05-03T15:38:44.0422043Z D:\a\1\s\boost-root>REM Persist variables 
2021-05-03T15:38:44.0779033Z ##[section]Finishing: Windows: Install Boost
-- Configuring incomplete, errors occurred!
CMake Error at C:/Program Files/CMake/share/cmake-3.20/Modules/FindPackageHandleStandardArgs.cmake:230 (message):
  Could NOT find Boost (missing: regex) (found suitable version "1.77.0",
See also "D:/a/1/s/build/CMakeFiles/CMakeOutput.log".
See also "D:/a/1/s/build/CMakeFiles/CMakeError.log".
  minimum required is "1.54.0")
Call Stack (most recent call first):
  C:/Program Files/CMake/share/cmake-3.20/Modules/FindPackageHandleStandardArgs.cmake:594 (_FPHSA_FAILURE_MESSAGE)
  C:/Program Files/CMake/share/cmake-3.20/Modules/FindBoost.cmake:2344 (find_package_handle_standard_args)
  CMakeLists.txt:32 (FIND_PACKAGE)