This makes sure that we always have a doxygen target to link to available. The target
page may simply say that the code gallery was not available.
LIST(APPEND _doxygen_input
${CMAKE_CURRENT_BINARY_DIR}/code-gallery/${_step}.h
)
- LIST(APPEND _doxygen_input
- ${CMAKE_CURRENT_BINARY_DIR}/code-gallery/code-gallery.h
- )
ENDFOREACH()
-
- LIST(APPEND _doxygen_depend
- ${CMAKE_CURRENT_BINARY_DIR}/code-gallery/code-gallery.h
- )
ENDIF()
+
+# always make the doxygen run depend on the code-gallery.h file
+# (whether generated from the code gallery or copied from
+# no-code-gallery.h; both happen in code-gallery/CMakeLists.txt)
+LIST(APPEND _doxygen_input
+ ${CMAKE_CURRENT_BINARY_DIR}/code-gallery/code-gallery.h
+)
+LIST(APPEND _doxygen_depend
+ ${CMAKE_CURRENT_BINARY_DIR}/code-gallery/code-gallery.h
+)
+
+
TO_STRING(_doxygen_image_path_string ${_doxygen_image_path})
TO_STRING(_doxygen_input_string ${_doxygen_input})
<!-- Navigation index tabs for HTML output -->
<navindex>
<tab type="mainpage" visible="yes" title=""/>
- <tab type="user" visible="yes" title="Tutorial" url="@ref Tutorial" />
+ <tab type="usergroup" title="Tutorial">
+ <tab type="user" visible="yes" title="Tutorial" url="@ref Tutorial" />
+ <tab type="user" visible="yes" title="Code gallery" url="@ref CodeGallery" />
+ </tab>
<tab type="modules" visible="yes" title="" intro=""/>
<tab type="namespaces" visible="yes" title="">
<tab type="namespacelist" visible="yes" title="" intro=""/>
ENDFOREACH()
ELSE()
- MESSAGE(STATUS "Generating the code-gallery documentation is only possible if the code gallery exists in ${DEAL_II_CODE_GALLERY_DIRECTORY}.")
+
+ # no copy of the code gallery is available. say so. but also
+ # install a file that creates a doxygen page we can link to
+ # nonetheless, so we don't get bad doxygen references
+ MESSAGE(STATUS "Setting up code gallery documentation.")
+ MESSAGE(STATUS " Skipping as no code gallery exists in ${DEAL_II_CODE_GALLERY_DIRECTORY}.")
+
+ FILE(COPY ${CMAKE_CURRENT_SOURCE_DIR}/no-code-gallery.h
+ DESTINATION ${CMAKE_CURRENT_BINARY_DIR})
+ FILE(RENAME ${CMAKE_CURRENT_BINARY_DIR}/no-code-gallery.h
+ ${CMAKE_CURRENT_BINARY_DIR}/code-gallery.h)
ENDIF()
--- /dev/null
+// ---------------------------------------------------------------------
+//
+// Copyright (C) 2016 by the deal.II authors
+//
+// This file is part of the deal.II library.
+//
+// The deal.II library is free software; you can use it, redistribute
+// it, and/or modify it under the terms of the GNU Lesser General
+// Public License as published by the Free Software Foundation; either
+// version 2.1 of the License, or (at your option) any later version.
+// The full text of the license can be found in the file LICENSE at
+// the top level of the deal.II distribution.
+//
+// ---------------------------------------------------------------------
+
+
+/**
+ * @page CodeGallery The deal.II code gallery
+ *
+ * In order to create pages for the code gallery, there needs to be a
+ * version of the code gallery checked out alongside the other
+ * top-level directories in the <code>deal.II/</code> directory. No
+ * such copy was found when configuring your version of deal.II.
+ *
+ * Instructions for obtaining the code gallery can be found at
+ * http://dealii.org/code-gallery.html .
+ */