zephyrproject-rtos / zephyr

Primary Git Repository for the Zephyr Project. Zephyr is a new generation, scalable, optimized, secure RTOS for multiple hardware architectures.
https://docs.zephyrproject.org
Apache License 2.0
10.49k stars 6.42k forks source link

Build failure when building ESP32 with WiFi, File System, and POSIX API all turned on #63823

Closed sam-golioth closed 8 months ago

sam-golioth commented 11 months ago

Describe the bug

ESP32_DevKitC_WROVER fails to build when WiFi is enabled alongside the filesystem POSIX API, due to a redefinition of the CONFIG_POSIX_FS macro. The symbol is defined by kconfig as well as hardcoded in modules/hal/espressif/zephyr/esp32/src/wifi/esp_wifi_adapter.c line 11.

To Reproduce

Steps to reproduce the behavior:

  1. west build -p -b esp32_devkitc_wrover samples/net/wifi -- -DCONFIG_POSIX_API=y -DCONFIG_FILE_SYSTEM=y

Expected behavior

The build completes successfully.

Impact

The POSIX filesystem API must be disabled to use ESP32 WiFi.

Logs and console output

/Users/samfriedman/golioth/test_cp_sdk_zephyr/modules/hal/espressif/zephyr/esp32/src/wifi/esp_wifi_adapter.c:11: error: "CONFIG_POSIX_FS" redefined [-Werror]
   11 | #define CONFIG_POSIX_FS
      |
In file included from <command-line>:
/Users/samfriedman/golioth/test_cp_sdk_zephyr/zephyr/samples/net/wifi/build/zephyr/include/generated/autoconf.h:407: note: this is the location of the previous 
definition
  407 | #define CONFIG_POSIX_FS 1
      |
cc1: all warnings being treated as errors
[117/354] Building C object 
zephyr/CMakeFiles/zephyr.dir/Users/samfriedman/golioth...cp_sdk_zephyr/modules/hal/espressif/components/wpa_supplicant/src/tls/bignum.c.obj
ninja: build stopped: subcommand failed.
FATAL ERROR: command exited with status 1: /Users/samfriedman/miniconda3/envs/golioth/bin/cmake --build 
/Users/samfriedman/golioth/test_cp_sdk_zephyr/zephyr/samples/net/wifi/build

Environment (please complete the following information):

github-actions[bot] commented 8 months ago

This issue has been marked as stale because it has been open (more than) 60 days with no activity. Remove the stale label or add a comment saying that you would like to have the label removed otherwise this issue will automatically be closed in 14 days. Note, that you can always re-open a closed issue at any time.