X-Git-Url: https://git.quassel-irc.org/?p=quassel.git;a=blobdiff_plain;f=po%2FCMakeLists.txt;h=0616948e6edfce28e54e85ccc68992fa82f4bf23;hp=9f8b2b274697ebaeaa74e11996c3639e5154efbf;hb=d68e9d67200abc51123b357bcdbbc816d4a70791;hpb=f8de7b607c3e168996138cbc5e1cfca18254ba09 diff --git a/po/CMakeLists.txt b/po/CMakeLists.txt index 9f8b2b27..0616948e 100644 --- a/po/CMakeLists.txt +++ b/po/CMakeLists.txt @@ -33,18 +33,20 @@ else(QT_LCONVERT_EXECUTABLE) message(STATUS "WARNING: lconvert not found, you won't have translations!") endif(QT_LCONVERT_EXECUTABLE) -# For a static build, we need to include Qt translations if available -if(STATIC AND QT_TRANSLATIONS_DIR) - foreach(LANG ${gen_linguas}) - file(GLOB lang_files ${QT_TRANSLATIONS_DIR}/qt_${LANG}*.qm) - foreach(absfile ${lang_files}) - get_filename_component(filename ${absfile} NAME) - message(STATUS "Importing ${filename}") - configure_file(${absfile} ${CMAKE_CURRENT_BINARY_DIR}/${filename} COPYONLY) - list(APPEND qm_files ${CMAKE_CURRENT_BINARY_DIR}/${filename}) - endforeach(absfile ${lang_files}) - endforeach(LANG ${gen_linguas}) -endif(STATIC AND QT_TRANSLATIONS_DIR) +# For a static or win32 build, we need to include Qt translations if available +if(QT_TRANSLATIONS_DIR) + if(STATIC OR WIN32) + foreach(LANG ${gen_linguas}) + file(GLOB lang_files ${QT_TRANSLATIONS_DIR}/qt_${LANG}*.qm) + foreach(absfile ${lang_files}) + get_filename_component(filename ${absfile} NAME) + message(STATUS "Importing ${filename}") + configure_file(${absfile} ${CMAKE_CURRENT_BINARY_DIR}/${filename} COPYONLY) + list(APPEND qm_files ${CMAKE_CURRENT_BINARY_DIR}/${filename}) + endforeach(absfile ${lang_files}) + endforeach(LANG ${gen_linguas}) + endif(STATIC OR WIN32) +endif(QT_TRANSLATIONS_DIR) # Write resource file set(resfile ${CMAKE_CURRENT_BINARY_DIR}/i18n.qrc) @@ -62,7 +64,9 @@ set_directory_properties(PROPERTIES ADDITIONAL_MAKE_CLEAN_FILES "${qm_files};i18 if(EMBED_DATA) set(COMMON_RCS ${COMMON_RCS} ${resfile} PARENT_SCOPE) else(EMBED_DATA) - install(FILES ${qm_files} DESTINATION ${DATA_INSTALL_DIR}/quassel/translations) + install(FILES ${qm_files} DESTINATION ${CMAKE_INSTALL_DATADIR}/quassel/translations) endif(EMBED_DATA) add_custom_target(po DEPENDS ${qm_files}) + +