I didn’t find a specific category for this kind of problem, so I posted it here.
I wanted to use Eclipse and GNU embedded toolchain to build and debug my code.
So, I imported the mbed-os-example-blinky to the online compiler, and then exported as Eclipse-ARM-GCC for a Nucleo-F401RE target.
Then I installed Eclipse, its Embedded GCC extension, the embedded toolchain and the make utility for windows. I imported the project as “Makefile project from existing sources”, and i tried to build it.
But the make command generates this strange error:
make all
make[1]: *** [D:/Embedded/demos/mbed-os-example-blinky/Makefile:1938: mbed-os-example-blinky.elf] Error -1073741819
make: *** [Makefile:26: all] Error 2
"make all" terminated with exit code 2. Build might be incomplete.
And gives no more information. I did some research on Google about the error, but with no result.
Below there are some other details, that maybe can be helpful for problem resolution
OS: Windows 11
Eclipse version: 2021-09
Target board: STM32 Nucleo-F401RE
GNU Embedded toolchain version: 10.3 2021-10
I don’t use Eclipse anymore but as I remember there was a bug in the exporter. Open the Makefile for editing and proceed to the line 1938. Most likely you will find there an invalid (garbage) path to a source file which should be easy to fix manually.
I was able to install Mbed Studio, and build the blinky baremetal example, and run it on the MAX32620FTHR (using the MAX32625PICO board to load it). The Mbed OS version appears to be 6.something, but I’m not really sure how to find the minor rev. I was even able to able to make some minor mods in the main.cpp file and successfully run them.
Now, I would like to migrate the whole project over to Eclipse 2022-09.
That appears to be about 2 orders of magnitude harder than I thought it would be. There does not appear to be any way to export the project from Mbed Studio to Eclipse. Or, for that matter, to VS Code. But I need to go with Eclipse, because it has some things that I want to use in the final project – AND, we will be using a custom board, not the MAX32620FTHR, so I need a bit more information on how the project should be constructed.
I’m using MacOS Monterey (not my choice, but programmers rarely get to choose that sort of thing).
Where can I go to get the information I need to build the blinky baremetal project (with mbed os 6) in Eclipse? I’d settle for VS Code, but prefer Eclipse.
Mbed OS Community Edition has native VS Code (and CLion) support, including automatic generation of debug configurations! See here for a guide on how to create a project and get started.