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

manifest: Update Zephyr version #9577

Merged
merged 2 commits into from
Dec 2, 2022

Conversation

stephanosio
Copy link
Contributor

@stephanosio stephanosio commented Dec 2, 2022

This commit pulls in the local sdk-zephyr fixes for the printk-based logging and newlib POSIX definition conflicts.

Ref: NCSDK-18426
Ref: NCSIDB-890

@CLAassistant
Copy link

CLAassistant commented Dec 2, 2022

CLA assistant check
All committers have signed the CLA.

@github-actions github-actions bot added changelog-entry-required Update changelog before merge. Remove label if entry is not needed or already added. manifest labels Dec 2, 2022
This commit pulls in the local sdk-zephyr fixes for the printk-based
logging and newlib POSIX definition conflicts.

Ref: NCSDK-18426
Ref: NCSIDB-890

Signed-off-by: Stephanos Ioannidis <[email protected]>
@NordicBuilder
Copy link
Contributor

NordicBuilder commented Dec 2, 2022

The following west manifest projects have been modified in this Pull Request:

Name Old Revision New Revision Diff
matter nrfconnect/sdk-connectedhomeip@22a5206 nrfconnect/sdk-connectedhomeip@f4a75a5 (master) nrfconnect/[email protected]
zephyr nrfconnect/sdk-zephyr@24d82de nrfconnect/sdk-zephyr@c0689b1 (main) nrfconnect/[email protected]

Note: This message is automatically posted and updated by the Manifest GitHub Action.

@stephanosio stephanosio force-pushed the manifest_zephyr_221202 branch from 8b2ce73 to ac8d35f Compare December 2, 2022 13:39
@stephanosio stephanosio requested a review from nordicjm December 2, 2022 13:42
@nordicjm nordicjm added this to the 2.2.0 milestone Dec 2, 2022
@NordicBuilder
Copy link
Contributor

NordicBuilder commented Dec 2, 2022

Test specification

CI/Jenkins/NRF

  • Integration Platforms

CI/Jenkins/integration

Test Module File based changes Manually selected West overwrite
desktop52_verification X
test-fw-nrfconnect-ble X
test-fw-nrfconnect-ble_samples X
test-fw-nrfconnect-chip X
test-fw-nrfconnect-nfc X
test-fw-nrfconnect-nrf-iot_lwm2m X
test-fw-nrfconnect-nrf-iot_thingy91 X
test-fw-nrfconnect-nrf_crypto X
test-fw-nrfconnect-rpc X
test-fw-nrfconnect-rs X
test-fw-nrfconnect-tfm X
test-fw-nrfconnect-thread X
test-sdk-find-my X

test-fw-nrfconnect-chip: added because there was no .github/test-spec.yml in 'matter'

Detailed information of selected test modules

Note: This message is automatically posted and updated by the CI

@NordicBuilder
Copy link
Contributor

You can find the documentation preview for this PR at this link. It will be updated about 10 minutes after the documentation build succeeds.

Note: This comment is automatically posted by the Documentation Publishing GitHub Action.

@Damian-Nordic
Copy link
Contributor

Note that Matter depends on POSIX extensions, such as:

#if __POSIX_VISIBLE >= 200809
size_t	 strnlen (const char *, size_t);
#endif
#if __MISC_VISIBLE || __POSIX_VISIBLE
char 	*strtok_r (char *__restrict, const char *__restrict, char **__restrict);
#endif

It also must be built with gnu++14 standard. Therefore, I'm afraid we cannot set _ANSI_SOURCE unconditionally.

@stephanosio
Copy link
Contributor Author

It also must be built with gnu++14 standard. Therefore, I'm afraid we cannot set _ANSI_SOURCE unconditionally.

The problem is not that _ANSI_SOURCE is set, it is that _DEFAULT_SOURCE is no longer defined by default when -std=gnu because it is not supposed to be, as explained in nrfconnect/sdk-zephyr@c0689b1), and Matter is currently relying on this incorrect behaviour/quirk.

The following patch should fix the issue. I will send a PR to sdk-connectedhomeip soon.

diff --git a/config/nrfconnect/chip-module/CMakeLists.txt b/config/nrfconnect/chip-module/CMakeLists.txt
index ed844c2d5..2a123f299 100644
--- a/config/nrfconnect/chip-module/CMakeLists.txt
+++ b/config/nrfconnect/chip-module/CMakeLists.txt
@@ -91,6 +91,8 @@ set(GN_ROOT_TARGET ${CHIP_ROOT}/config/nrfconnect/chip-gn)
 
 # Prepare compiler flags
 
+list(APPEND CHIP_CFLAGS -D_DEFAULT_SOURCE)
+
 if (CONFIG_ARM)
     list(APPEND CHIP_CFLAGS_C
         --specs=nosys.specs
@@ -309,6 +311,7 @@ add_dependencies(chip-gn kernel)
 
 zephyr_interface_library_named(chip)
 target_compile_definitions(chip INTERFACE CHIP_HAVE_CONFIG_H)
+target_compile_definitions(chip INTERFACE _DEFAULT_SOURCE)
 target_include_directories(chip INTERFACE
     ${CHIP_ROOT}/src
     ${CHIP_ROOT}/src/include

This commit pulls in the local sdk-connectedhomeip fix that defines
`_DEFAULT_SOURCE` when compiling Matter.

Signed-off-by: Stephanos Ioannidis <[email protected]>
@stephanosio stephanosio force-pushed the manifest_zephyr_221202 branch from 3916d76 to c8645af Compare December 2, 2022 16:44
@NordicBuilder NordicBuilder removed the DNM label Dec 2, 2022
@nordicjm nordicjm merged commit 7d7d0e9 into nrfconnect:main Dec 2, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
changelog-entry-required Update changelog before merge. Remove label if entry is not needed or already added. manifest manifest-matter manifest-zephyr
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants