From: Giuseppe Bilotta Date: Fri, 22 Jul 2011 05:48:22 +0000 (+0200) Subject: Merge remote-tracking branch 'erlehmann/master' X-Git-Tag: 0.2.20110922~81^2~35^2~5^2~6 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=02653573d27efa13d8590504a8d30866fe5b093e;p=oweals%2Fminetest.git Merge remote-tracking branch 'erlehmann/master' Conflicts (from the introduction of fr translations): src/CMakeLists.txt --- 02653573d27efa13d8590504a8d30866fe5b093e diff --cc src/CMakeLists.txt index 8c6e1d450,532ac9fee..f3dee7f30 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@@ -266,10 -256,9 +266,11 @@@ if(BUILD_CLIENT install(FILES ${images} DESTINATION ${DATADIR}) - install(FILES ${CMAKE_BINARY_DIR}/locale/de/LC_MESSAGES/minetest-c55.mo DESTINATION locale/de/LC_MESSAGES) - install(FILES ${CMAKE_BINARY_DIR}/locale/fr/LC_MESSAGES/minetest-c55.mo DESTINATION locale/fr/LC_MESSAGES) - + if (USE_GETTEXT) + install(FILES ${CMAKE_BINARY_DIR}/locale/de/LC_MESSAGES/minetest-delta.mo DESTINATION locale/de/LC_MESSAGES) ++ install(FILES ${CMAKE_BINARY_DIR}/locale/fr/LC_MESSAGES/minetest-c55.mo DESTINATION locale/fr/LC_MESSAGES) + endif() + if(WIN32) if(DEFINED IRRLICHT_DLL) install(FILES ${IRRLICHT_DLL} DESTINATION ${BINDIR}) @@@ -289,23 -274,42 +290,35 @@@ endif(BUILD_CLIENT) if(BUILD_SERVER) - install(TARGETS minetestserver DESTINATION ${BINDIR}) + install(TARGETS ${PROJECT_NAME}server DESTINATION ${BINDIR}) endif(BUILD_SERVER) -if(WIN32) - set(GETTEXT_MSGFMT "${GETTEXT_BIN_DIR}/msgfmt" CACHE FILEPATH "path to msgfmt") -elseif(APPLE) - set(GETTEXT_MSGFMT "${GETTEXT_BIN_DIR}/msgfmt" CACHE FILEPATH "path to msgfmt") -else() - set(GETTEXT_MSGFMT "msgfmt") -endif() - -add_custom_command(OUTPUT ${CMAKE_BINARY_DIR}/locale/de/LC_MESSAGES COMMAND ${CMAKE_COMMAND} -E make_directory ${CMAKE_BINARY_DIR}/locale/de/LC_MESSAGES COMMENT "mo-update [de]: Creating locale directory.") -add_custom_command(OUTPUT ${CMAKE_BINARY_DIR}/locale/fr/LC_MESSAGES COMMAND ${CMAKE_COMMAND} -E make_directory ${CMAKE_BINARY_DIR}/locale/fr/LC_MESSAGES COMMENT "mo-update [fr]: Creating locale directory.") - -add_custom_command( - OUTPUT ${CMAKE_BINARY_DIR}/locale/de/LC_MESSAGES/minetest-c55.mo - COMMAND ${GETTEXT_MSGFMT} -o ${CMAKE_BINARY_DIR}/locale/de/LC_MESSAGES/minetest-c55.mo ${CMAKE_SOURCE_DIR}/po/de/minetest-c55.po - DEPENDS - ${CMAKE_BINARY_DIR}/locale/de/LC_MESSAGES - ${CMAKE_SOURCE_DIR}/po/de/minetest-c55.po - WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}/po/de - COMMENT "mo-update [de]: Creating mo file." - ) -add_custom_command( - OUTPUT ${CMAKE_BINARY_DIR}/locale/fr/LC_MESSAGES/minetest-c55.mo - COMMAND ${GETTEXT_MSGFMT} -o ${CMAKE_BINARY_DIR}/locale/fr/LC_MESSAGES/minetest-c55.mo ${CMAKE_SOURCE_DIR}/po/fr/minetest-c55.po - DEPENDS - ${CMAKE_BINARY_DIR}/locale/fr/LC_MESSAGES - ${CMAKE_SOURCE_DIR}/po/fr/minetest-c55.po - WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}/po/fr - COMMENT "mo-update [fr]: Creating mo file." - ) - -add_custom_target(translation_de ALL COMMENT "mo update [de]" DEPENDS ${CMAKE_BINARY_DIR}/locale/de/LC_MESSAGES/minetest-c55.mo) -add_custom_target(translation_fr ALL COMMENT "mo update [fr]" DEPENDS ${CMAKE_BINARY_DIR}/locale/fr/LC_MESSAGES/minetest-c55.mo) +if (USE_GETTEXT) + add_custom_command(OUTPUT ${CMAKE_BINARY_DIR}/locale/de/LC_MESSAGES COMMAND ${CMAKE_COMMAND} -E make_directory ${CMAKE_BINARY_DIR}/locale/de/LC_MESSAGES COMMENT "mo-update [de]: Creating locale directory.") ++ add_custom_command(OUTPUT ${CMAKE_BINARY_DIR}/locale/fr/LC_MESSAGES COMMAND ${CMAKE_COMMAND} -E make_directory ${CMAKE_BINARY_DIR}/locale/fr/LC_MESSAGES COMMENT "mo-update [fr]: Creating locale directory.") + + add_custom_command( + OUTPUT ${CMAKE_BINARY_DIR}/locale/de/LC_MESSAGES/minetest-delta.mo + COMMAND ${GETTEXT_MSGFMT} -o ${CMAKE_BINARY_DIR}/locale/de/LC_MESSAGES/minetest-delta.mo ${CMAKE_SOURCE_DIR}/po/de/minetest-c55.po + DEPENDS + ${CMAKE_BINARY_DIR}/locale/de/LC_MESSAGES + ${CMAKE_SOURCE_DIR}/po/de/minetest-c55.po + WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}/po/de + COMMENT "mo-update [de]: Creating mo file." + ) ++ add_custom_command( ++ OUTPUT ${CMAKE_BINARY_DIR}/locale/fr/LC_MESSAGES/minetest-c55.mo ++ COMMAND ${GETTEXT_MSGFMT} -o ${CMAKE_BINARY_DIR}/locale/fr/LC_MESSAGES/minetest-c55.mo ${CMAKE_SOURCE_DIR}/po/fr/minetest-c55.po ++ DEPENDS ++ ${CMAKE_BINARY_DIR}/locale/fr/LC_MESSAGES ++ ${CMAKE_SOURCE_DIR}/po/fr/minetest-c55.po ++ WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}/po/fr ++ COMMENT "mo-update [fr]: Creating mo file." ++ ) + + add_custom_target(translation_de ALL COMMENT "mo update [de]" DEPENDS ${CMAKE_BINARY_DIR}/locale/de/LC_MESSAGES/minetest-delta.mo) ++ add_custom_target(translation_fr ALL COMMENT "mo update [fr]" DEPENDS ${CMAKE_BINARY_DIR}/locale/fr/LC_MESSAGES/minetest-c55.mo) +endif(USE_GETTEXT) # Subdirectories