From b5b42a570a9268f4237b0cc3b1814b5c1266bc3f Mon Sep 17 00:00:00 2001 From: tamasmeszaros Date: Wed, 27 Apr 2022 17:18:28 +0200 Subject: [PATCH] Force utf8 encoding for wxString in all Unix-like platforms --- deps/wxWidgets/wxWidgets.cmake | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/deps/wxWidgets/wxWidgets.cmake b/deps/wxWidgets/wxWidgets.cmake index 1ca6735cc..293942568 100644 --- a/deps/wxWidgets/wxWidgets.cmake +++ b/deps/wxWidgets/wxWidgets.cmake @@ -9,6 +9,11 @@ if(CMAKE_SYSTEM_NAME STREQUAL "Linux") set(_wx_toolkit "-DwxBUILD_TOOLKIT=gtk${_gtk_ver}") endif() +set(_unicode_utf8 OFF) +if (UNIX) # wxWidgets will not use char as the underlying type for wxString unless its forced to. + set (_unicode_utf8 ON) +endif() + prusaslicer_add_cmake_project(wxWidgets # GIT_REPOSITORY "https://github.com/prusa3d/wxWidgets" # GIT_TAG tm_cross_compile #${_wx_git_tag} @@ -23,6 +28,7 @@ prusaslicer_add_cmake_project(wxWidgets -DwxUSE_MEDIACTRL=OFF -DwxUSE_DETECT_SM=OFF -DwxUSE_UNICODE=ON + -DwxUSE_UNICODE_UTF8=${_unicode_utf8} -DwxUSE_OPENGL=ON -DwxUSE_LIBPNG=sys -DwxUSE_ZLIB=sys