diff options
author | Sebastien Helleu <flashcode@flashtux.org> | 2013-07-31 13:28:59 +0200 |
---|---|---|
committer | Sebastien Helleu <flashcode@flashtux.org> | 2013-07-31 13:28:59 +0200 |
commit | 261efe6299710424812faadf03905198763e3014 (patch) | |
tree | 5b7780c8a8acb366abcb17f3bd405a79b187dd32 /doc/ja | |
parent | 9951902c7b39a1e783bc1b0f903d616de5b848d8 (diff) | |
download | weechat-261efe6299710424812faadf03905198763e3014.zip |
core: add cmake option ENABLE_MAN to compile man page (on by default)
For configure, the option is "--disable-man".
Diffstat (limited to 'doc/ja')
-rw-r--r-- | doc/ja/CMakeLists.txt | 132 | ||||
-rw-r--r-- | doc/ja/Makefile.am | 29 | ||||
-rw-r--r-- | doc/ja/weechat_user.ja.txt | 9 |
3 files changed, 99 insertions, 71 deletions
diff --git a/doc/ja/CMakeLists.txt b/doc/ja/CMakeLists.txt index e1c6fe76d..6f821d792 100644 --- a/doc/ja/CMakeLists.txt +++ b/doc/ja/CMakeLists.txt @@ -17,71 +17,77 @@ # along with WeeChat. If not, see <http://www.gnu.org/licenses/>. # -# man page -ADD_CUSTOM_COMMAND( - OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/weechat-curses.1 - COMMAND ${A2X_EXECUTABLE} ARGS -a lang=ja -a revision='WeeChat ${VERSION}' -d manpage -f manpage -L -D ${CMAKE_CURRENT_BINARY_DIR} ${CMAKE_CURRENT_SOURCE_DIR}/weechat-curses.1.ja.txt - DEPENDS - ${CMAKE_CURRENT_SOURCE_DIR}/weechat-curses.1.ja.txt - ${CMAKE_CURRENT_SOURCE_DIR}/cmdline_options.ja.txt - COMMENT "Building weechat-curses.1 (ja)" -) -ADD_CUSTOM_TARGET(doc-man-ja ALL DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/weechat-curses.1) -INSTALL(FILES ${CMAKE_CURRENT_BINARY_DIR}/weechat-curses.1 DESTINATION ${MANDIR}/ja/man1) +IF (ENABLE_MAN) + # man page + ADD_CUSTOM_COMMAND( + OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/weechat-curses.1 + COMMAND ${A2X_EXECUTABLE} ARGS -a lang=ja -a revision='WeeChat ${VERSION}' -d manpage -f manpage -L -D ${CMAKE_CURRENT_BINARY_DIR} ${CMAKE_CURRENT_SOURCE_DIR}/weechat-curses.1.ja.txt + DEPENDS + ${CMAKE_CURRENT_SOURCE_DIR}/weechat-curses.1.ja.txt + ${CMAKE_CURRENT_SOURCE_DIR}/cmdline_options.ja.txt + COMMENT "Building weechat-curses.1 (ja)" + ) + ADD_CUSTOM_TARGET(doc-man-ja ALL DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/weechat-curses.1) + INSTALL(FILES ${CMAKE_CURRENT_BINARY_DIR}/weechat-curses.1 DESTINATION ${MANDIR}/ja/man1) +ENDIF (ENABLE_MAN) -# user's guide -ADD_CUSTOM_COMMAND( - OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/weechat_user.ja.html - COMMAND ${ASCIIDOC_EXECUTABLE} ARGS -a toc -a toclevels=4 -a toc-title='目次' -a date=`date "+%F"` -a revision="${VERSION}" -a stylesheet=${CMAKE_CURRENT_SOURCE_DIR}/../asciidoc.css -f ${CMAKE_CURRENT_SOURCE_DIR}/../asciidoc.conf -n -o ${CMAKE_CURRENT_BINARY_DIR}/weechat_user.ja.html ${CMAKE_CURRENT_SOURCE_DIR}/weechat_user.ja.txt - DEPENDS - ${CMAKE_CURRENT_SOURCE_DIR}/weechat_user.ja.txt - ${CMAKE_CURRENT_SOURCE_DIR}/cmdline_options.ja.txt - ${CMAKE_CURRENT_SOURCE_DIR}/autogen/user/*.txt - COMMENT "Building weechat_user.ja.html" -) -ADD_CUSTOM_TARGET(doc-user-ja ALL DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/weechat_user.ja.html) -INSTALL(FILES ${CMAKE_CURRENT_BINARY_DIR}/weechat_user.ja.html DESTINATION ${SHAREDIR}/doc/${PROJECT_NAME}) +IF(ENABLE_DOC AND SOURCEHIGHLIGHT_FOUND) -# scripting guide -ADD_CUSTOM_COMMAND( - OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/weechat_scripting.ja.html - COMMAND ${ASCIIDOC_EXECUTABLE} ARGS -a toc -a toclevels=3 -a toc-title='目次' -a date=`date "+%F"` -a revision="${VERSION}" -a stylesheet=${CMAKE_CURRENT_SOURCE_DIR}/../asciidoc.css -n -o ${CMAKE_CURRENT_BINARY_DIR}/weechat_scripting.ja.html ${CMAKE_CURRENT_SOURCE_DIR}/weechat_scripting.ja.txt - DEPENDS - ${CMAKE_CURRENT_SOURCE_DIR}/weechat_scripting.ja.txt - COMMENT "Building weechat_scripting.ja.html" -) -ADD_CUSTOM_TARGET(doc-scripting-ja ALL DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/weechat_scripting.ja.html) -INSTALL(FILES ${CMAKE_CURRENT_BINARY_DIR}/weechat_scripting.ja.html DESTINATION ${SHAREDIR}/doc/${PROJECT_NAME}) + # user's guide + ADD_CUSTOM_COMMAND( + OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/weechat_user.ja.html + COMMAND ${ASCIIDOC_EXECUTABLE} ARGS -a toc -a toclevels=4 -a toc-title='目次' -a date=`date "+%F"` -a revision="${VERSION}" -a stylesheet=${CMAKE_CURRENT_SOURCE_DIR}/../asciidoc.css -f ${CMAKE_CURRENT_SOURCE_DIR}/../asciidoc.conf -n -o ${CMAKE_CURRENT_BINARY_DIR}/weechat_user.ja.html ${CMAKE_CURRENT_SOURCE_DIR}/weechat_user.ja.txt + DEPENDS + ${CMAKE_CURRENT_SOURCE_DIR}/weechat_user.ja.txt + ${CMAKE_CURRENT_SOURCE_DIR}/cmdline_options.ja.txt + ${CMAKE_CURRENT_SOURCE_DIR}/autogen/user/*.txt + COMMENT "Building weechat_user.ja.html" + ) + ADD_CUSTOM_TARGET(doc-user-ja ALL DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/weechat_user.ja.html) + INSTALL(FILES ${CMAKE_CURRENT_BINARY_DIR}/weechat_user.ja.html DESTINATION ${SHAREDIR}/doc/${PROJECT_NAME}) -# FAQ -ADD_CUSTOM_COMMAND( - OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/weechat_faq.ja.html - COMMAND ${ASCIIDOC_EXECUTABLE} ARGS -a toc -a toc-title='目次' -a date=`date "+%F"` -a revision="${VERSION}" -a stylesheet=${CMAKE_CURRENT_SOURCE_DIR}/../asciidoc.css -f ${CMAKE_CURRENT_SOURCE_DIR}/../asciidoc.conf -n -o ${CMAKE_CURRENT_BINARY_DIR}/weechat_faq.ja.html ${CMAKE_CURRENT_SOURCE_DIR}/weechat_faq.ja.txt - DEPENDS - ${CMAKE_CURRENT_SOURCE_DIR}/weechat_faq.ja.txt - COMMENT "Building weechat_faq.ja.html" -) -ADD_CUSTOM_TARGET(doc-faq-ja ALL DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/weechat_faq.ja.html) -INSTALL(FILES ${CMAKE_CURRENT_BINARY_DIR}/weechat_faq.ja.html DESTINATION ${SHAREDIR}/doc/${PROJECT_NAME}) + # scripting guide + ADD_CUSTOM_COMMAND( + OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/weechat_scripting.ja.html + COMMAND ${ASCIIDOC_EXECUTABLE} ARGS -a toc -a toclevels=3 -a toc-title='目次' -a date=`date "+%F"` -a revision="${VERSION}" -a stylesheet=${CMAKE_CURRENT_SOURCE_DIR}/../asciidoc.css -n -o ${CMAKE_CURRENT_BINARY_DIR}/weechat_scripting.ja.html ${CMAKE_CURRENT_SOURCE_DIR}/weechat_scripting.ja.txt + DEPENDS + ${CMAKE_CURRENT_SOURCE_DIR}/weechat_scripting.ja.txt + COMMENT "Building weechat_scripting.ja.html" + ) + ADD_CUSTOM_TARGET(doc-scripting-ja ALL DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/weechat_scripting.ja.html) + INSTALL(FILES ${CMAKE_CURRENT_BINARY_DIR}/weechat_scripting.ja.html DESTINATION ${SHAREDIR}/doc/${PROJECT_NAME}) -# quickstart -ADD_CUSTOM_COMMAND( - OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/weechat_quickstart.ja.html - COMMAND ${ASCIIDOC_EXECUTABLE} ARGS -a toc -a toc-title='目次' -a date=`date "+%F"` -a revision="${VERSION}" -a stylesheet=${CMAKE_CURRENT_SOURCE_DIR}/../asciidoc.css -n -o ${CMAKE_CURRENT_BINARY_DIR}/weechat_quickstart.ja.html ${CMAKE_CURRENT_SOURCE_DIR}/weechat_quickstart.ja.txt - DEPENDS - ${CMAKE_CURRENT_SOURCE_DIR}/weechat_quickstart.ja.txt - COMMENT "Building weechat_quickstart.ja.html" -) -ADD_CUSTOM_TARGET(doc-quickstart-ja ALL DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/weechat_quickstart.ja.html) -INSTALL(FILES ${CMAKE_CURRENT_BINARY_DIR}/weechat_quickstart.ja.html DESTINATION ${SHAREDIR}/doc/${PROJECT_NAME}) + # FAQ + ADD_CUSTOM_COMMAND( + OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/weechat_faq.ja.html + COMMAND ${ASCIIDOC_EXECUTABLE} ARGS -a toc -a toc-title='目次' -a date=`date "+%F"` -a revision="${VERSION}" -a stylesheet=${CMAKE_CURRENT_SOURCE_DIR}/../asciidoc.css -f ${CMAKE_CURRENT_SOURCE_DIR}/../asciidoc.conf -n -o ${CMAKE_CURRENT_BINARY_DIR}/weechat_faq.ja.html ${CMAKE_CURRENT_SOURCE_DIR}/weechat_faq.ja.txt + DEPENDS + ${CMAKE_CURRENT_SOURCE_DIR}/weechat_faq.ja.txt + COMMENT "Building weechat_faq.ja.html" + ) + ADD_CUSTOM_TARGET(doc-faq-ja ALL DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/weechat_faq.ja.html) + INSTALL(FILES ${CMAKE_CURRENT_BINARY_DIR}/weechat_faq.ja.html DESTINATION ${SHAREDIR}/doc/${PROJECT_NAME}) -# tester's guide -ADD_CUSTOM_COMMAND( - OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/weechat_tester.ja.html - COMMAND ${ASCIIDOC_EXECUTABLE} ARGS -a toc -a toc-title='目次' -a date=`date "+%F"` -a revision="${VERSION}" -a stylesheet=${CMAKE_CURRENT_SOURCE_DIR}/../asciidoc.css -n -o ${CMAKE_CURRENT_BINARY_DIR}/weechat_tester.ja.html ${CMAKE_CURRENT_SOURCE_DIR}/weechat_tester.ja.txt - DEPENDS - ${CMAKE_CURRENT_SOURCE_DIR}/weechat_tester.ja.txt - COMMENT "Building weechat_tester.ja.html" -) -ADD_CUSTOM_TARGET(doc-tester-ja ALL DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/weechat_tester.ja.html) -INSTALL(FILES ${CMAKE_CURRENT_BINARY_DIR}/weechat_tester.ja.html DESTINATION ${SHAREDIR}/doc/${PROJECT_NAME}) + # quickstart + ADD_CUSTOM_COMMAND( + OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/weechat_quickstart.ja.html + COMMAND ${ASCIIDOC_EXECUTABLE} ARGS -a toc -a toc-title='目次' -a date=`date "+%F"` -a revision="${VERSION}" -a stylesheet=${CMAKE_CURRENT_SOURCE_DIR}/../asciidoc.css -n -o ${CMAKE_CURRENT_BINARY_DIR}/weechat_quickstart.ja.html ${CMAKE_CURRENT_SOURCE_DIR}/weechat_quickstart.ja.txt + DEPENDS + ${CMAKE_CURRENT_SOURCE_DIR}/weechat_quickstart.ja.txt + COMMENT "Building weechat_quickstart.ja.html" + ) + ADD_CUSTOM_TARGET(doc-quickstart-ja ALL DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/weechat_quickstart.ja.html) + INSTALL(FILES ${CMAKE_CURRENT_BINARY_DIR}/weechat_quickstart.ja.html DESTINATION ${SHAREDIR}/doc/${PROJECT_NAME}) + + # tester's guide + ADD_CUSTOM_COMMAND( + OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/weechat_tester.ja.html + COMMAND ${ASCIIDOC_EXECUTABLE} ARGS -a toc -a toc-title='目次' -a date=`date "+%F"` -a revision="${VERSION}" -a stylesheet=${CMAKE_CURRENT_SOURCE_DIR}/../asciidoc.css -n -o ${CMAKE_CURRENT_BINARY_DIR}/weechat_tester.ja.html ${CMAKE_CURRENT_SOURCE_DIR}/weechat_tester.ja.txt + DEPENDS + ${CMAKE_CURRENT_SOURCE_DIR}/weechat_tester.ja.txt + COMMENT "Building weechat_tester.ja.html" + ) + ADD_CUSTOM_TARGET(doc-tester-ja ALL DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/weechat_tester.ja.html) + INSTALL(FILES ${CMAKE_CURRENT_BINARY_DIR}/weechat_tester.ja.html DESTINATION ${SHAREDIR}/doc/${PROJECT_NAME}) + +ENDIF(ENABLE_DOC AND SOURCEHIGHLIGHT_FOUND) diff --git a/doc/ja/Makefile.am b/doc/ja/Makefile.am index 096523a4c..67ba8bb53 100644 --- a/doc/ja/Makefile.am +++ b/doc/ja/Makefile.am @@ -30,12 +30,21 @@ EXTRA_DIST = CMakeLists.txt \ $(wildcard autogen/user/*.txt) \ $(wildcard autogen/plugin_api/*.txt) -all-local: weechat-curses.1 \ - weechat_user.ja.html \ +if MAN + man_targets = weechat-curses.1 + man_install = install-man + man_uninstall = uninstall-man +endif +if DOC + doc_targets = weechat_user.ja.html \ weechat_scripting.ja.html \ weechat_faq.ja.html \ weechat_quickstart.ja.html \ weechat_tester.ja.html + doc_install = install-doc + doc_uninstall = uninstall-doc +endif +all-local: $(man_targets) $(doc_targets) # man page weechat-curses.1: weechat-curses.1.ja.txt cmdline_options.ja.txt @@ -61,19 +70,27 @@ weechat_quickstart.ja.html: weechat_quickstart.ja.txt weechat_tester.ja.html: weechat_tester.ja.txt $(ASCIIDOC) -a toc -a toc-title='目次' -a date=`date "+%F"` -a revision="$(VERSION)" -a stylesheet=$(abs_top_srcdir)/doc/asciidoc.css -n -o weechat_tester.ja.html $(abs_top_srcdir)/doc/ja/weechat_tester.ja.txt -# install docs +# install man/docs -install-data-hook: +install-data-hook: $(man_install) $(doc_install) + +install-man: $(mkinstalldirs) $(DESTDIR)$(mandir)/ja/man1/ $(INSTALL_DATA) *.1 $(DESTDIR)$(mandir)/ja/man1/ + +install-doc: $(mkinstalldirs) $(DESTDIR)$(docdir)/ $(INSTALL_DATA) *.html $(DESTDIR)$(docdir)/ -# uninstall docs +# uninstall man/docs -uninstall-hook: +uninstall-hook: $(man_uninstall) $(doc_uninstall) + +uninstall-man: $(RM) $(DESTDIR)$(mandir)/ja/man1/weechat-curses.1 -rmdir $(DESTDIR)$(mandir)/ja/man1 + +uninstall-doc: $(RM) $(DESTDIR)$(docdir)/*.ja.html -rmdir $(DESTDIR)$(docdir) diff --git a/doc/ja/weechat_user.ja.txt b/doc/ja/weechat_user.ja.txt index 81f2a8c89..9da7a2ae0 100644 --- a/doc/ja/weechat_user.ja.txt +++ b/doc/ja/weechat_user.ja.txt @@ -95,8 +95,10 @@ WeeChat は cmake または autotools を使ってコンパイルできます (c | liblua5.1-0-dev | | | lua プラグイン | tcl-dev | ≥ 8.5 | | tcl プラグイン | guile-2.0-dev | ≥ 2.0 | | guile (scheme) プラグイン -| asciidoc | ≥ 8.5.0 | | 文書の生成 (HTML ファイル) -| source-highlight | | | HTML 文書に含まれるソースコードのシンタックスハイライト +// TRANSLATION MISSING +| asciidoc | ≥ 8.5.0 | | build man page and documentation +// TRANSLATION MISSING +| source-highlight | | | syntax highlight for sources in documentation // TRANSLATION MISSING | xsltproc, docbook-xml, docbook-xsl | | | build man page @@ -171,6 +173,9 @@ List of commonly used options: | ENABLE_DEMO | `ON`, `OFF` | OFF | Compile Demo plugin. +| ENABLE_MAN | `ON`, `OFF` | ON | + Compile man page. + | ENABLE_DOC | `ON`, `OFF` | OFF | Compile documentation (it takes a long time, recommended only if you build a binary package embedding documentation or if you can't browse documentation |