I move my embedded toolchain for C++ SAMD21 from Ubuntu 16 to Ubuntu 20.4 and arm-none-eabi-g++ no longer compiles my project. This is the error I get:
arm-none-eabi-g++: fatal error: -fuse-linker-plugin, but liblto_plugin.so not found
compilation terminated.
Seems like liblto_plugin is either not installed, or installed but not found. What is this library and how could I solve this issue?
My makefile runs this:
/home/reneman/toolchain/arm2021/arm-none-eabi-gcc/7-2017q4/bin/arm-none-eabi-g++ -mcpu=cortex-m0plus -mthumb -c -g -Os -w -std=gnu++11 -ffunction-sections -fdata-sections -fno-threadsafe-statics -nostdlib --param max-inline-insns-single=500 -fno-rtti -fno-exceptions -MMD -DF_CPU=48000000L -DSAM21 -Iinclude -I../../../myOS.v11/HardwareSAM21/include -I../../../myOS.v11/ports/include -c src/Principal.cpp -o obj/sam21/Principal.o
/home/reneman/toolchain/arm2021/arm-none-eabi-gcc/7-2017q4/bin/arm-none-eabi-g++ -L../../../myOS.v11/lib/sam21 ../../../myOS.v11/lib/sam21/libRenesys.a -o bin/sam21/myOS.elf obj/sam21/Principal.o -mcpu=cortex-m0plus -mthumb -specs=nano.specs -specs=nosys.specs -Wl,--gc-sections -Wl,--script=/home/reneman/toolchain/arm2021/linker/samd21j18.ld -lKernelComunicacion -lEthernet -lPuertos -lSPI -lHALCore -lHAL -lstreaming -lHardwareSAM21 -lCoreSAM21
Thanks,