CMakeLists.txt: add a comment

This commit is contained in:
Přemysl Eric Janouch 2020-04-06 01:44:17 +02:00 committed by Přemysl Eric Janouch
parent 6287e20919
commit 722fc48a30
Signed by: p
GPG Key ID: A0420B94F92B9493
1 changed files with 2 additions and 0 deletions

View File

@ -17,6 +17,8 @@ set (project_version "0.9.7")
# Try to append commit ID if it follows a version tag. It might be nicer if
# we could also detect dirty worktrees but that's very hard to get right.
# If we didn't need this for CPack, we could use add_custom_command to generate
# a version source/include file.
find_package (Git)
set (git_head "${PROJECT_SOURCE_DIR}/.git/HEAD")
if (GIT_FOUND AND EXISTS "${git_head}")