Cannot move location counter backwards (Nulceo-F042K6 and mbed os)

Good morning

Can someone shed a light on this loader error message?

Linking .pio/build/nucleo_f042k6/firmware.elf
/home/me/PlatformIO/Projects/USB Device/.pio/build/nucleo_f042k6/STM32F042X6.ld.link_script.ld:82 cannot move location counter backwards (from 0000000020000998 to 0000000020000800)
collect2: error: ld returned 1 exit status
*** [.pio/build/nucleo_f042k6/firmware.elf] Error 1

Is the generated code too big?
Which would be strange as the used USBDevice library is specially for the F042K6 platform…

thanks in advance

Sounds like a weird version of an overflow message if maybe the previous linker segment gets to large and then it tries to set the current address to some other value, but that fails. The error message indicates you are 198 bytes beyond something.

Do you have the full project for reproduction?

I suspect it uses just too much RAM…assuming mbed os eats up too much…

Well I have the whole project…can I somehow export it including the installed library?

Just your project folder should be good enough to compile your project, shouldn’t it? A repo on github or google driver upload would be appreciated.

Uploaded the project here:

The library used is:

“__pkg_dir”: “/home/klingler/.platformio/lib/USBDevice”,
“__src_url”: “hg+”,
“name”: “USBDevice”,
“version”: “33c22b6de512”,
“authors”: [],
“frameworks”: [],
“platforms”: [],
“keywords”: []

thanks in advance