Make sure that version info is updated before building code

Otherwise, the library may be declared "done" before the version number
process have had any change to touch files it depends upon. This ensures
that the version number is correct before we start building the library.
This commit is contained in:
Roland Kaufmann 2013-07-31 12:58:12 +02:00
parent 155bb2fc9c
commit 764c3c8e60

View File

@ -23,3 +23,8 @@ add_custom_target (update-version ALL
-P ${PROJECT_SOURCE_DIR}/cmake/Scripts/WriteVerSHA.cmake
COMMENT "Updating version information"
)
# the target above gets built every time thanks to the "ALL" modifier,
# but it must also be done before the main library so it can pick up
# any changes it does.
add_dependencies (${${project}_TARGET} update-version)