i18n: QT_TRANSLATIONS_DIR hasn't been set since Qt 5.3.

None of the Qt translations are found, nor shipped along with the
Calamares translations; it depends on the translations of Qt
on the live system. The mechanism was broken, anyway, by the
split into qt_<foo>.qm and qtbase_<foo>.qm, and the introduction
for QPT for the translation of standard button texts.

Just drop the special code looking for Qt translations and the
rcc hacks that entails.

FIXES #336
This commit is contained in:
Adriaan de Groot 2017-06-29 06:25:49 -04:00
parent 5cd328dad3
commit 611cb1f94c

View File

@ -7,12 +7,6 @@ macro(add_calamares_translations language)
set( calamares_i18n_qrc_content "${calamares_i18n_qrc_content}<qresource prefix=\"/lang\">\n" ) set( calamares_i18n_qrc_content "${calamares_i18n_qrc_content}<qresource prefix=\"/lang\">\n" )
foreach( lang ${CALAMARES_LANGUAGES} ) foreach( lang ${CALAMARES_LANGUAGES} )
set( calamares_i18n_qrc_content "${calamares_i18n_qrc_content}<file>calamares_${lang}.qm</file>\n" ) set( calamares_i18n_qrc_content "${calamares_i18n_qrc_content}<file>calamares_${lang}.qm</file>\n" )
if( NOT lang STREQUAL "en" AND EXISTS ${QT_TRANSLATIONS_DIR}/qt_${lang}.qm )
file( COPY ${QT_TRANSLATIONS_DIR}/qt_${lang}.qm DESTINATION ${CMAKE_CURRENT_BINARY_DIR} )
set( calamares_i18n_qrc_content "${calamares_i18n_qrc_content}<file>qt_${lang}.qm</file>\n" )
endif()
# build explicitly enabled languages
list( APPEND TS_FILES "${CMAKE_SOURCE_DIR}/lang/calamares_${lang}.ts" ) list( APPEND TS_FILES "${CMAKE_SOURCE_DIR}/lang/calamares_${lang}.ts" )
endforeach() endforeach()