commit dbfb3f4e13c611a57c4bdfde7e0828ea6abd2817
Author: Scott Kostyshak <[email protected]>
Date: Tue Jul 22 10:29:33 2025 +0200
ctests: fix check_load tests on newer Qt 6
On Qt 6.8.3, all check_load tests would fail with something like the
following:
-- Executing bin/lyx -batch -userdir "Testing/.lyx"
/path/to/repo/lib/examples/Welcome.lyx
-- Error code of lyx = 0
-- Error line = Detected locale "C" with character encoding
"ANSI_X3.4-1968", which is not UTF-8.
-- Error line = Qt depends on a UTF-8 locale, and has switched to "C.UTF-8"
instead.
-- Error line = If this causes problems, reconfigure your locale. See the
locale(1) manual
-- Error line = for more information.
CMake Error at /path/to/repo/development/autotests/check_load.cmake:47
(message):
lyx gave warnings/errors:
Detected locale "C" with character encoding "ANSI_X3.4-1968", which is not
UTF-8.
Qt depends on a UTF-8 locale, and has switched to "C.UTF-8" instead.
If this causes problems, reconfigure your locale. See the locale(1)
manual
for more information.
I checked the check_load tests work with the patch with both
Qt 6.8.3 and Qt 6.4.2.
---
development/autotests/check_load.cmake | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/development/autotests/check_load.cmake
b/development/autotests/check_load.cmake
index 0a0d35154b..92bb7a7a24 100644
--- a/development/autotests/check_load.cmake
+++ b/development/autotests/check_load.cmake
@@ -20,7 +20,7 @@
message(STATUS "Executing ${lyx} -batch -userdir \"${LYX_TESTS_USERDIR}\"
${LYXFILE}")
set(ENV{${LYX_USERDIR_VER}} "${LYX_TESTS_USERDIR}")
-set(ENV{LANG} "en") # to get all error-messages in english
+set(ENV{LANG} "en_US.UTF-8") # to get all error-messages in english
execute_process(
COMMAND ${lyx} -batch -userdir "${LYX_TESTS_USERDIR}" ${LYXFILE}
--
lyx-cvs mailing list
[email protected]
https://lists.lyx.org/mailman/listinfo/lyx-cvs