After following the instructions here, http://elinux.org/RPi_U-Boot, for setting up U-Boot, I am getting the following error when running the command make -j8 -s

cc1: error: bad value (armv5) for -march= switch

Makefile:912: recipe for target 'u-boot.cfg' failed

I have searched around on google, but I have not been able to find much about this. Any suggestions to what the problem is or what I am missed/am doing wrong?

2 Answers 2


This simply came as the CROSS_COMPILE variable was not set...

  • can you be more verbose so this answer can also help the others?
    – Jakuje
    Nov 30, 2015 at 17:55

As the linked guide notes, you must first

export CROSS_COMPILE=the-prefix-of-the-arm-cross-toolchain-installed-

and then run make because as you're building (most likely) software for another architecture 'gcc' will not accept the various flags that we pass in when building.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.