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

-Wundef warnings on by default / preprocessor fixes #1234

merged 2 commits into from Mar 14, 2017


Copy link

commented Jan 19, 2017

This PR introduces the following changes:

  • Turns on -Wundef when building firmware. Coupled with -Werror, this should allow to catch all the broken preprocessor conditionals
  • Fixes preprocessor errors encountered after ^
  • Due to a bug in gcc, #pragma GCC diagnostic doesn't seem to be applied ( causing errors when including boost. Boost headers that cause errors with -Wundef and -Werror are wrapped in separate header files with #pragma GCC system_header which causes warnings to be treated as warnings again.

This PR also fixes #1139.


  • Contributor has signed CLA
  • Problem and Solution clearly stated
  • Code peer reviewed
  • API tests compiled
  • Run unit/integration/application tests on device
  • Add documentation (specifically what errors may have been lurking before and how they might have affected users)
  • Add to after merging (add links to docs and issues)


  • [PR #1234] [Fixes #1139] [Electron] spark/hardware/max_binary event was sent in error, adding 69 more bytes of data to handshake (full or session resume). Also fixes other preprocessor errors.
avtolstoy added 2 commits Jan 19, 2017
- Turns on -Wundef
- Fixes preprocessors errors
- Fixes gcc platform builds (mostly due to warning in boost)

@avtolstoy avtolstoy added this to the 0.7.0 milestone Jan 19, 2017

@technobly technobly added the bug label Jan 23, 2017

@technobly technobly added the confirmed label Mar 14, 2017

@technobly technobly merged commit cb8a39c into develop Mar 14, 2017

2 checks passed

continuous-integration/travis-ci/pr The Travis CI build passed
continuous-integration/travis-ci/push The Travis CI build passed

@technobly technobly deleted the feature/undef-errors branch Mar 14, 2017

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
None yet
2 participants
You can’t perform that action at this time.