From ee55027efa926a3a11ed333d0e3a5f1ed5c93c5b Mon Sep 17 00:00:00 2001 From: Marcin Kajor Date: Thu, 7 Mar 2024 11:44:35 +0100 Subject: [PATCH 1/3] [nrf noup] [nrfconnect] Disable Zephyr socket extensions The recvmsg() is now implemented natively in Zephyr, so we are not supposed to define a custom one. Signed-off-by: Marcin Kajor --- src/platform/nrfconnect/SystemPlatformConfig.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/platform/nrfconnect/SystemPlatformConfig.h b/src/platform/nrfconnect/SystemPlatformConfig.h index ce0df4d5f6..64ceccddaa 100644 --- a/src/platform/nrfconnect/SystemPlatformConfig.h +++ b/src/platform/nrfconnect/SystemPlatformConfig.h @@ -52,3 +52,6 @@ struct ChipDeviceEvent; #endif // ========== Platform-specific Configuration Overrides ========= + +// Disable Zephyr Socket extensions module, as the Zephyr RTOS now implements recvmsg() +#define CHIP_SYSTEM_CONFIG_USE_ZEPHYR_SOCKET_EXTENSIONS 0 From 16d3fd9ee6445dabc09d1738bc6b6bbba43613e8 Mon Sep 17 00:00:00 2001 From: Marcin Kajor Date: Mon, 11 Mar 2024 11:17:12 +0100 Subject: [PATCH 2/3] [nrf noup] [nrfconnect] Remove D_SYS__PTHREADTYPES_H_ flag ... from the gnu17 configuration to avoid missing pthread types definitions (_pthreadtypes.h). This tricked the preprocessor the header was already included, hence we didn't get its content. Signed-off-by: Marcin Kajor --- config/nrfconnect/app/enable-gnu-std.cmake | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/config/nrfconnect/app/enable-gnu-std.cmake b/config/nrfconnect/app/enable-gnu-std.cmake index 5f31e1a5c6..4019bbd31b 100644 --- a/config/nrfconnect/app/enable-gnu-std.cmake +++ b/config/nrfconnect/app/enable-gnu-std.cmake @@ -1,6 +1,5 @@ add_library(gnu17 INTERFACE) target_compile_options(gnu17 INTERFACE - $<$:-std=gnu++17> - -D_SYS__PTHREADTYPES_H_) + $<$:-std=gnu++17>) target_link_libraries(app PRIVATE gnu17) From 7527edbcb0f0407bffa93abc3e63da0952b1f9a4 Mon Sep 17 00:00:00 2001 From: Marcin Kajor Date: Mon, 11 Mar 2024 12:02:44 +0100 Subject: [PATCH 3/3] [nrf noup] [nrfconnect] Use newlib as a default libc implementation. The PICOLIB is now used by the default. NEWLIB_LIBC symbol is no longer selected by hostap. OpenThread selects NEWLIB_LIBC anyway. Signed-off-by: Marcin Kajor --- config/nrfconnect/chip-module/Kconfig.defaults | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/config/nrfconnect/chip-module/Kconfig.defaults b/config/nrfconnect/chip-module/Kconfig.defaults index 8afc13b113..552ca671b3 100644 --- a/config/nrfconnect/chip-module/Kconfig.defaults +++ b/config/nrfconnect/chip-module/Kconfig.defaults @@ -24,6 +24,10 @@ if CHIP # System configuration # ============================================================================== +choice LIBC_IMPLEMENTATION + default NEWLIB_LIBC +endchoice + config ASSERT default y