Skip to content

[MSVC][std:c++latest] openFrameworks failed to build on MSVC #6832

@xiaoxiao-Xu

Description

@xiaoxiao-Xu

Hi All,

The MSVC team recently added openFrameworks as part of RWC testing to detect compiler regressions. And we found some errors when building openFrameworks with '/std:c++latest'. Could you please help look at this issue or provide some workarounds? Thanks in advance.

Repro steps:

1. git clone https://github.com/openframeworks/openFrameworks F:\gitP\openframeworks\openFrameworks
2. mkdir F:\gitP\openframeworks\openFrameworks\build_amd64
3. cd F:\gitP\openframeworks\openFrameworks\build_amd64
4. set _CL_= /std:c++latest
5. msbuild /m /p:Platform=x64 /p:Configuration=Release ../libs/openFrameworksCompiled/project/vs/openframeworksLib.vcxproj /t:Rebuild /p:OutDir=F:\gitP\openframeworks\openFrameworks\build_amd64 /p:PlatformToolset=v142

Build log:
build.log

Error info:

C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\VC\Tools\MSVC\14.29.30133\include\chrono(3313,22): error C2757: 'filesystem': a symbol with this name already exists and therefore this name cannot be used as a namespace name (compiling source file ..\..\..\openFrameworks\3d\ofCamera.cpp)
C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\VC\Tools\MSVC\14.29.30133\include\chrono(3318,36): error C2039: '_File_time_clock': is not a member of 'boost::filesystem' (compiling source file ..\..\..\openFrameworks\3d\ofCamera.cpp)
C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\VC\Tools\MSVC\14.29.30133\include\chrono(3318,52): error C2061: syntax error: identifier '_File_time_clock' (compiling source file ..\..\..\openFrameworks\3d\ofCamera.cpp)
C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\VC\Tools\MSVC\14.29.30133\include\chrono(3313,22): error C2757: 'filesystem': a symbol with this name already exists and therefore this name cannot be used as a namespace name (compiling source file ..\..\..\openFrameworks\app\ofMainLoop.cpp)
C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\VC\Tools\MSVC\14.29.30133\include\chrono(3321,34): error C2065: 'file_clock': undeclared identifier (compiling source file ..\..\..\openFrameworks\3d\ofCamera.cpp)
C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\VC\Tools\MSVC\14.29.30133\include\chrono(3318,36): error C2039: '_File_time_clock': is not a member of 'boost::filesystem' (compiling source file ..\..\..\openFrameworks\app\ofMainLoop.cpp)
C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\VC\Tools\MSVC\14.29.30133\include\chrono(3321,23): error C2923: 'std::chrono::time_point': 'file_clock' is not a valid template type argument for parameter '_Clock' (compiling source file ..\..\..\openFrameworks\3d\ofCamera.cpp) 
C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\VC\Tools\MSVC\14.29.30133\include\chrono(3318,52): error C2061: syntax error: identifier '_File_time_clock' (compiling source file ..\..\..\openFrameworks\app\ofMainLoop.cpp)
C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\VC\Tools\MSVC\14.29.30133\include\chrono(3321,34): error C2065: 'file_clock': undeclared identifier (compiling source file ..\..\..\openFrameworks\app\ofMainLoop.cpp)
C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\VC\Tools\MSVC\14.29.30133\include\chrono(3321,11): error C2955: 'std::chrono::time_point': use of class template requires template argument list (compiling source file ..\..\..\openFrameworks\3d\ofCamera.cpp)
C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\VC\Tools\MSVC\14.29.30133\include\chrono(3321,23): error C2923: 'std::chrono::time_point': 'file_clock' is not a valid template type argument for parameter '_Clock' (compiling source file ..\..\..\openFrameworks\app\ofMainLoop.cpp)
C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\VC\Tools\MSVC\14.29.30133\include\chrono(3321,34): error C3861: 'file_clock': identifier not found (compiling source file ..\..\..\openFrameworks\3d\ofCamera.cpp)
C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\VC\Tools\MSVC\14.29.30133\include\chrono(3326,22): error C2757: 'filesystem': a symbol with this name already exists and therefore this name cannot be used as a namespace name (compiling source file ..\..\..\openFrameworks\3d\ofCamera.cpp)
C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\VC\Tools\MSVC\14.29.30133\include\chrono(3321,11): error C2955: 'std::chrono::time_point': use of class template requires template argument list (compiling source file ..\..\..\openFrameworks\app\ofMainLoop.cpp)
C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\VC\Tools\MSVC\14.29.30133\include\chrono(3321,34): error C3861: 'file_clock': identifier not found (compiling source file ..\..\..\openFrameworks\app\ofMainLoop.cpp)

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions