diff doc/CMakeLists.txt @ 0:1158cffe5a5e

Initial import
author David Demelier <markand@malikania.fr>
date Mon, 08 Feb 2016 16:43:14 +0100
parents
children 113d909fdfe1
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/doc/CMakeLists.txt	Mon Feb 08 16:43:14 2016 +0100
@@ -0,0 +1,58 @@
+#
+# CMakeLists.txt -- CMake build system for irccd
+#
+# Copyright (c) 2013-2016 David Demelier <markand@malikania.fr>
+#
+# Permission to use, copy, modify, and/or distribute this software for any
+# purpose with or without fee is hereby granted, provided that the above
+# copyright notice and this permission notice appear in all copies.
+#
+# THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
+# WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
+# MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
+# ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
+# WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
+# ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
+# OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+#
+
+project(doc)
+
+# Meta targets `docs`
+add_custom_target(
+	docs ALL
+	COMMENT "Building irccd documentation"
+	SOURCES
+		${doc_SOURCE_DIR}/procs/README.md
+		${doc_SOURCE_DIR}/procs/00.tests.md
+		${doc_SOURCE_DIR}/procs/00.new-release.md
+		${doc_SOURCE_DIR}/procs/20.options.md
+		${doc_SOURCE_DIR}/procs/30.options.md
+		${doc_SOURCE_DIR}/procs/60.new-command.md
+)
+
+#
+# Set the DOC_OUTPUT variable to where files will be installed
+# -------------------------------------------------------------------
+#
+# Depending if irccd is relocatable or not, documentation generated will be in a different folder, either
+# in the real fakeroot documentation directory or not.
+#
+
+if (IRCCD_RELOCATABLE)
+	set(DOC_OUTPUT ${CMAKE_BINARY_DIR}/fakeroot/${WITH_DOCDIR})
+else ()
+	set(DOC_OUTPUT ${CMAKE_BINARY_DIR}/docs)
+endif ()
+
+# Needed for fakeroot
+if (WITH_DOXYGEN)
+	add_subdirectory(doxygen)
+endif ()
+
+add_subdirectory(examples)
+add_subdirectory(man)
+
+if (WITH_HTML)
+	add_subdirectory(html)
+endif ()