windows: remove deprecated codecvt via UTF-8 narrow APIs

Drop wstring_convert/codecvt and the
related wide process calls (_wsystem, _wexecvp, CreateProcessW)
in favor of ::system, _execvp, and CreateProcess.
This commit is contained in:
kevkevinpal
2026-07-11 10:22:19 -04:00
parent b388674acf
commit 6b6d77cc84
5 changed files with 32 additions and 46 deletions

View File

@@ -24,8 +24,7 @@ endif()
# Even though ::system is part of the standard library, we still check
# for it, to support building targets that don't have it, such as iOS.
check_cxx_symbol_exists(std::system "cstdlib" HAVE_STD_SYSTEM)
check_cxx_symbol_exists(::_wsystem "stdlib.h" HAVE__WSYSTEM)
if(HAVE_STD_SYSTEM OR HAVE__WSYSTEM)
if(HAVE_STD_SYSTEM)
set(HAVE_SYSTEM 1)
endif()