Ver Fonte

binutils: fix bfin build

See gcc bug for details:
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77311

Fixes:

  http://autobuild.buildroot.net/results/1e93be2fb02a3fb2731e48b0d9e54a0d4080a112/

Signed-off-by: Waldemar Brodkorb <wbx@openadk.org>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Waldemar Brodkorb há 9 anos atrás
pai
commit
f6fd59ebf0
1 ficheiros alterados com 6 adições e 0 exclusões
  1. 6 0
      package/binutils/binutils.mk

+ 6 - 0
package/binutils/binutils.mk

@@ -71,6 +71,12 @@ endif
 BINUTILS_CONF_ENV += ac_cv_prog_MAKEINFO=missing
 HOST_BINUTILS_CONF_ENV += ac_cv_prog_MAKEINFO=missing
 
+# gcc bug with Os/O2/O3, PR77311
+# error: unable to find a register to spill in class 'CCREGS'
+ifeq ($(BR2_bfin),y)
+BINUTILS_CONF_ENV += CFLAGS="$(TARGET_CFLAGS) -O1"
+endif
+
 # Install binutils after busybox to prefer full-blown utilities
 ifeq ($(BR2_PACKAGE_BUSYBOX),y)
 BINUTILS_DEPENDENCIES += busybox