summaryrefslogtreecommitdiff
path: root/Rules.mak
diff options
context:
space:
mode:
Diffstat (limited to 'Rules.mak')
-rw-r--r--Rules.mak7
1 files changed, 3 insertions, 4 deletions
diff --git a/Rules.mak b/Rules.mak
index 70c49bd60..46e480801 100644
--- a/Rules.mak
+++ b/Rules.mak
@@ -152,6 +152,9 @@ endif
# Add a bunch of extra pedantic annoyingly strict checks
WARNINGS+=-Wstrict-prototypes -Wno-trigraphs -fno-strict-aliasing
+# Some nice CFLAGS to work with
+CFLAGS:=$(WARNINGS) $(OPTIMIZATION) -fno-builtin -nostdinc $(CPUFLAGS) \
+ -D_LIBC $(CPU_CFLAGS-y) $(ARCH_CFLAGS) -I$(TOPDIR)include -I.
ifeq ($(DODEBUG),y)
CFLAGS += -g
@@ -162,10 +165,6 @@ else
LDFLAGS := $(CPU_LDFLAGS-y) -s -shared --warn-common --warn-once -z combreloc
endif
-# Some nice CFLAGS to work with
-CFLAGS:=$(WARNINGS) $(OPTIMIZATION) -fno-builtin -nostdinc $(CPUFLAGS) \
- -D_LIBC $(CPU_CFLAGS-y) $(ARCH_CFLAGS) -I$(TOPDIR)include -I.
-
# Sigh, some stupid versions of gcc can't seem to cope with '-iwithprefix include'
#CFLAGS+=-iwithprefix include
CFLAGS+=$(shell $(CC) -print-search-dirs | sed -ne "s/install: *\(.*\)/-I\1include/gp")