-
Notifications
You must be signed in to change notification settings - Fork 7
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
🔨 (cmake): FirmwareKit - depend on os_version file #1231
Conversation
Codecov Report
@@ Coverage Diff @@
## develop #1231 +/- ##
========================================
Coverage 96.16% 96.16%
========================================
Files 146 146
Lines 3594 3594
========================================
Hits 3456 3456
Misses 138 138 📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more |
File comparision analysis report🔖 Info
Click to show memory sections
📝 SummaryClick to show summary
🗺️ Map files diff outputClick to show diff list
|
File comparision analysis report🔖 Info
Click to show memory sections
📝 SummaryClick to show summary
🗺️ Map files diff outputClick to show diff list
|
3c4afb2
to
2b9f7b1
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Decide if the project depend or not on semver
Version current_version = Version { | ||
semver::version {OS_VERSION}.major, | ||
semver::version {OS_VERSION}.minor, | ||
semver::version {OS_VERSION}.patch, | ||
}; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is in conflict with issue
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yes and no -- the idea of removing semver was to remove complicated code just to get the version number.
semver is using constexpr
almost everywhere, which means that the actual work is done at compile time and not run time, so the final binary should only have the actual major, minor and patch values.
this must be further investigated to be confirmed.
on the other hand, removing semver will mean finding another way to parse the OS_VERSION, either by using lines for each values or different files. A bit more complicated to handle cleanly in cmake.
also, semver is already being used in embedded code, so using it in unit tests is normal and cleans up things while we investigate further and decide to keep it or remove it for something else.
2b9f7b1
to
26a4fcf
Compare
This commit make FirmwareKit (and directory) depend on os_version config file This means that when the version is updated, cmake configure is run again and the os_version.h file is regenerated with the new version This should make development as build number could be added in the future as well
26a4fcf
to
d873d33
Compare
d873d33
to
7f77528
Compare
Kudos, SonarCloud Quality Gate passed!
|
This commit make FirmwareKit (and directory) depend on os_version config
file
This means that when the version is updated, cmake configure is run
again and the os_version.h file is regenerated with the new version
This should make development as build number could be added in the
future as well