The intro.cpp for V2 does not compile in MSVC 19.34.31937.0
- Dominant language
- C++
- Stars
- 145
- Forks
- 151
- PR merge metrics
- No merged PRs in 30d
Description
I tried compiling the example file intro.cpp in the example folder for v2 using the following setup:
CMake project using vcpkg to import Boost Process 1.81. Compiled using MSVC 19.34.31937.0.
The compiler output is the following:
```
>------ Build All started: Project: process_v2, Configuration: x64-debug ------
[1/2] Building CXX object process_v2\CMakeFiles\process_v2.dir\process_v2.cpp.obj
FAILED: process_v2/CMakeFiles/process_v2.dir/process_v2.cpp.obj
C:\PROGRA~1\MIB055~1\2022\COMMUN~1\VC\Tools\MSVC\1434~1.319\bin\Hostx64\x64\cl.exe /nologo /TP -external:I%LocalPath%\process_v2\out\build\x64-debug\vcpkg_installed\x64-windows\include -external:W0 /DWIN32 /D_WINDOWS /W3 /GR /EHsc /MDd /Zi /Ob0 /Od /RTC1 -std:c++20 /showIncludes /Foprocess_v2\CMakeFiles\process_v2.dir\process_v2.cpp.obj /Fdprocess_v2\CMakeFiles\process_v2.dir\ /FS -c %LocalPath%\process_v2\process_v2\process_v2.cpp
Please define _WIN32_WINNT or _WIN32_WINDOWS appropriately. For example:
- add -D_WIN32_WINNT=0x0601 to the compiler command line; or
- add _WIN32_WINNT=0x0601 to your project's Preprocessor Definitions.
Assuming _WIN32_WINNT=0x0601 (i.e. Windows 7 target).
%LocalPath%\process_v2\out\build\x64-debug\vcpkg_installed\x64-windows\include\boost\process\v2\environment.hpp(504): error C2065: 'source': undeclared identifier
%LocalPath%\process_v2\out\build\x64-debug\vcpkg_installed\x64-windows\include\boost\process\v2\environment.hpp(505): error C2065: 'source': undeclared identifier
%LocalPath%\process_v2\out\build\x64-debug\vcpkg_installed\x64-windows\include\boost\process\v2\environment.hpp(723): error C2065: 'source': undeclared identifier
%LocalPath%\process_v2\out\build\x64-debug\vcpkg_installed\x64-windows\include\boost\process\v2\environment.hpp(724): error C2065: 'source': undeclared identifier
%LocalPath%\process_v2\out\build\x64-debug\vcpkg_installed\x64-windows\include\boost\process\v2\environment.hpp(969): error C2065: 'source': undeclared identifier
%LocalPath%\process_v2\out\build\x64-debug\vcpkg_installed\x64-windows\include\boost\process\v2\environment.hpp(970): error C2065: 'source': undeclared identifier
%LocalPath%\process_v2\out\build\x64-debug\vcpkg_installed\x64-windows\include\boost\process\v2\environment.hpp(1734): error C2664: 'std::vector> boost::process::v2::process_environment::build_env&>(Args,void *)': cannot convert argument 2 from 'const char [1]' to 'void *'
with
[
Args=std::initializer_list &
]
%LocalPath%\process_v2\out\build\x64-debug\vcpkg_installed\x64-windows\include\boost/process/v2/environment.hpp(1734): note: Conversion loses qualifiers
%LocalPath%\process_v2\out\build\x64-debug\vcpkg_installed\x64-windows\include\boost/process/v2/environment.hpp(1723): note: see declaration of 'boost::process::v2::process_environment::build_env'
%LocalPath%\process_v2\out\build\x64-debug\vcpkg_installed\x64-windows\include\boost/process/v2/environment.hpp(1702): note: could be 'std::vector> boost::process::v2::process_environment::build_env(Args &&,std::enable_if::value,void>::type *)'
%LocalPath%\process_v2\out\build\x64-debug\vcpkg_installed\x64-windows\include\boost/process/v2/environment.hpp(1734): note: Failed to specialize function template 'std::vector> boost::process::v2::process_environment::build_env(Args &&,std::enable_if::value,void>::type *)'
%LocalPath%\process_v2\out\build\x64-debug\vcpkg_installed\x64-windows\include\boost/process/v2/environment.hpp(1734): note: With the following template arguments:
%LocalPath%\process_v2\out\build\x64-debug\vcpkg_installed\x64-windows\include\boost/process/v2/environment.hpp(1734): note: 'Args=std::initializer_list &'
%LocalPath%\process_v2\out\build\x64-debug\vcpkg_installed\x64-windows\include\boost/process/v2/environment.hpp(1734): note: while trying to match the argument list '(std::initializer_list, const char [1])'
%LocalPath%\process_v2\out\build\x64-debug\vcpkg_installed\x64-windows\include\boost\process\v2\environment.hpp(1735): error C2664: 'std::vector> boost::process::v2::process_environment::build_env>>&>(Args,void *)': cannot convert argument 2 from 'const wchar_t [1]' to 'void *'
with
[
Args=std::initializer_list>> &
]
%LocalPath%\process_v2\out\build\x64-debug\vcpkg_installed\x64-windows\include\boost/process/v2/environment.hpp(1735): note: Conversion loses qualifiers
%LocalPath%\process_v2\out\build\x64-debug\vcpkg_installed\x64-windows\include\boost/process/v2/environment.hpp(1723): note: see declaration of 'boost::process::v2::process_environment::build_env'
%LocalPath%\process_v2\out\build\x64-debug\vcpkg_installed\x64-windows\include\boost/process/v2/environment.hpp(1702): note: could be 'std::vector> boost::process::v2::process_environment::build_env(Args &&,std::enable_if::value,void>::type *)'
%LocalPath%\process_v2\out\build\x64-debug\vcpkg_installed\x64-windows\include\boost/process/v2/environment.hpp(1735): note: Failed to specialize function template 'std::vector> boost::process::v2::process_environment::build_env(Args &&,std::enable_if::value,void>::type *)'
%LocalPath%\process_v2\out\build\x64-debug\vcpkg_installed\x64-windows\include\boost/process/v2/environment.hpp(1735): note: With the following template arguments:
%LocalPath%\process_v2\out\build\x64-debug\vcpkg_installed\x64-windows\include\boost/process/v2/environment.hpp(1735): note: 'Args=std::initializer_list>> &'
%LocalPath%\process_v2\out\build\x64-debug\vcpkg_installed\x64-windows\include\boost/process/v2/environment.hpp(1735): note: while trying to match the argument list '(std::initializer_list>>, const wchar_t [1])'
ninja: build stopped: subcommand failed.
Build All failed.
```
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.