summaryrefslogtreecommitdiff
path: root/Rules.mak
diff options
context:
space:
mode:
authorTobias Anderberg <tobias.anderberg@axis.com>2002-12-05 17:37:44 +0000
committerTobias Anderberg <tobias.anderberg@axis.com>2002-12-05 17:37:44 +0000
commitafb1cd9b2c8cfcf305c1920b45de54b3e78da32a (patch)
tree69232888cbac7cd0f017cda4a77337a178228e48 /Rules.mak
parent3f4393ac14d334aa38db17903d091488df9faf91 (diff)
Added CPU_CFLAGS and CPU_LDFLAGS for cris.
Added additional CFLAGS for cris when compiling with PIC.
Diffstat (limited to 'Rules.mak')
-rw-r--r--Rules.mak12
1 files changed, 11 insertions, 1 deletions
diff --git a/Rules.mak b/Rules.mak
index abe7696f2..11c82e8ac 100644
--- a/Rules.mak
+++ b/Rules.mak
@@ -155,6 +155,11 @@ ifeq ($(strip $(TARGET_ARCH)),h8300)
CPU_CFLAGS-y+=-mh -mint32 -fsigned-char
endif
+ifeq ($(strip $(TARGET_ARCH)),cris)
+ CPU_LDFLAGS-$(CONFIG_CRIS):="-mcrislinux"
+ CPU_CFLAGS-$(CONFIG_CRIS):="-mlinux"
+endif
+
# Override optimization settings when debugging
ifeq ($(DODEBUG),y)
OPTIMIZATION=$(call check_gcc,-Os,-O2)
@@ -179,7 +184,6 @@ endif
#CFLAGS+=-iwithprefix include
CFLAGS+=$(shell $(CC) -print-search-dirs | sed -ne "s/install: *\(.*\)/-I\1include/gp")
-
ifneq ($(DOASSERTS),y)
CFLAGS += -DNDEBUG
endif
@@ -196,9 +200,15 @@ ifeq ($(HAVE_SHARED),y)
BUILD_DYNAMIC_LINKER:=/lib/$(notdir $(SYSTEM_LDSO))
endif
endif
+
ifeq ($(DOPIC),y)
+ifeq ($(strip $(TARGET_ARCH)),cris)
+ CFLAGS += -fpic -mlinux
+else
CFLAGS += -fPIC
endif
+endif
+
ifeq ($(UCLIBC_HAS_SOFT_FLOAT),y)
CFLAGS += $(call check_gcc,-msoft-float,)
endif