mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-22 10:00:33 +00:00
Added layouttranslations handling to cmake build
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@38174 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
a1b7ea843f
commit
428c425a51
@ -39,6 +39,7 @@ macro(lyx_install _parent_src_dir _gl_dir _file_type)
|
||||
list(REMOVE_ITEM files_list "${_current_dir}/.svn")
|
||||
list(REMOVE_ITEM files_list "${_current_dir}/Makefile.in")
|
||||
list(REMOVE_ITEM files_list "${_current_dir}/Makefile.am")
|
||||
list(REMOVE_ITEM files_list "${_current_dir}/layouttranslations")
|
||||
GET_FILENAME_COMPONENT(_base_dir ${_current_dir} NAME)
|
||||
if(_glob_dir STREQUAL ".")
|
||||
set(_base_dir .)
|
||||
|
@ -18,7 +18,11 @@ macro(add_gettext_python _par _dir)
|
||||
list(SORT _s1)
|
||||
list(APPEND _sources ${_s1})
|
||||
endforeach(_arg)
|
||||
SET(_dst "${CMAKE_CURRENT_BINARY_DIR}/${_par}_l10n.pot")
|
||||
if (${_par} MATCHES "layouttranslations")
|
||||
SET(_dst "${CMAKE_CURRENT_BINARY_DIR}/${_par}")
|
||||
else ()
|
||||
SET(_dst "${CMAKE_CURRENT_BINARY_DIR}/${_par}_l10n.pot")
|
||||
endif()
|
||||
SET(_tmp_src_files "${CMAKE_CURRENT_BINARY_DIR}/${_par}_tmp_files")
|
||||
SET(_src_files "${CMAKE_CURRENT_BINARY_DIR}/${_par}_files")
|
||||
file(WRITE ${_tmp_src_files} "")
|
||||
@ -35,16 +39,31 @@ macro(add_gettext_python _par _dir)
|
||||
COMMAND ${CMAKE_COMMAND} -E copy_if_different ${_tmp_src_files} ${_src_files}
|
||||
DEPENDS ${_tmp_src_files}
|
||||
)
|
||||
ADD_CUSTOM_COMMAND(
|
||||
OUTPUT "${_dst}"
|
||||
PRE_BUILD
|
||||
COMMAND ${LYX_PYTHON_EXECUTABLE}
|
||||
ARGS "${TOP_SRC_DIR}/po/lyx_pot.py" -b "${TOP_SRC_DIR}" -o "${_dst}" -t ${_par1} "--src_file=${_src_files}"
|
||||
DEPENDS ${_sources} ${_src_files}
|
||||
)
|
||||
if (${_par} MATCHES "layouttranslations")
|
||||
ADD_CUSTOM_COMMAND(
|
||||
OUTPUT "${_dst}"
|
||||
PRE_BUILD
|
||||
COMMAND ${CMAKE_COMMAND} -E copy_if_different "${TOP_SRC_DIR}/lib/layouttranslations" "${_dst}"
|
||||
COMMAND ${LYX_PYTHON_EXECUTABLE}
|
||||
ARGS "${TOP_SRC_DIR}/po/lyx_pot.py" -b "${TOP_SRC_DIR}" -o "${_dst}" -t ${_par1} "--src_file=${_src_files}"
|
||||
DEPENDS ${_sources} ${_src_files}
|
||||
COMMENT "${LYX_PYTHON_EXECUTABLE} ${TOP_SRC_DIR}/po/lyx_pot.py -b ${TOP_SRC_DIR} -o ${_dst} -t ${_par1} --src_file=${_src_files}"
|
||||
)
|
||||
ADD_CUSTOM_TARGET(layouttranslations ALL DEPENDS "${_dst}")
|
||||
install(FILES "${_dst}" DESTINATION .)
|
||||
else()
|
||||
ADD_CUSTOM_COMMAND(
|
||||
OUTPUT "${_dst}"
|
||||
PRE_BUILD
|
||||
COMMAND ${LYX_PYTHON_EXECUTABLE}
|
||||
ARGS "${TOP_SRC_DIR}/po/lyx_pot.py" -b "${TOP_SRC_DIR}" -o "${_dst}" -t ${_par1} "--src_file=${_src_files}"
|
||||
DEPENDS ${_sources} ${_src_files}
|
||||
COMMENT "${LYX_PYTHON_EXECUTABLE} ${TOP_SRC_DIR}/po/lyx_pot.py -b ${TOP_SRC_DIR} -o ${_dst} -t ${_par1} --src_file=${_src_files}"
|
||||
)
|
||||
LIST(APPEND _py_sources "${_dst}")
|
||||
endif()
|
||||
SET_SOURCE_FILES_PROPERTIES("${_dst}" GENERATED)
|
||||
SET_SOURCE_FILES_PROPERTIES("${_src_files}" GENERATED)
|
||||
LIST(APPEND _py_sources "${_dst}")
|
||||
endmacro(add_gettext_python)
|
||||
|
||||
SET_SOURCE_FILES_PROPERTIES("${CMAKE_CURRENT_BINARY_DIR}/${_lyxname}.cat.pot" GENERATED)
|
||||
@ -58,6 +77,7 @@ add_gettext_python(encodings lib encodings)
|
||||
add_gettext_python(ui lib/ui *.ui *.inc)
|
||||
add_gettext_python(external lib external_templates)
|
||||
add_gettext_python(formats lib configure.py)
|
||||
add_gettext_python(layouttranslations lib/layouts *.layout *.inc *.module)
|
||||
|
||||
ADD_CUSTOM_COMMAND(
|
||||
OUTPUT "${CMAKE_CURRENT_BINARY_DIR}/${_lyxname}.cat.pot"
|
||||
|
@ -1234,8 +1234,8 @@ Translation sk
|
||||
"Claim" "Nárok"
|
||||
"Conclusion" "Záver"
|
||||
"Condition" "Podmienka"
|
||||
"Conjecture" "Dohad"
|
||||
"Corollary" "Corollary"
|
||||
"Conjecture" "Hypotéza"
|
||||
"Corollary" "Korolár"
|
||||
"Criterion" "Kritérium"
|
||||
"Definition" "Definícia"
|
||||
"Example" "Príklad"
|
||||
|
16
po/sk.po
16
po/sk.po
@ -9,7 +9,7 @@ msgstr ""
|
||||
"Project-Id-Version: LyX-1.6\n"
|
||||
"Report-Msgid-Bugs-To: lyx-devel@lists.lyx.org\n"
|
||||
"POT-Creation-Date: 2011-03-31 07:28+0200\n"
|
||||
"PO-Revision-Date: 2011-03-31 07:49+0200\n"
|
||||
"PO-Revision-Date: 2011-03-31 07:54+0200\n"
|
||||
"Last-Translator: Kornel Benko <kornel@lyx.org>\n"
|
||||
"Language-Team: Slovak <lyx-docs@lists.lyx.org>\n"
|
||||
"Language: sk\n"
|
||||
@ -5334,7 +5334,7 @@ msgstr "Podmienka"
|
||||
#: lib/layouts/theorems.inc:132 lib/layouts/theorems-chap-bytype.module:102
|
||||
#: lib/layouts/theorems-sec-bytype.module:86
|
||||
msgid "Conjecture"
|
||||
msgstr "Dohad"
|
||||
msgstr "Hypotéza"
|
||||
|
||||
#: lib/layouts/AEA.layout:166 lib/layouts/beamer.layout:987
|
||||
#: lib/layouts/elsart.layout:322 lib/layouts/foils.layout:250
|
||||
@ -7443,7 +7443,7 @@ msgstr "Definícia \\arabic{theorem}"
|
||||
|
||||
#: lib/layouts/elsart.layout:367
|
||||
msgid "Conjecture \\arabic{theorem}"
|
||||
msgstr "Dohad \\arabic{theorem}"
|
||||
msgstr "Hypotéza \\arabic{theorem}"
|
||||
|
||||
#: lib/layouts/elsart.layout:374
|
||||
msgid "Example \\arabic{theorem}"
|
||||
@ -8226,7 +8226,7 @@ msgstr "Nárok \\theclaim."
|
||||
#: lib/layouts/ijmpc.layout:293 lib/layouts/ijmpd.layout:303
|
||||
#: lib/layouts/theorems-ams-bytype.inc:124 lib/layouts/theorems-bytype.inc:100
|
||||
msgid "Conjecture \\theconjecture."
|
||||
msgstr "Dohad \\theconjecture."
|
||||
msgstr "Hypotéza \\theconjecture."
|
||||
|
||||
#: lib/layouts/ijmpc.layout:296 lib/layouts/ijmpd.layout:306
|
||||
msgid "Appendices Section"
|
||||
@ -8466,7 +8466,7 @@ msgstr "Nárok."
|
||||
|
||||
#: lib/layouts/llncs.layout:317 lib/layouts/svjour.inc:329
|
||||
msgid "Conjecture #."
|
||||
msgstr "Dohad #."
|
||||
msgstr "Hypotéza #."
|
||||
|
||||
#: lib/layouts/llncs.layout:345 lib/layouts/svjour.inc:357
|
||||
msgid "Example #."
|
||||
@ -8834,7 +8834,7 @@ msgstr "[Pokrok Obsahy]"
|
||||
#: lib/layouts/siamltex.layout:111 lib/layouts/theorems-order.inc:34
|
||||
#: lib/layouts/theorems-starred.inc:114
|
||||
msgid "Conjecture*"
|
||||
msgstr "Dohad*"
|
||||
msgstr "Hypotéza*"
|
||||
|
||||
#: lib/layouts/siamltex.layout:121
|
||||
#: lib/layouts/theorems-ams-extended-bytype.module:94
|
||||
@ -9778,7 +9778,7 @@ msgstr "Tvrdenie \\thetheorem."
|
||||
|
||||
#: lib/layouts/theorems-ams.inc:123 lib/layouts/theorems.inc:123
|
||||
msgid "Conjecture \\thetheorem."
|
||||
msgstr "Dohad \\thetheorem."
|
||||
msgstr "Hypotéza \\thetheorem."
|
||||
|
||||
#: lib/layouts/theorems-ams.inc:141 lib/layouts/theorems.inc:141
|
||||
msgid "Fact \\thetheorem."
|
||||
@ -9830,7 +9830,7 @@ msgstr "Nárok*"
|
||||
|
||||
#: lib/layouts/theorems-starred.inc:117
|
||||
msgid "Conjecture."
|
||||
msgstr "Dohad."
|
||||
msgstr "Hypotéza."
|
||||
|
||||
#: lib/layouts/theorems-starred.inc:131
|
||||
msgid "Fact*"
|
||||
|
Loading…
Reference in New Issue
Block a user