autodetect system language on MacOS

This commit is contained in:
Ryu481 2025-07-03 20:42:45 +02:00 committed by GitHub
commit 31a9f91961
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -33,7 +33,6 @@ endif()
add_executable(qbt_app)
# Generate lproj folders for the translations
set(LPROJ_FOLDERS "")
foreach(TS_FILE IN LISTS QBT_TS_FILES)
string(FIND "${TS_FILE}" "_" POS)
math(EXPR START "${POS} + 1")
@ -41,9 +40,6 @@ foreach(TS_FILE IN LISTS QBT_TS_FILES)
string(REPLACE ".ts" ".lproj" LPROJ_FOLDER "${LPROJ_FOLDER}")
# @ is not valid as a language code for a lproj folder on MacOS
string(REPLACE "@" "-" LPROJ_FOLDER "${LPROJ_FOLDER}")
list(APPEND LPROJ_FOLDERS "${LPROJ_FOLDER}")
endforeach()
foreach(LPROJ_FOLDER IN LISTS LPROJ_FOLDERS)
add_custom_command(
TARGET qbt_app
POST_BUILD