Open IraSch opened 8 months ago
Hi @IraSch. I'm going to ask you to post the full output from a compilation. Please do this:
I am able to get my sketch to compile now. What I did was to put ArdruinoBearSSLConfig.h (with the DEFINE uncommented) in with the other Bear library files instead of having it in the same folder as my sketch.
Thank you for your help and for your library
I suspected this was the problem. Unfortunately https://github.com/arduino-libraries/ArduinoBearSSL/pull/45 was not tested. The system of putting the ArduinoBearSSLConfig.h
in the sketch folder as demonstrated in the library examples is fatally flawed because, at least in the official boards platforms (the situation is different for the 3rd party "STM32 MCU based boards" platform and perhaps some other 3rd party platforms), the sketch folder is intentionally not added to the the compiler's "search path", so this conditional will always evaluate as false
:
and thus an ArduinoBearSSLConfig.h
in the sketch folder will have no effect on the library, as was previously reported three years ago at https://github.com/arduino-libraries/ArduinoBearSSL/pull/45#issuecomment-817744608, but never acted on.
In order to avoid other users suffering from the same poor experience caused by this defect, the pointless ArduinoBearSSLConfig.h
files must be removed from the examples and the correct way to use the ArduinoBearSSLConfig.h
system documented. We will use this issue to track that task so it must remain open even though you are no longer suffering from it.
I installed the BearSSL library latest version. I put the
ArduinoBearSSLConfig.h
file in the same directory as my sketch, and modified it to uncomment the line:In my sketch I have
But I get a compile error:
I also tried adding the
#define
at the top of my sketch, but still get the compile error.I thought I saw someone else using this library with MKR1000, so I must be missing something.