e-Paper
e-Paper copied to clipboard
Rohoog/compile opt
This changes the optimization flag -O0 (no optimization) to -O and uses -ffunction-sections and -fdata-sections in combination with --gc-sections for linker to remove unused parts of the example code from the binary. After stripping and leaving only one demo (the typical situation), binary will be reduced to about 64KB (on aarch64).
Without the array index overflow change, the optimization will expose the index overflow problem. The epd binary will cause a segmentation fault at the very end of the run.