User applications can include their own version of mbedtls

v0.5.0-rc.2 breaks my use of tropicssl aes 128 encryption. I have attempted to use the mbedtls library, but get a compilation error when compiling locally. “dirent.h not supported”

I use the command

make clean all program-dfu PLATFORM=electron APP=SensorNode APPDIR=/app/SensorNode

I attempted to disable the x509 modules in config.h but it didn’t seem to help.

I’m wondering if there’s a newer version of the ARM GCC CCP compiler, I’m currently on version gcc-arm-none-eabi-4_9-2015q3

Rather than replacing one problem (tropicSSL not compling) with another (mbedtls) - please tell us what the problem is with tropicSSL - that might be simpler to fix than jumping to an entirely new SSL implementation.

I’ve been using the tropicssl hack mentioned here, Link error trying to use AES

after pulling the v0.5.0-rc.2 and rc1 I get the following error.

libraries/tropicssl/aes.c:42:30: fatal error: tropicssl/config.h: No such file or directory

I suggest copying the headers and sources into your application folder from the communication module sources, so that’s a permanent part of your application. This will isolate your application from changes to the internals of system firmware (such as the one we just did where the tropicSSL headers are now private and not exposed to applications to avoid conflicts.)

ok, I’ve moved all the files over, new error.

make[2]: *** No rule to make target `../build/target/user/platform-10-m/SensorNode/SensorNode/lib/tropicssl/library/aes.o', needed by `../build/target/user/platform-10-m/SensorNode/SensorNode/libuser.a'.  Stop.

it’s looking for the files in /lib/tropicssl when it should be looking for the files in /libraries/tropicssl

Did you do a clean build? remove build/target to be sure.

yeah, I’ve tried both. same issue

what does your application source tree look like?

you’ll need to flatten the structure - copy the headers and *.c files to ./tropicSSL and delete all other files and folders (in particular .mk files.) - just like the other libraries you have there.

ok, flattened structure

/app/SensorNode/libraries/tropicssl/aes.c:42:30: fatal error: tropicssl/config.h: No such file or directory

going through and localizing all references to tropicssl files… Succcess!

1 Like


1 Like

Hi @entropealabs , what does it mean “localizing” in this context? thanks!

see here,

I moved the tropicssl library into my local libraries directory, and “localized” the includes.

1 Like