-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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
fix: Use the same compiler options for xrpl.libxrpl and all its submodules #5228
Conversation
* Treats warnings as errors so the build will fail, avoiding further problems down the line. * Also include OS and compiler information in the dependencies environment dump.
* Resolves an issue introduced by XRPLF#5111, which inadvertently removed the -Wno-maybe-uninitialized compiler option from those modules. This resulted in new "may be used uninitialized" build warnings, first noticed in the "protocol" module. When compiling with derr=TRUE, those warnings became errors, which made the build fail.
Compiler options like |
…bmodules" This reverts commit e103657.
* Resolves an issue introduced by XRPLF#5111, which inadvertently removed the -Wno-maybe-uninitialized compiler option from some modules. This resulted in new "may be used uninitialized" build warnings, first noticed in the "protocol" module. When compiling with derr=TRUE, those warnings became errors, which made the build fail.
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## develop #5228 +/- ##
=========================================
- Coverage 78.0% 78.0% -0.0%
=========================================
Files 789 789
Lines 66953 66955 +2
Branches 8107 8110 +3
=========================================
- Hits 52218 52213 -5
- Misses 14735 14742 +7
|
* upstream/develop: chore: add macos dependency installation (5233) prefix Uint384 and Uint512 with Hash in server_definitions (5231) refactor: add `rpcName` to `LEDGER_ENTRY` macro (5202)
Note to self: Also need to move the Edit Turns out that target properties don't propagate to dependents the way compile definitions and options do. So I added a |
* Turns out that target properties don't propagate to dependents the way compile definitions and options do.
* upstream/develop: chore: update deprecated Github Actions (5241) XLS-46: DynamicNFT (5048)
This reverts commit 2b12370.
* Removes the need to set the UNITY_BUILD property on each project, except xrpl.libpb, where it needs to be forced OFF.
* upstream/develop: Fix failing assert in `connect` RPC (5235)
With
This is not new, but given the aim of this PR is to revive the
The identical fix is also in #5224 (thanks to @thejohnfreeman ) but of course that PR will take much longer to finish, review and merge. |
With
|
That patch feels really hacky. Then again, any workaround is probably going to feel hacky. I don't have easy access to gcc13 right now, so I'll apply the patch and commit so we can move forward. I'm curious, though, do you get any different results from either:
or
|
This fails:
This also fails:
However, I think you will like this one better, and it does compile cleanly on gcc 13 (go figure):
|
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.
Some minor remarks aside which are for your consideration but aren't blockers, I like this change a lot.
D'oh! What an oversight! I'll change it to |
Annoyingly, this fails with gcc 13, while
|
Commit message:
|
Issues have been resolved. John is not expected to be available to follow-up.
High Level Overview of Change
xrpl.libxrpl
cmake module to the dependency modules introduced by Enforce levelization in libxrpl with CMake #5111.assert
andwerr
options turned on. This will cause CI jobs to fail if a developer introduces a new compiler warning, or causes anassert
to fail in release builds.Context of Change
#5111 reorganized the folders in
src/libxrpl
into dependencies of thexrpl.libxrpl
cmake library. Unfortunately, this caused those modules to no longer have the settings that were applied toxrpl.libxrpl
.One of those settings was the
-Wno-maybe-uninitialized
compiler option, which resulted in new "may be used uninitialized" build warnings. When compiling with derr=TRUE, those warnings became errors, which made the build fail. The first occurence was in the "protocol" module, but there were others.(Incidentally, this also disabled Antithesis instrumentation (#5042 #5213) in those modules.)
Type of Change
Before / After
Before:
werr
cmake option is enabled.After:
werr
cmake option is enabled.Test Plan
This does not directly change any source code or functionality, so as long as the build works, and existing tests pass, all is well.
Suggested commit message