2009-10-03 00:45:24 +08:00
|
|
|
project(EigenDoc)
|
2008-08-27 07:07:33 +08:00
|
|
|
|
2008-12-02 20:59:10 +08:00
|
|
|
set_directory_properties(PROPERTIES EXCLUDE_FROM_ALL TRUE)
|
2007-12-21 17:30:32 +08:00
|
|
|
|
2009-05-17 18:12:39 +08:00
|
|
|
project(EigenDoc)
|
|
|
|
|
2008-12-02 20:59:10 +08:00
|
|
|
if(CMAKE_COMPILER_IS_GNUCXX)
|
|
|
|
if(CMAKE_SYSTEM_NAME MATCHES Linux)
|
|
|
|
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -O1 -g1")
|
|
|
|
endif(CMAKE_SYSTEM_NAME MATCHES Linux)
|
|
|
|
endif(CMAKE_COMPILER_IS_GNUCXX)
|
2008-05-28 12:38:16 +08:00
|
|
|
|
2009-02-04 23:37:00 +08:00
|
|
|
configure_file(
|
|
|
|
${Eigen_SOURCE_DIR}/unsupported/doc/Doxyfile.in
|
|
|
|
${CMAKE_CURRENT_BINARY_DIR}/Doxyfile-unsupported
|
|
|
|
)
|
|
|
|
|
2008-12-02 20:59:10 +08:00
|
|
|
configure_file(
|
2007-12-21 17:02:24 +08:00
|
|
|
${CMAKE_CURRENT_SOURCE_DIR}/Doxyfile.in
|
|
|
|
${CMAKE_CURRENT_BINARY_DIR}/Doxyfile
|
|
|
|
)
|
2007-09-28 14:17:36 +08:00
|
|
|
|
2008-12-02 20:59:10 +08:00
|
|
|
configure_file(
|
2008-08-25 18:49:53 +08:00
|
|
|
${CMAKE_CURRENT_SOURCE_DIR}/eigendoxy_header.html.in
|
|
|
|
${CMAKE_CURRENT_BINARY_DIR}/eigendoxy_header.html
|
|
|
|
)
|
|
|
|
|
2008-12-02 20:59:10 +08:00
|
|
|
configure_file(
|
2008-08-25 18:49:53 +08:00
|
|
|
${CMAKE_CURRENT_SOURCE_DIR}/eigendoxy_footer.html.in
|
|
|
|
${CMAKE_CURRENT_BINARY_DIR}/eigendoxy_footer.html
|
|
|
|
)
|
|
|
|
|
2008-12-02 20:59:10 +08:00
|
|
|
set(examples_targets "")
|
|
|
|
set(snippets_targets "")
|
2007-12-21 19:29:04 +08:00
|
|
|
|
2008-12-07 07:20:30 +08:00
|
|
|
add_definitions("-DEIGEN_DEFAULT_IO_FORMAT=EIGEN_DOCS_IO_FORMAT")
|
|
|
|
|
2008-12-02 20:59:10 +08:00
|
|
|
add_subdirectory(examples)
|
|
|
|
add_subdirectory(snippets)
|
2007-12-21 17:30:32 +08:00
|
|
|
|
2008-12-02 20:59:10 +08:00
|
|
|
add_custom_target(
|
2009-03-11 21:11:38 +08:00
|
|
|
doc-eigen-prerequisites
|
2007-12-21 19:29:04 +08:00
|
|
|
ALL
|
2008-08-27 14:43:42 +08:00
|
|
|
COMMAND ${CMAKE_COMMAND} -E make_directory ${CMAKE_CURRENT_BINARY_DIR}/html/
|
2008-08-25 18:49:53 +08:00
|
|
|
COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_SOURCE_DIR}/eigendoxy_tabs.css
|
|
|
|
${CMAKE_CURRENT_BINARY_DIR}/html/
|
|
|
|
COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_SOURCE_DIR}/Eigen_Silly_Professor_64x64.png
|
|
|
|
${CMAKE_CURRENT_BINARY_DIR}/html/
|
2009-02-18 18:27:18 +08:00
|
|
|
COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_SOURCE_DIR}/AsciiQuickReference.txt
|
|
|
|
${CMAKE_CURRENT_BINARY_DIR}/html/
|
2007-12-21 19:29:04 +08:00
|
|
|
WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}
|
|
|
|
)
|
|
|
|
|
2009-02-04 23:37:00 +08:00
|
|
|
add_custom_target(
|
2009-03-11 21:11:38 +08:00
|
|
|
doc-unsupported-prerequisites
|
2009-02-04 23:37:00 +08:00
|
|
|
ALL
|
|
|
|
COMMAND ${CMAKE_COMMAND} -E make_directory ${Eigen_BINARY_DIR}/doc/html/unsupported
|
|
|
|
COMMAND ${CMAKE_COMMAND} -E copy ${Eigen_SOURCE_DIR}/doc/eigendoxy_tabs.css
|
|
|
|
${Eigen_BINARY_DIR}/doc/html/unsupported/
|
|
|
|
COMMAND ${CMAKE_COMMAND} -E copy ${Eigen_SOURCE_DIR}/doc/Eigen_Silly_Professor_64x64.png
|
|
|
|
${Eigen_BINARY_DIR}/doc/html/unsupported/
|
|
|
|
WORKING_DIRECTORY ${Eigen_BINARY_DIR}/doc
|
|
|
|
)
|
|
|
|
|
2009-03-11 21:11:38 +08:00
|
|
|
add_dependencies(doc-eigen-prerequisites all_snippets all_examples)
|
2009-12-08 03:10:11 +08:00
|
|
|
add_dependencies(doc-unsupported-prerequisites unsupported_snippets unsupported_examples)
|
2009-03-11 21:11:38 +08:00
|
|
|
add_custom_target(doc ALL
|
|
|
|
COMMAND doxygen Doxyfile-unsupported
|
|
|
|
COMMAND doxygen
|
|
|
|
COMMAND doxygen Doxyfile-unsupported # run doxygen twice to get proper eigen <=> unsupported cross references
|
|
|
|
WORKING_DIRECTORY ${Eigen_BINARY_DIR}/doc)
|
|
|
|
add_dependencies(doc doc-eigen-prerequisites doc-unsupported-prerequisites)
|