Now I cannot reproduce as your claimed error with flto and fno-exceptions. Taking your case with following build.bat, it run successfully on my Windows box:
------------
path c:\windows;c:\windows\system32
set GXX="c:\Program Files (x86)\GNU Tools ARM Embedded\8 2019-q3-update\bin\arm-none-eabi-g++.exe"
set CXXFLAGS=-ggdb -ffunction-sections -fdata-sections -std=gnu++14 -fno-rtti -fno-exceptions
Michal,
Now I cannot reproduce as your claimed error with flto and fno-exceptions. Taking your case with following build.bat, it run successfully on my Windows box: c:\windows\ system32 update\ bin\arm- none-eabi- g++.exe"
------------
path c:\windows;
set GXX="c:\Program Files (x86)\GNU Tools ARM Embedded\8 2019-q3-
set CXXFLAGS=-ggdb -ffunction-sections -fdata-sections -std=gnu++14 -fno-rtti -fno-exceptions
%GXX% -flto -mcpu=cortex-m7 -mthumb %CXXFLAGS% -c wolf.cpp -o wolf.o
%GXX% -flto -mcpu=cortex-m7 -mthumb %CXXFLAGS% -c hornet.cpp -o hornet.o
%GXX% -flto -mcpu=cortex-m7 -mthumb %CXXFLAGS% -c syscalls.cpp -o syscalls.o
%GXX% -flto -mcpu=cortex-m7 -mthumb %CXXFLAGS% -c main.cpp -o main.o
%GXX% -flto -mcpu=cortex-m7 -mthumb %CXXFLAGS% wolf.o hornet.o main.o syscalls.o -o application.elf
------------
What did I miss?