SmartThingsCommunity / st-device-sdk-c-ref

SmartThings SDK Reference for Direct Connected Devices for C
Apache License 2.0
119 stars 172 forks source link

error: 'x509_crt_verify_strings' defined but not used. #100

Closed shivanshu-semwal closed 2 years ago

shivanshu-semwal commented 2 years ago

I'm following the getting started guide, when I reach the step for building i get this error,

python build.py apps/esp8266/switch_example    
Python requirements from /home/ant/st-device-sdk-c-ref/bsp/esp8266/requirements.txt are satisfied.
GENCONFIG
WARNING: esp-idf git submodule components/mbedtls/mbedtls may be out of date. Run 'git submodule update' in IDF_PATH dir to update.
WARNING: Toolchain version is not supported: esp-2020r3-49-gd5524c1
Expected to see version: crosstool-ng-1.22.0-100-ge567ec7
Please check ESP-IDF setup instructions and update the toolchain, or proceed at your own risk.
WARNING: Compiler version is not supported: 8.4.0
Expected to see version(s): 5.2.0
Please check ESP-IDF setup instructions and update the toolchain, or proceed at your own risk.
CC build/bootloader/main/bootloader_start.o
AR build/bootloader/main/libmain.a
.
.
.
CC build/mbedtls/mbedtls/library/x509_create.o
CC build/mbedtls/mbedtls/library/md2.o
CC build/mbedtls/mbedtls/library/chacha20.o
CC build/mbedtls/mbedtls/library/ssl_srv.o
CC build/mbedtls/mbedtls/library/x509_crt.o
/home/ant/st-device-sdk-c-ref/bsp/esp8266/components/mbedtls/mbedtls/library/x509_crt.c:1676:44: error: 'x509_crt_verify_strings' defined but not used [-Werror=unused-const-variable=]
 static const struct x509_crt_verify_string x509_crt_verify_strings[] = {
                                            ^~~~~~~~~~~~~~~~~~~~~~~
cc1: some warnings being treated as errors
make[1]: *** [/home/ant/st-device-sdk-c-ref/bsp/esp8266/make/component_wrapper.mk:292: mbedtls/library/x509_crt.o] Error 1
make: *** [/home/ant/st-device-sdk-c-ref/bsp/esp8266/make/project.mk:571: component-mbedtls-build] Error 2
shivanshu-semwal commented 2 years ago

I was using new version of the toolchain that was causing the problem. I fixed it by using the one mentioned in the README.md - this one