找不到openssl/ssl.h头文件

greenstone
Posts: 20
Joined: Mon Jul 10, 2023 9:14 am

找不到openssl/ssl.h头文件

Postby greenstone » Tue Jul 11, 2023 1:56 am

Running ninja in directory /home/shihongbo/esp-idf/examples/esp32-lqwy-project-shi/build
Executing "ninja all"...
[1/1] cd /home/shihongbo/esp-idf/examples/esp32-lqwy-project-shi/build/bootloader/esp-idf/esptool_py && /home/shihong...fset 0x8000 bootloader 0x1000 /home/shihongbo/esp-idf/examples/esp32-lqwy-project-shi/build/bootloader/bootloader.bi
Bootloader binary size 0x6860 bytes. 0x7a0 bytes (7%) free.
[2/50] Building C object esp-idf/sta_protocols/CMakeFiles/__idf_sta_protocols.dir/openssl_cilent_node.c.objFAILED: esp-idf/sta_protocols/CMakeFiles/__idf_sta_protocols.dir/openssl_cilent_node.c.obj
/home/shihongbo/.espressif/tools/xtensa-esp32-elf/esp-12.2.0_20230208/xtensa-esp32-elf/bin/xtensa-esp32-elf-gcc -DESP_PLATFORM -DIDF_VER=\"v5.1-dev-4726-gdf9310ada2-dirty\" -DSOC_MMU_PAGE_SIZE=CONFIG_MMU_PAGE_SIZE -D_GNU_SOURCE -D_POSIX_READER_WRITER_LOCKS -Iconfig -I../components/sta_protocols/include -I../../../components/newlib/platform_include -I../../../components/freertos/FreeRTOS-Kernel/include -I../../../components/freertos/FreeRTOS-Kernel/portable/xtensa/include -I../../../components/freertos/esp_additions/include/freertos -I../../../components/freertos/esp_additions/include -I../../../components/freertos/esp_additions/arch/xtensa/include -I../../../components/esp_hw_support/include -I../../../components/esp_hw_support/include/soc -I../../../components/esp_hw_support/include/soc/esp32 -I../../../components/esp_hw_support/port/esp32/. -I../../../components/esp_hw_support/port/esp32/private_include -I../../../components/heap/include -I../../../components/log/include -I../../../components/soc/include -I../../../components/soc/esp32 -I../../../components/soc/esp32/include -I../../../components/hal/esp32/include -I../../../components/hal/include -I../../../components/hal/platform_port/include -I../../../components/esp_rom/include -I../../../components/esp_rom/include/esp32 -I../../../components/esp_rom/esp32 -I../../../components/esp_common/include -I../../../components/esp_system/include -I../../../components/esp_system/port/soc -I../../../components/esp_system/port/include/private -I../../../components/xtensa/include -I../../../components/xtensa/esp32/include -I../../../components/lwip/include -I../../../components/lwip/include/apps -I../../../components/lwip/include/apps/sntp -I../../../components/lwip/lwip/src/include -I../../../components/lwip/port/include -I../../../components/lwip/port/freertos/include -I../../../components/lwip/port/esp32xx/include -I../../../components/lwip/port/esp32xx/include/arch -I../main/include -I../components/remote/include -I../components/port/include -I../components/debug/include -I../../../components/esp_ringbuf/include -I../../../components/esp_wifi/include -I../../../components/esp_wifi/wifi_apps/include -I../../../components/esp_event/include -I../../../components/esp_phy/include -I../../../components/esp_phy/esp32/include -I../../../components/esp_netif/include -I../../../components/driver/include -I../../../components/driver/deprecated -I../../../components/driver/analog_comparator/include -I../../../components/driver/dac/include -I../../../components/driver/gpio/include -I../../../components/driver/gptimer/include -I../../../components/driver/i2c/include -I../../../components/driver/i2s/include -I../../../components/driver/ledc/include -I../../../components/driver/mcpwm/include -I../../../components/driver/parlio/include -I../../../components/driver/pcnt/include -I../../../components/driver/rmt/include -I../../../components/driver/sdio_slave/include -I../../../components/driver/sdmmc/include -I../../../components/driver/sigma_delta/include -I../../../components/driver/spi/include -I../../../components/driver/temperature_sensor/include -I../../../components/driver/touch_sensor/include -I../../../components/driver/twai/include -I../../../components/driver/uart/include -I../../../components/driver/usb_serial_jtag/include -I../../../components/driver/touch_sensor/esp32/include -I../../../components/esp_pm/include -I../components/linux_list/include -I../components/application/include -mlongcalls -Wno-frame-address -ffunction-sections -fdata-sections -Wall -Werror=all -Wno-error=unused-function -Wno-error=unused-variable -Wno-error=unused-but-set-variable -Wno-error=deprecated-declarations -Wextra -Wno-unused-parameter -Wno-sign-compare -Wno-enum-conversion -gdwarf-4 -ggdb -mfix-esp32-psram-cache-issue -mfix-esp32-psram-cache-strategy=memw -Og -fmacro-prefix-map=/home/shihongbo/esp-idf/examples/esp32-lqwy-project-shi=. -fmacro-prefix-map=/home/shihongbo/esp-idf=/IDF -fstrict-volatile-bitfields -fno-jump-tables -fno-tree-switch-conversion -DconfigENABLE_FREERTOS_DEBUG_OCDAWARE=1 -std=gnu17 -Wno-old-style-declaration -MD -MT esp-idf/sta_protocols/CMakeFiles/__idf_sta_protocols.dir/openssl_cilent_node.c.obj -MF esp-idf/sta_protocols/CMakeFiles/__idf_sta_protocols.dir/openssl_cilent_node.c.obj.d -o esp-idf/sta_protocols/CMakeFiles/__idf_sta_protocols.dir/openssl_cilent_node.c.obj -c ../components/sta_protocols/openssl_cilent_node.c
In file included from ../components/sta_protocols/openssl_cilent_node.c:1:
../components/sta_protocols/include/openssl_client_node.h:10:10: fatal error: openssl/ssl.h: No such file or directory
10 | #include "openssl/ssl.h"
| ^~~~~~~~~~~~~~~


目前准备把公司的老esp-idf v4.0构建的esp32工程迁移到v5.1,ubuntu20.04下编译,自己写了CMakeLists,idf.py build后出现找不到头文件openssl/ssl.h头文件,但是我看我的系统根目录下的/usr/include/openssl含有ssl.h,于是添加这个目录到环境变量,为什么还是出现找不到环境变量呢?我的PATH目录中含有usr/include/openssl子目录。为什么还找不到openssl/ssl.h

ESP_Gargamel
Posts: 786
Joined: Wed Nov 14, 2018 8:45 am

Re: 找不到openssl/ssl.h头文件

Postby ESP_Gargamel » Tue Jul 11, 2023 3:01 am

v4.4 及之前版本,IDF 中是有 openssl 组件的,v5.0 开始,IDF 中不再提供 openssl 组件。

参看:https://docs.espressif.com/projects/esp ... components

Who is online

Users browsing this forum: No registered users and 53 guests