summaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
authorAllen Winter <allen.winter@kdab.com>2021-11-27 08:51:39 -0500
committerAllen Winter <allen.winter@kdab.com>2021-11-27 08:51:39 -0500
commit9827b909830eb02a1eab38e783db9d61d9a05de1 (patch)
treed3a0443507632b147c3227b08eb06eca54bf796f /doc
parentadf25615bd350d22897db6ea62f7f89842a6338b (diff)
downloadlibical-git-9827b909830eb02a1eab38e783db9d61d9a05de1.tar.gz
buildsystem - disable building Gtk docs with STATIC_ONLY
Diffstat (limited to 'doc')
-rw-r--r--doc/reference/libical-glib/CMakeLists.txt17
1 files changed, 16 insertions, 1 deletions
diff --git a/doc/reference/libical-glib/CMakeLists.txt b/doc/reference/libical-glib/CMakeLists.txt
index ca58244c..c4f8b594 100644
--- a/doc/reference/libical-glib/CMakeLists.txt
+++ b/doc/reference/libical-glib/CMakeLists.txt
@@ -1,4 +1,18 @@
-include(GtkDoc)
+
+option(ENABLE_GTK_DOC "Use gtk-doc to build documentation" True)
+
+if(NOT ENABLE_GTK_DOC)
+ return()
+endif()
+
+if(STATIC_ONLY)
+ message(FATAL_ERROR
+ "You are attempting to build the Gtk docs, "
+ "however that option is not supported when building static libraries only. "
+ "Please disable the static only option (-DSTATIC_ONLY=False) "
+ "if you really want to build the Gtk docs. Alternatively, you can "
+ "disable building Gtk docs (by passing -DENABLE_GTK_DOC=False to cmake).")
+endif()
# To regenerate libical-glib-docs.xml.in from current sources use these steps:
# a) delete ${CMAKE_CURRENT_BINARY_DIR}/libical-glib-docs.xml
@@ -15,6 +29,7 @@ include(GtkDoc)
# like the replacement of the "[Insert title here]" and the <bookinfo/> content
if(ENABLE_GTK_DOC)
+ include(GtkDoc)
set(SOURCEDIRS
${CMAKE_BINARY_DIR}/src/libical-glib