From af025ea9a7cb01de115221b999a361b9565696af Mon Sep 17 00:00:00 2001 From: Marcel Moolenaar Date: Wed, 26 Sep 2007 01:31:28 +0000 Subject: [PATCH] Force -O1 compilation when targeted for ia64. GCC 4 generates bad code at -O2. Since this is likely caused by the low-level optimizer, testing TARGET_ARCH rather than MACHINE_ARCH should handle ia64 cross-compilation as well. With this work-around in place, we can release using the current GCC and Binutils code at the default optimization level on ia64. Approved by: re (kensmith) --- gnu/usr.bin/binutils/ld/Makefile | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/gnu/usr.bin/binutils/ld/Makefile b/gnu/usr.bin/binutils/ld/Makefile index 66e8e2ab9035..777482277435 100644 --- a/gnu/usr.bin/binutils/ld/Makefile +++ b/gnu/usr.bin/binutils/ld/Makefile @@ -4,6 +4,10 @@ .PATH: ${SRCDIR}/ld +.if ${TARGET_ARCH} == "ia64" +CFLAGS+= -O1 +.endif + PROG= ld SCRIPTDIR= /usr/libdata/ldscripts SRCS+= ldcref.c ldctor.c ldemul.c ldemul-list.h ldexp.c ldfile.c \