-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
Choose logging backend on a per-target basis #32119
Conversation
PR #32119: Size comparison from 27b8143 to 630e62b Full report (2 builds for cc32xx)
|
ac38549
to
7a43751
Compare
PR #32119: Size comparison from 598356c to 7a43751 Full report (2 builds for cc32xx)
|
PR #32119: Size comparison from 598356c to 735ae9c Increases above 0.2%:
Increases (8 builds for bl602, bl702, bl702l)
Decreases (7 builds for bl602, bl702, bl702l, qpg)
Full report (15 builds for bl602, bl702, bl702l, cc32xx, qpg, stm32)
|
PR #32119: Size comparison from 274719d to 259e656 Increases above 0.2%:
Increases (9 builds for bl602, bl702, bl702l, qpg)
Decreases (7 builds for bl602, bl702, bl702l)
Full report (15 builds for bl602, bl702, bl702l, cc32xx, qpg, stm32)
|
8b27c3d
to
f0bdb79
Compare
PR #32119: Size comparison from 274719d to f0bdb79 Increases above 0.2%:
Increases (9 builds for bl602, bl702, bl702l, qpg)
Decreases (7 builds for bl602, bl702, bl702l)
Full report (15 builds for bl602, bl702, bl702l, cc32xx, qpg, stm32)
|
PR #32119: Size comparison from 947fef5 to 0f62542 Increases above 0.2%:
Full report (79 builds for bl602, bl702, bl702l, cc13x4_26x4, cc32xx, cyw30739, esp32, linux, mbed, nxp, psoc6, qpg, stm32, telink, tizen)
|
PR #32119: Size comparison from 947fef5 to 658f1ae Increases above 0.2%:
Full report (46 builds for bl602, bl702, bl702l, cc13x4_26x4, cc32xx, cyw30739, linux, mbed, nxp, psoc6, qpg, stm32, tizen)
|
8348b26
to
0c9a960
Compare
PR #32119: Size comparison from 917cf26 to 0c9a960 Increases above 0.2%:
Full report (96 builds for bl602, bl702, bl702l, cc13x4_26x4, cc32xx, cyw30739, efr32, esp32, linux, mbed, nrfconnect, nxp, psoc6, qpg, stm32, telink, tizen)
|
PR #32119: Size comparison from 07ac2f1 to 0407588 Increases above 0.2%:
Full report (29 builds for bl602, bl702, bl702l, cc13x4_26x4, cc32xx, linux, mbed, nxp, qpg, stm32, tizen)
|
Executables and shared libraries now explicitly link with `platform/logging:default` or `platform/logging:stdio`, so that the `platform/logging:force_stdio` kludge is no longer needed. The `chip_monolithic_tests` gn arg has been moved to `build/chip/tests.gni`.
PR #32119: Size comparison from 07ac2f1 to 2a680bc Increases above 0.2%:
Full report (96 builds for bl602, bl702, bl702l, cc13x4_26x4, cc32xx, cyw30739, efr32, esp32, linux, mbed, nrfconnect, nxp, psoc6, qpg, stm32, telink, tizen)
|
Executables and shared libraries now explicitly link with `platform/logging:default` or `platform/logging:stdio`, so that the `platform/logging:force_stdio` kludge is no longer needed. The `chip_monolithic_tests` gn arg has been moved to `build/chip/tests.gni`.
This is no longer needed as of project-chip#32119
* Remove workarounds for stdio logging target This is no longer needed as of #32119 * Pull in android logging in the standard way
Problem
This PR aims to fix #30633, which is due to a hack used for selecting logging backend:
connectedhomeip/src/platform/logging/BUILD.gn
Lines 57 to 68 in 783c3e0
Changes
Following suggestions by @ksperling-apple, I created two separate targets:
platform/logging:default
andplatform/logging:stdio
. All executables and shared libraries built by this project, will now explicitly depend on one or the other.External code, which uses chip as a library, now also has an option to choose which logging backend gets used. By default, if it links against
libCHIP
, nothing should change. But now a second variant is also built, calledlibCHIP_using_stdio
. It is possible to choose which one will get linked from within CMake, by settingCONFIG_CHIP_FORCE_LOGGING_STDIO
. This is used by openiotsdk unit tests, which should continue logging to stdio, even though this platform usually uses the other logging backend.