-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Description
- Operating system: Linux
- Stlink tools version and/or git commit hash: latest/git-9d08810
Cloning the repository, pushing it to somewhere else, and cloning it from that second place breaks the build process.
Error from make:
CMake Error at CMakeLists.txt:91 (set_target_properties):
set_target_properties called with incorrect number of arguments.
It seems to fail because some of the variables in
set_target_properties(${STLINK_LIB_SHARED}
PROPERTIES SOVERSION ${PROJECT_VERSION_MAJOR}
VERSION ${STLINK_SHARED_VERSION}
)
end up being empty, because cmake/Version.cmake tries to get the values with git describe which fails because it doesn't find any names, presumably because the tags aren't pushed by default.
Doing a git push --tags from a repo cloned directly from the official repository to the other repository, followed by git pull --tags in the non-working copy fixes this.
I suggest that in addition to checking that git exists and the project is under git, cmake/Version.cmake should also check that the repository actually contains any tags before taking the git-aware branch of the conditional.