Hello,
I am trying to get the example code for the WebClient Compiled without the arduino GUI.
The good thing: It works.
The very bad thing: The code size jumps from 5486 Byte with the Arduino GUI up to 11058 Byes with a Makefile. Both resulting programs work as expected when uploaded. Note: I had to define
extern "C" void __cxa_pure_virtual(void);
void __cxa_pure_virtual(void) {};
because otherwise I get an error:
hardware/cores/arduino/Print.cpp:153: undefined reference to `__cxa_pure_virtual
I already tried to link the ready .o files from the arduino temporary directory, but this ends up in the linking error above. I already used strace to see what commands the GUI gives avr-gcc but there were nothing unusual. The only thing: If I do not add the -lm lib, the code size increases by an additional ~2KB.
It looks linke there is a lot of unused code removed, but I am really at the end of my knowledge whats going on in the magic GUI.
Any Ideas?