Skip to content
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

Address CI build warnings #2742

Merged
merged 8 commits into from
Mar 25, 2024
Merged

Conversation

mikee47
Copy link
Contributor

@mikee47 mikee47 commented Mar 24, 2024

This PR addresses warnings which have crept into the CI build logs.
Worst case is probably esp32 with IDF 5.2 (GCC 13.2) producing 350 warnings, now 65.

General fixes

Fix compiler warnings/errors

Replaced a few more instances of printf with streaming operators, simpler and type-safe.
Fixed Overloaded virtual warnings.

Note: See remaining warnings for NimBLE (submodule) which need attention.

Graphics library fixes

  • Fix control rendering: Should use their own bounds for positioning, set button font
  • Fix const parameters
  • use unique_ptr for getGlyph calls
  • Use std::make_unique and assignment instead of reset()
  • Avoid printf
  • Demote reinterpret_cast to static_cast where appropriate
  • Apply coding style to samples
  • Fix compiler warnings

Disable esp32 warning about RWX segments

Check introduced with linker (LD, binutils 2.39) from IDF 5.2 onwards
This specifically refers to IRAM, which we do actually need to be writeable and executable.
(IDF link code disables this warning also.)

mikee47 added 8 commits March 24, 2024 15:33
- Run test with lower log verbosity
- Fix control rendering: Should use their own bounds for positioning, set button font
- Fix const parameters
- use unique_ptr for getGlyph calls
- Use `std::make_unique` and assignment instead of reset()
- Avoid printf
- Demote `reinterpret_cast` to `static_cast` where appropriate
- Apply coding style to samples
- Fix compiler warnings
Check introduced with linker (LD, binutils 2.39) from IDF 5.2 onwards
This specifically refers to IRAM, which we do actually need to be writeable and executable
@mikee47 mikee47 force-pushed the fix/compile-warnings branch from 5733d58 to bcc9a59 Compare March 24, 2024 20:42
@slaff slaff added this to the 5.2.0 milestone Mar 25, 2024
@mikee47
Copy link
Contributor Author

mikee47 commented Mar 25, 2024

@slaff codeql still running on ubuntu-20.04, actions for this and coverity scan, release and spelling-check could be updated. Shall we do that here or in a separate PR?

NB. Also readthedocs can be updated.

@slaff
Copy link
Contributor

slaff commented Mar 25, 2024

Shall we do that here or in a separate PR? ... Also readthedocs can be updated.

@mikee47 I would prefer separate PRs. Thank you for your hard work.

@slaff
Copy link
Contributor

slaff commented Mar 25, 2024

@mikee47 are you ready with this PR?

@mikee47
Copy link
Contributor Author

mikee47 commented Mar 25, 2024

@slaff Yes, all done thanks.

@slaff slaff merged commit 629678a into SmingHub:develop Mar 25, 2024
46 checks passed
@mikee47 mikee47 deleted the fix/compile-warnings branch March 25, 2024 19:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants