Closed
Description
Describe your problem here.
Hello there~. I encountered a problem when compiling the reposity in vs2017
what i have done are below:
- I used
git clone --recurse-submodules xxx
to access your reposity - using vs2017 to open the solution
msvc14/log4cplus.sln
- right click the log4cplus solution and set it my launch project
- right click the log4jcplus -> Property -> C++ -> language -> C++ stardand -> /std:c++17
- generate the solution
but i keeps telling me this deprecated error:
1>d:\gitwork\log4cplus\src\property.cxx(146): error C4996: 'std::codecvt_mode': warning STL4017: std::wbuffer_convert, std::wstring_convert, and the <codecvt> header (containing std::codecvt_mode, std::codecvt_utf8, std::codecvt_utf16, and std::codecvt_utf8_utf16) are deprecated in C++17. (The std::codecvt class template is NOT deprecated.) The C++ Standard doesn't provide equivalent non-deprecated functionality; consider using MultiByteToWideChar() and WideCharToMultiByte() from <Windows.h> instead. You can define _SILENCE_CXX17_CODECVT_HEADER_DEPRECATION_WARNING or _SILENCE_ALL_CXX17_DEPRECATION_WARNINGS to acknowledge that you have received this warning.
1>d:\software\visualstudio\2017\community\vc\tools\msvc\14.16.27023\include\codecvt(24): note: reference to “std::codecvt_mode” declaration
1>d:\gitwork\log4cplus\src\property.cxx(146): error C4996: 'std::codecvt_utf8<log4cplus::tchar,1114111,5>': warning STL4017: std::wbuffer_convert, std::wstring_convert, and the <codecvt> header (containing std::codecvt_mode, std::codecvt_utf8, std::codecvt_utf16, and std::codecvt_utf8_utf16) are deprecated in C++17. (The std::codecvt class template is NOT deprecated.) The C++ Standard doesn't provide equivalent non-deprecated functionality; consider using MultiByteToWideChar() and WideCharToMultiByte() from <Windows.h> instead. You can define _SILENCE_CXX17_CODECVT_HEADER_DEPRECATION_WARNING or _SILENCE_ALL_CXX17_DEPRECATION_WARNINGS to acknowledge that you have received this warning.
1>d:\gitwork\log4cplus\src\property.cxx(145): note: reference to “std::codecvt_utf8<log4cplus::tchar,1114111,5>” declaration
1>d:\gitwork\log4cplus\src\property.cxx(155): error C4996: 'std::codecvt_mode': warning STL4017: std::wbuffer_convert, std::wstring_convert, and the <codecvt> header (containing std::codecvt_mode, std::codecvt_utf8, std::codecvt_utf16, and std::codecvt_utf8_utf16) are deprecated in C++17. (The std::codecvt class template is NOT deprecated.) The C++ Standard doesn't provide equivalent non-deprecated functionality; consider using MultiByteToWideChar() and WideCharToMultiByte() from <Windows.h> instead. You can define _SILENCE_CXX17_CODECVT_HEADER_DEPRECATION_WARNING or _SILENCE_ALL_CXX17_DEPRECATION_WARNINGS to acknowledge that you have received this warning.
1>d:\software\visualstudio\2017\community\vc\tools\msvc\14.16.27023\include\codecvt(24): note: reference to “std::codecvt_mode” declaration
1>d:\gitwork\log4cplus\src\property.cxx(155): error C4996: 'std::codecvt_utf16<log4cplus::tchar,1114111,5>': warning STL4017: std::wbuffer_convert, std::wstring_convert, and the <codecvt> header (containing std::codecvt_mode, std::codecvt_utf8, std::codecvt_utf16, and std::codecvt_utf8_utf16) are deprecated in C++17. (The std::codecvt class template is NOT deprecated.) The C++ Standard doesn't provide equivalent non-deprecated functionality; consider using MultiByteToWideChar() and WideCharToMultiByte() from <Windows.h> instead. You can define _SILENCE_CXX17_CODECVT_HEADER_DEPRECATION_WARNING or _SILENCE_ALL_CXX17_DEPRECATION_WARNINGS to acknowledge that you have received this warning.
1>d:\gitwork\log4cplus\src\property.cxx(154): note: reference to “std::codecvt_utf16<log4cplus::tchar,1114111,5>” declaration
1>d:\gitwork\log4cplus\src\property.cxx(145): error C4996: 'std::codecvt_utf8<log4cplus::tchar,1114111,5>::codecvt_utf8': warning STL4017: std::wbuffer_convert, std::wstring_convert, and the <codecvt> header (containing std::codecvt_mode, std::codecvt_utf8, std::codecvt_utf16, and std::codecvt_utf8_utf16) are deprecated in C++17. (The std::codecvt class template is NOT deprecated.) The C++ Standard doesn't provide equivalent non-deprecated functionality; consider using MultiByteToWideChar() and WideCharToMultiByte() from <Windows.h> instead. You can define _SILENCE_CXX17_CODECVT_HEADER_DEPRECATION_WARNING or _SILENCE_ALL_CXX17_DEPRECATION_WARNINGS to acknowledge that you have received this warning.
1>d:\software\visualstudio\2017\community\vc\tools\msvc\14.16.27023\include\codecvt(48): note: reference to “std::codecvt_utf8<log4cplus::tchar,1114111,5>::codecvt_utf8” declaration
1>d:\gitwork\log4cplus\src\property.cxx(154): error C4996: 'std::codecvt_utf16<log4cplus::tchar,1114111,5>::codecvt_utf16': warning STL4017: std::wbuffer_convert, std::wstring_convert, and the <codecvt> header #(containing std::codecvt_mode, std::codecvt_utf8, std::codecvt_utf16, and std::codecvt_utf8_utf16) are deprecated in C++17. (The std::codecvt class template is NOT deprecated.) The C++ Standard doesn't provide equivalent non-deprecated functionality; consider using MultiByteToWideChar() and WideCharToMultiByte() from <Windows.h> instead. You can define _SILENCE_CXX17_CODECVT_HEADER_DEPRECATION_WARNING or _SILENCE_ALL_CXX17_DEPRECATION_WARNINGS to acknowledge that you have received this warning.
I don't what went wrong~
Also, provide the following information:
- version: log4cplus 2.0.3
- operating system, CPU, bitness: WINDOWS 10 64bits, CPU: Intel i5-8250U
configure
script, or CMake, etc., flags and settings: using vs2017- flags and settings used by your application: /std:c++17
@ #