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

Clean up defines in src/platform/BUILD.gn #7575

Merged

Conversation

mspang
Copy link
Contributor

@mspang mspang commented Jun 13, 2021

  • Separate true/false defines are no longer required, as the header
    generator maps "true" to 1 and "false" to 0.

  • We should be setting false config #defines to 0 so that we
    can build with -Wundef

Move defines into the main list where possible so that they are always
added to the generated header.

Tested by:

git revert -n HEAD
./gn_build.sh enable_efr32_builds=true enable_qpg6100_builds=true is_debug=false
cp -a --reflink out/debug out/debug_old
git reset --hard
./gn_build.sh enable_efr32_builds=true enable_qpg6100_builds=true is_debug=false
find out/debug -name CHIPDeviceBuildConfig.h | while read x; do diff -u <(sort $(echo $x | sed s,debug,debug_old,)) <(sort $x); done|less

@todo
Copy link

todo bot commented Jun 13, 2021

should be fatal for development. Change once bugs are fixed

# TODO: should be fatal for development. Change once bugs are fixed
chip_stack_lock_tracking = "log"
} else {
# TODO: may want to enable at least logging for embedded to find bugs
# this needs tuning depending on how many resources various platforms have
# available (mainly flash size)
chip_stack_lock_tracking = "none"
}
} else {
assert(
chip_stack_lock_tracking == "none" ||


This comment was generated by todo based on a TODO comment in bcadfbf in #7575. cc @mspang.

@todo
Copy link

todo bot commented Jun 13, 2021

may want to enable at least logging for embedded to find bugs

# TODO: may want to enable at least logging for embedded to find bugs
# this needs tuning depending on how many resources various platforms have
# available (mainly flash size)
chip_stack_lock_tracking = "none"
}
} else {
assert(
chip_stack_lock_tracking == "none" ||
chip_stack_lock_tracking == "log" ||
chip_stack_lock_tracking == "fatal",
"Please select a valid value for chip_stack_lock_tracking: auto, none, log, fatal")


This comment was generated by todo based on a TODO comment in bcadfbf in #7575. cc @mspang.

- Separate true/false defines are no longer required, as the header
  generator maps "true" to 1 and "false" to 0.

- We should be setting false config #defines to 0 so that we
  can build with -Wundef

Move defines into the main list where possible so that they are always
added to the generated header.
@mspang mspang force-pushed the for-chip/cleanup-platform-defines branch from 229c191 to bdc5fd8 Compare June 14, 2021 02:24
@andy31415 andy31415 merged commit 732e1c0 into project-chip:master Jun 14, 2021
@mspang mspang deleted the for-chip/cleanup-platform-defines branch June 14, 2021 21:01
vivien-apple added a commit to vivien-apple/connectedhomeip-1 that referenced this pull request Jun 15, 2021
vivien-apple added a commit to vivien-apple/connectedhomeip-1 that referenced this pull request Jun 15, 2021
vivien-apple added a commit to vivien-apple/connectedhomeip-1 that referenced this pull request Jun 15, 2021
nikita-s-wrk pushed a commit to nikita-s-wrk/connectedhomeip that referenced this pull request Sep 23, 2021
- Separate true/false defines are no longer required, as the header
  generator maps "true" to 1 and "false" to 0.

- We should be setting false config #defines to 0 so that we
  can build with -Wundef

Move defines into the main list where possible so that they are always
added to the generated header.
nikita-s-wrk pushed a commit to nikita-s-wrk/connectedhomeip that referenced this pull request Sep 23, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants