Lupdate command and cmake



  • hi
    i use qtcreator on ubuntu 11.10
    i have a project that uses cmake
    i open cmakelists.txt file with qtcreator and it works fine
    but now i want to use lupdate and lrelease on it
    but it does'nt get me any translation file to translated
    it get me this:
    found 0 source text(s)



  • You should look at the documentation of lupdate / lrelease and how to use these from the command-line, then use ADD_CUSTOM_COMMAND in your CMakeLists.txt file to actually perform the actions required to generate your translation files:

    @
    ADD_CUSTOM_COMMAND (
    OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/project.ts
    COMMAND lupdate -silent -I ./includes ./sources -ts ./project.ts ${CMAKE_CURRENT_BINARY_DIR}/project.ts
    WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}
    )
    @



  • but this command not perform! why?


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.