* Patch by Fred Klatt, 25 Jun 2004:
[oweals/u-boot.git] / config.mk
index 51ca5f0a6b32c27ffdfbc9ab7bc54e7e0736194c..218239120374bddcf46fce51e6c1657ac0406dbf 100644 (file)
--- a/config.mk
+++ b/config.mk
@@ -122,6 +122,14 @@ else
 CFLAGS := $(CPPFLAGS) -Wall -Wstrict-prototypes
 endif
 
+# avoid trigraph warnings while parsing pci.h (produced by NIOS gcc-2.9)
+# this option have to be placed behind -Wall -- that's why it is here
+ifeq ($(ARCH),nios)
+ifeq ($(findstring 2.9,$(shell $(CC) --version)),2.9)
+CFLAGS := $(CPPFLAGS) -Wall -Wno-trigraphs
+endif
+endif
+
 AFLAGS_DEBUG := -Wa,-gstabs
 AFLAGS := $(AFLAGS_DEBUG) -D__ASSEMBLY__ $(CPPFLAGS)