We have found some common errors that users face and have listed them here to help you get started with your application as quickly as possible.

Mbed CLI issues or Error: collect2: error: ld returned 1 exit status

Purge the cache with the following command:

mbed cache purge

You probably also have a stale BUILD folder. Clean up your directory and try again:

rm -rf BUILD


Error: Prompt wrapping around line

If your terminal is wrapping your text as show here:

Error prompt wrapping around line image

In your terminal type:

export PS1='\u@\h: '

For a more minimalist type:

export PS1='> '


Error: "Requires make version 3.82 or later (current is 3.81)"

If you encounter this error, install the brew and make by typing the following code:

ruby -e "$(curl -fsSL"
brew install make

Note: On a Mac, you might have to use gmake instead of make, to run your commands.


Error: -bash: mbed: command not found

If you encounter this error, try the following fixes.

For Mac:

We recommend using the installer and running the downloaded Mbed CLI App. This app will automatically launch a shell with all the dependencies solved for you.

If installed manually, make sure to follow these instructions.

Mbed CLI chip image

Previous Next