summaryrefslogtreecommitdiff
path: root/devel/avr-gcc-42/files/patch-bug25672
blob: 09fa118994db3934b4468bcf8365708e69137bf0 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=25672

--- Makefile.in.orig    Thu Dec 15 19:02:02 2005
+++ Makefile.in Thu Apr 27 03:58:59 2006
@@ -329,7 +329,7 @@
 # CFLAGS will be just -g.  We want to ensure that TARGET libraries
 # (which we know are built with gcc) are built with optimizations so
 # prepend -O2 when setting CFLAGS_FOR_TARGET.
-CFLAGS_FOR_TARGET = -O2 $(CFLAGS) $(SYSROOT_CFLAGS_FOR_TARGET)
+CFLAGS_FOR_TARGET = -O2 $(filter-out -march=% -mcpu=%,$(CFLAGS)) $(SYSROOT_CFLAGS_FOR_TARGET)
 SYSROOT_CFLAGS_FOR_TARGET = @SYSROOT_CFLAGS_FOR_TARGET@
 CXXFLAGS_FOR_TARGET = $(CXXFLAGS) $(SYSROOT_CFLAGS_FOR_TARGET)
 LIBCFLAGS_FOR_TARGET = $(CFLAGS_FOR_TARGET)