Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion src/rp2_common/pico_cyw43_arch/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,13 @@ if (PICO_CYW43_SUPPORTED) # set by BOARD=pico-w
pico_cyw43_arch_sys_freertos)
target_compile_definitions(pico_cyw43_arch_lwip_sys_freertos_headers INTERFACE
CYW43_LWIP=1
LWIP_PROVIDE_ERRNO=1
# FreeRTOS+lwIP uses newlib, which provides a thread-local errno

@kilograham kilograham Jun 16, 2026

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

um, who says it uses newlib? surely it is dependent on the compiler/toolchain?

# via <errno.h>. LWIP_PROVIDE_ERRNO=1 would declare lwIP's own
# `extern int errno` global, diverging from newlib's storage and
# silently breaking mbedTLS BIO shims (and any code reading errno
# via <errno.h>) that miss the EWOULDBLOCK lwIP wrote.
# LWIP_ERRNO_STDINCLUDE=1 routes lwIP through <errno.h> instead.
LWIP_ERRNO_STDINCLUDE=1
# now the default
#PICO_LWIP_CUSTOM_LOCK_TCPIP_CORE=1 # we want to override the lwip locking mechanism to use our mutex
)
Expand Down
Loading