Repository navigation
build(cmake): read Source_Version before git describe - #437
Open
jolavillette wants to merge 1 commit into
Open
jolavillette wants to merge 1 commit into
jolavillette wants to merge 1 commit into
Conversation
A source tarball carries libretroshare's `git describe` in Source_Version, but the file was read only when git failed. When the tarball is unpacked inside another git repository (git-buildpackage, or any checkout), git succeeds there and describes that repository instead: the engine hash became the packaging tag (e.g. debian/0.6.8+ds-1-dirty), and when the enclosing repository carries v*.*.* tags (gbp with upstream history) the version did too. Read the file first when it exists, git otherwise, for both the version and the engine hash.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
A source tarball stores libretroshare's
git describeinSource_Version(#385), but CMake read the file only when git failed. When the tarball is unpacked inside another git repository, git succeeds there and describes that repository: built from a git-buildpackage repository (the usual way Debian packages are maintained), the engine hash became the packaging tag (debian/0.6.8+ds-1-dirty), and the version too when that repository carriesv*.*.*tags.Now
Source_Versionis read first when it exists, git otherwise, for both the version and the engine hash. A plain git checkout has noSource_Versionfile, so nothing changes there.The GUI side of the same fix is in RetroShare/RetroShare#3308.