extract documentation from cmake modules

This commit is contained in:
Radovan Bast
2015-06-04 15:59:55 +02:00
parent 2d23fd9e8c
commit 7d9a8a5797
4 changed files with 86 additions and 5 deletions

View File

@ -1,8 +1,10 @@
# determine program version from file, example: "14.1"
# the reason why this information is stored
# in a file and not as cmake variable
# is that cmake-unaware programs can
# parse and use it (e.g. Sphinx)
#.rst:
#
# Determine program version from file "VERSION" (example: "14.1")
# The reason why this information is stored
# in a file and not as CMake variable is that CMake-unaware programs can parse
# and use it (e.g. Sphinx).
if(EXISTS "${PROJECT_SOURCE_DIR}/VERSION")
file(READ "${PROJECT_SOURCE_DIR}/VERSION" PROGRAM_VERSION)
string(STRIP "${PROGRAM_VERSION}" PROGRAM_VERSION)