gcc: error: unrecognized -march target: armv5

90 views Asked by At

I'm trying to compile u-boot-2017.05 (because it can boot a 32-bit ARM board. It is an out-of-tree u-boot build that can execute the ubldr to boot FreeBSD. I found it here :

https://src.fedoraproject.org/repo/pkgs/uboot-tools/u-boot-2017.05.tar.bz2/sha512/be270f9242a72b05463092a022bbabd54996762de1ff23bf7575124ac02e62f49572a4e2f6f571a5019047d40027e56e35593b5cc373c4a5a39b100c3377ba93/

It has been suggested to me by the U-Boot Xen maintainers. Infact one of them said :

Yes, it can boot a 32-bit ARM board. I'm not a FreeBSD person, but I've helped a FreeBSD user booting a 32-bit ARM box with u-boot (GoFlexHome Marvell Kirkwood 6281). The u-boot version was 2017.05. I used an out-of-tree u-boot build. This u-boot executed the ubldr to boot FreeBSD. Please see here :

https://forum.doozan.com/read.php?3,49039,82059#msg-82059

So. I tried to compile it directly on my ARM Chromebook,but it failed. And it also fails if compiled with "ARCH=arm CROSS_COMPILE=arm-linux-gnueabihf-" on my Ubuntu 23.04 x86_64 workstation :

/Chromebook/freebsd-xen/domU-freebsd/bootloaders/u-boot-2017.05# make
snow_defconfig

 HOSTCC  scripts/basic/fixdep
  HOSTCC  scripts/kconfig/conf.o
  HOSTCC  scripts/kconfig/zconf.tab.o
  HOSTLD  scripts/kconfig/conf
#
# configuration written to .config
#


/Chromebook/freebsd-xen/domU-freebsd/bootloaders/u-boot-2017.05# make

scripts/kconfig/conf  --silentoldconfig Kconfig
  CHK     include/config.h
  CFG     u-boot.cfg
  GEN     include/autoconf.mk
  GEN     include/autoconf.mk.dep
  CFG     spl/u-boot.cfg
  GEN     spl/include/autoconf.mk
  CHK     include/config/uboot.release
  CHK     include/generated/version_autogenerated.h
  UPD     include/generated/version_autogenerated.h
  CHK     include/generated/timestamp_autogenerated.h
  UPD     include/generated/timestamp_autogenerated.h
  CC      lib/asm-offsets.s
gcc: error: unrecognized -march target: armv5
gcc: note: valid arguments are: armv4 armv4t armv5t armv5te armv5tej
armv6 armv6j armv6k armv6z armv6kz armv6zk armv6t2 armv6-m armv6s-m
armv7 armv7-a armv7ve armv7-r armv7-m armv7e-m armv8-a armv8.1-a
armv8.2-a armv8.3-a armv8.4-a
armv8.5-a armv8.6-a armv8-m.base armv8-m.main armv8-r armv8.1-m.main
armv9-a iwmmxt iwmmxt2 native; did you mean ‘armv4’?
gcc: error: missing argument to ‘-march=’
make[1]: *** [Kbuild:44: lib/asm-offsets.s] Errore 1
make: *** [Makefile:1287: prepare0] Errore 2

What should I do to compile it succesfully ?

0

There are 0 answers