summaryrefslogtreecommitdiffstats
path: root/data/gendoc
diff options
context:
space:
mode:
authorMichele Calgaro <michele.calgaro@yahoo.it>2026-01-08 22:21:09 +0900
committerMichele Calgaro <michele.calgaro@yahoo.it>2026-01-22 13:29:16 +0900
commit79d24411875b27f4af6278c6ad9186158b3aa3b8 (patch)
treec638c28eeddd69a9e8b9b0feb0d6f870aaf7a773 /data/gendoc
parente304398a568bfdba21ff36074c21e0799d5bba48 (diff)
downloadkvirc-feat/cmake-conversion.tar.gz
kvirc-feat/cmake-conversion.zip
Signed-off-by: Michele Calgaro <michele.calgaro@yahoo.it>
Diffstat (limited to 'data/gendoc')
-rw-r--r--data/gendoc/CMakeLists.txt19
1 files changed, 19 insertions, 0 deletions
diff --git a/data/gendoc/CMakeLists.txt b/data/gendoc/CMakeLists.txt
new file mode 100644
index 0000000..3336f3f
--- /dev/null
+++ b/data/gendoc/CMakeLists.txt
@@ -0,0 +1,19 @@
+file( GLOB_RECURSE _h_files RELATIVE ${CMAKE_SOURCE_DIR} ${CMAKE_SOURCE_DIR}/*.h )
+file( GLOB_RECURSE _cpp_files RELATIVE ${CMAKE_SOURCE_DIR} ${CMAKE_SOURCE_DIR}/*.cpp )
+
+set( GENERATE_DIR "${CMAKE_BINARY_DIR}/gendoc" )
+
+add_custom_target(generate_docfiles ALL
+ COMMAND ${CMAKE_COMMAND} -E make_directory ${GENERATE_DIR}
+ COMMAND perl data/gendoc/gendoc.pl -v ${PACKAGE_VERSION} ${GENERATE_DIR}
+ data/doctemplates/*.template ${_cpp_files} ${_h_files}
+ WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}
+)
+
+install(CODE "
+ file(
+ INSTALL ${GENERATE_DIR}/
+ DESTINATION ${DATA_INSTALL_DIR}/${PROJECT_NAME}/help/en
+ PATTERN *.html
+ )
+")