Enable various compilation flags to reduce the binary size (#401)
* Add the following compilation flags: * -fno-exceptions and -fno-non-call-exceptions : disable exception handling * -fno-rtti : disable run time type information (needed by dynamic_cast, for example) These flags reduce the binary size by about 100KB! Also, -fstack-usage generate debug info (not in final binary) to allow tools like Puncover to do a stack analysis. * Remove unused CMake variables in CMake_nRF5x.cmake (duplicated in src/CMakeLists.txt). Replace -O0 by -Og in DEBUG builds. This generates a smaller binary (small enough for the internal memory) that is debugger friendly.
This commit is contained in:
@@ -153,7 +153,7 @@ void DisplayApp::Refresh() {
|
||||
break;
|
||||
case Messages::TimerDone:
|
||||
if (currentApp == Apps::Timer) {
|
||||
auto *timer = dynamic_cast<Screens::Timer*>(currentScreen.get());
|
||||
auto *timer = static_cast<Screens::Timer*>(currentScreen.get());
|
||||
timer->setDone();
|
||||
} else {
|
||||
LoadApp(Apps::Timer, DisplayApp::FullRefreshDirections::Down);
|
||||
|
Reference in New Issue
Block a user