File: step104.slog

package info (click to toggle)
debmake-doc 1.17-7
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 24,612 kB
  • sloc: makefile: 768; sh: 690; ansic: 114; python: 99; sed: 16
file content (41 lines) | stat: -rw-r--r-- 1,327 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
 $ cat debhello-3.4/po/LINGUAS
ja
 $ cat debhello-3.4/po/CMakeLists.txt
include(FindGettext)
if(GETTEXT_FOUND)
  set(_potFile ${CMAKE_BINARY_DIR}/po/${PROJECT_NAME}.pot)
  # program source file
  set(_src_list
    ${CMAKE_SOURCE_DIR}/src/hello.c
    ${CMAKE_SOURCE_DIR}/lib/sharedlib.c
  )
  add_custom_command(
    OUTPUT ${_potFile}
    COMMAND touch ${_potFile}
    COMMAND xgettext -o ${_potFile} ${_src_list}
    COMMAND xgettext -L Desktop -j -o ${_potFile} ${CMAKE_SOURCE_DIR}/data/he...
    DEPENDS ${_src_list} ${CMAKE_SOURCE_DIR}/data/hello.desktop.in
    WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}
  )
  add_custom_target(pot ALL
    DEPENDS ${_potFile}
  )
  # Create a target "translations" and output mo files.
  gettext_create_translations(${_potFile} ALL ja.po)
  #gettext_process_pot_file(${_potFile} ALL ja)
  set(_desktopinFile ${CMAKE_SOURCE_DIR}/data/hello.desktop.in)
  set(_desktopFile ${CMAKE_BINARY_DIR}/data/hello.desktop)
  add_custom_command(
    OUTPUT ${_desktopFile}
    COMMAND ${GETTEXT_MSGFMT_EXECUTABLE} --desktop -o ${_desktopFile} --templ...
    DEPENDS ${_desktopFile} ja.po
    WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}
  )
  add_custom_target(desktop ALL
    DEPENDS ${_desktopFile}
  )
  install(FILES ${_desktopFile}
    DESTINATION share/applications
  )
endif(GETTEXT_FOUND)