diff options
author | Sébastien Helleu <flashcode@flashtux.org> | 2015-09-27 22:11:21 +0200 |
---|---|---|
committer | Sébastien Helleu <flashcode@flashtux.org> | 2015-09-27 22:11:21 +0200 |
commit | 152b5ec2a7b92527695e2093d5ff45488816e83d (patch) | |
tree | 38cb0d2cc358227e39450ed36525fe9778c5f514 /doc | |
parent | 15470bdb7d6e3a28978c4accbe0d58e1a032dc9e (diff) | |
download | weechat-152b5ec2a7b92527695e2093d5ff45488816e83d.zip |
doc: add build of Czech man page and quickstart guide
Diffstat (limited to 'doc')
-rw-r--r-- | doc/CMakeLists.txt | 1 | ||||
-rw-r--r-- | doc/Makefile.am | 2 | ||||
-rw-r--r-- | doc/cs/CMakeLists.txt | 52 | ||||
-rw-r--r-- | doc/cs/Makefile.am | 82 |
4 files changed, 136 insertions, 1 deletions
diff --git a/doc/CMakeLists.txt b/doc/CMakeLists.txt index 2d47a9aac..90bc380eb 100644 --- a/doc/CMakeLists.txt +++ b/doc/CMakeLists.txt @@ -52,6 +52,7 @@ if(ENABLE_MAN OR ENABLE_DOC) add_subdirectory(es) add_subdirectory(ru) add_subdirectory(ja) + add_subdirectory(cs) endif() diff --git a/doc/Makefile.am b/doc/Makefile.am index 44e50c9d8..1184eb611 100644 --- a/doc/Makefile.am +++ b/doc/Makefile.am @@ -18,7 +18,7 @@ # along with WeeChat. If not, see <http://www.gnu.org/licenses/>. # -SUBDIRS = . en fr it de pl es ru ja +SUBDIRS = . en fr it de pl es ru ja cs EXTRA_DIST = docgen.py \ CMakeLists.txt \ diff --git a/doc/cs/CMakeLists.txt b/doc/cs/CMakeLists.txt new file mode 100644 index 000000000..ceff82539 --- /dev/null +++ b/doc/cs/CMakeLists.txt @@ -0,0 +1,52 @@ +# +# Copyright (C) 2003-2015 Sébastien Helleu <flashcode@flashtux.org> +# +# This file is part of WeeChat, the extensible chat client. +# +# WeeChat is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 3 of the License, or +# (at your option) any later version. +# +# WeeChat is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with WeeChat. If not, see <http://www.gnu.org/licenses/>. +# + +if(ENABLE_MAN) + # man page + add_custom_command( + OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/weechat.1 + COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_SOURCE_DIR}/weechat.1.cs.asciidoc . + COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_SOURCE_DIR}/cmdline_options.cs.asciidoc . + COMMAND ${A2X_EXECUTABLE} ARGS -a revision='WeeChat ${VERSION}' -d manpage -f manpage -L weechat.1.cs.asciidoc + DEPENDS + ${CMAKE_CURRENT_SOURCE_DIR}/weechat.1.cs.asciidoc + ${CMAKE_CURRENT_SOURCE_DIR}/cmdline_options.cs.asciidoc + WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} + COMMENT "Building weechat.1 (cs)" + ) + add_custom_target(doc-man-cs ALL DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/weechat.1) + install(FILES ${CMAKE_CURRENT_BINARY_DIR}/weechat.1 DESTINATION ${MANDIR}/cs/man1) +endif() + +if(ENABLE_DOC AND SOURCEHIGHLIGHT_FOUND) + + # quickstart + add_custom_command( + OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/weechat_quickstart.cs.html + COMMAND ${ASCIIDOC_EXECUTABLE} ARGS ${ASCIIDOC_ARGS_QUICKSTART} -o weechat_quickstart.cs.html ${CMAKE_CURRENT_SOURCE_DIR}/weechat_quickstart.cs.asciidoc + DEPENDS + ${CMAKE_CURRENT_SOURCE_DIR}/../asciidoc_toc2.css + ${CMAKE_CURRENT_SOURCE_DIR}/weechat_quickstart.cs.asciidoc + WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} + COMMENT "Building weechat_quickstart.cs.html" + ) + add_custom_target(doc-quickstart-cs ALL DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/weechat_quickstart.cs.html) + install(FILES ${CMAKE_CURRENT_BINARY_DIR}/weechat_quickstart.cs.html DESTINATION ${SHAREDIR}/doc/${PROJECT_NAME}) + +endif() diff --git a/doc/cs/Makefile.am b/doc/cs/Makefile.am new file mode 100644 index 000000000..02194efcc --- /dev/null +++ b/doc/cs/Makefile.am @@ -0,0 +1,82 @@ +# +# Copyright (C) 2003-2015 Sébastien Helleu <flashcode@flashtux.org> +# +# This file is part of WeeChat, the extensible chat client. +# +# WeeChat is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 3 of the License, or +# (at your option) any later version. +# +# WeeChat is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with WeeChat. If not, see <http://www.gnu.org/licenses/>. +# + +docdir = $(datadir)/doc/$(PACKAGE) + +EXTRA_DIST = CMakeLists.txt \ + weechat.1.cs.asciidoc \ + cmdline_options.cs.asciidoc \ + weechat_quickstart.cs.asciidoc \ + $(wildcard autogen/user/*.asciidoc) \ + $(wildcard autogen/plugin_api/*.asciidoc) + +if MAN + man_targets = weechat.1 + man_install = install-man + man_uninstall = uninstall-man +endif +if DOC + doc_targets = weechat_quickstart.cs.html + doc_install = install-doc + doc_uninstall = uninstall-doc +endif +all-local: $(man_targets) $(doc_targets) + +# man page +weechat.1: weechat.1.cs.asciidoc cmdline_options.cs.asciidoc + -mkdir tmp_man + cp -f $(abs_top_srcdir)/doc/cs/weechat.1.cs.asciidoc ./tmp_man/ + cp -f $(abs_top_srcdir)/doc/cs/cmdline_options.cs.asciidoc ./tmp_man/ + (cd tmp_man && $(A2X) -a revision="WeeChat $(VERSION)" -d manpage -f manpage -L weechat.1.cs.asciidoc) + mv -f tmp_man/weechat.1 . + rm -rf tmp_man + +# quickstart +weechat_quickstart.cs.html: weechat_quickstart.cs.asciidoc $(abs_top_srcdir)/doc/asciidoc_toc2.css + $(ASCIIDOC) -b html5 -a revision="$(VERSION)" -a stylesheet=$(abs_top_srcdir)/doc/asciidoc_toc2.css -f $(abs_top_srcdir)/doc/asciidoc.conf -n -o weechat_quickstart.cs.html $(abs_top_srcdir)/doc/cs/weechat_quickstart.cs.asciidoc + +# install man/docs + +install-data-hook: $(man_install) $(doc_install) + +install-man: + $(mkinstalldirs) $(DESTDIR)$(mandir)/cs/man1/ + $(INSTALL_DATA) *.1 $(DESTDIR)$(mandir)/cs/man1/ + +install-doc: + $(mkinstalldirs) $(DESTDIR)$(docdir)/ + $(INSTALL_DATA) *.html $(DESTDIR)$(docdir)/ + +# uninstall man/docs + +uninstall-hook: $(man_uninstall) $(doc_uninstall) + +uninstall-man: + $(RM) $(DESTDIR)$(mandir)/cs/man1/weechat.1 + -rmdir $(DESTDIR)$(mandir)/cs/man1 + +uninstall-doc: + $(RM) $(DESTDIR)$(docdir)/*.cs.html + -rmdir $(DESTDIR)$(docdir) + +# clean + +clean-local: + -rm -f weechat.1 weechat.1.cs.asciidoc cmdline_options.cs.asciidoc + -rm -f *.html |