From cf25d9373bb2148e86e46e9c25e245ffe9ec4026 Mon Sep 17 00:00:00 2001 From: Matthias Vogelgesang Date: Fri, 10 Aug 2012 15:14:08 +0200 Subject: Revert doc building changes Instead of switching WITH_REFERENCE we have to use WITH_GTK_DOC that can also be disabled at configure time. --- src/CMakeLists.txt | 16 +++++----------- 1 file changed, 5 insertions(+), 11 deletions(-) (limited to 'src/CMakeLists.txt') diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 0a38e17..9508c5c 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -160,18 +160,12 @@ set_target_properties(uca PROPERTIES target_link_libraries(uca ${uca_LIBS}) -if (NOT DEFINED WITH_REFERENCE) - set(WITH_REFERENCE TRUE) -endif() - - # --- Build documentation ----------------------------------------------------- -if (NOT DEFINED WITH_REFERENCE) - set(WITH_REFERENCE TRUE) -endif() pkg_check_modules(GTK_DOC gtk-doc) -if(GTK_DOC_FOUND AND WITH_REFERENCE) + +if(GTK_DOC_FOUND) option(WITH_GTK_DOC "Build documentation" ON) + if (WITH_GTK_DOC) set(docs_dir "${CMAKE_CURRENT_BINARY_DIR}") set(docs_out "${docs_dir}/reference") @@ -248,11 +242,11 @@ if(GTK_DOC_FOUND AND WITH_REFERENCE) DEPENDS ${docs_out}/sgml.stamp ${docs_out}/uca-docs.xml WORKING_DIRECTORY ${docs_out}) - add_custom_target(reference DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/html.stamp) + add_custom_target(reference ALL DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/html.stamp) install(FILES ${reference_files} DESTINATION share/gtk-doc/html/uca) endif() -endif(GTK_DOC_FOUND AND WITH_REFERENCE) +endif() # --- Install target ---------------------------------------------------------- -- cgit v1.2.3