Skip to content

Add compiler flags : -fno-rtti, -fno-exceptions, -fno-non-call-exceptions,... #389

@JF002

Description

@JF002

I really thought these flags were already enabled but... it looks like they are not!

We are in an embedded system, we don't need some high level functionalities like exceptions and RTTI. Disabling these functionalities at build time should reduce the size of the final binary.

I think we should be able to add -fno-exceptions -fno-non-call-exceptions -fno-rtti to COMMON_FLAGS in src/CMakeLists.txt.
It might be interesting to experiment with other flags mentioned here : https://bitbashing.io/embedded-cpp.html

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions