2014-02-04 08:56:14 +00:00
|
|
|
#
|
|
|
|
# Copyright (C) 2013-2014 Synopsys, Inc. All rights reserved.
|
|
|
|
#
|
|
|
|
# SPDX-License-Identifier: GPL-2.0+
|
|
|
|
#
|
|
|
|
|
2015-02-03 10:58:14 +00:00
|
|
|
ifndef CONFIG_CPU_BIG_ENDIAN
|
2014-02-04 08:56:14 +00:00
|
|
|
CONFIG_SYS_LITTLE_ENDIAN = 1
|
2015-02-03 10:58:14 +00:00
|
|
|
else
|
|
|
|
CONFIG_SYS_BIG_ENDIAN = 1
|
2014-02-04 08:56:14 +00:00
|
|
|
endif
|
|
|
|
|
|
|
|
ifdef CONFIG_SYS_LITTLE_ENDIAN
|
2015-05-13 09:49:31 +00:00
|
|
|
ARC_CROSS_COMPILE := arc-linux-
|
2015-02-03 10:58:20 +00:00
|
|
|
PLATFORM_LDFLAGS += -EL
|
|
|
|
PLATFORM_CPPFLAGS += -mlittle-endian
|
2014-02-04 08:56:14 +00:00
|
|
|
endif
|
|
|
|
|
|
|
|
ifdef CONFIG_SYS_BIG_ENDIAN
|
2015-05-13 09:49:31 +00:00
|
|
|
ARC_CROSS_COMPILE := arceb-linux-
|
2014-02-04 08:56:14 +00:00
|
|
|
PLATFORM_LDFLAGS += -EB
|
2015-02-03 10:58:20 +00:00
|
|
|
PLATFORM_CPPFLAGS += -mbig-endian
|
2014-02-04 08:56:14 +00:00
|
|
|
endif
|
|
|
|
|
2014-02-28 05:33:30 +00:00
|
|
|
ifeq ($(CROSS_COMPILE),)
|
|
|
|
CROSS_COMPILE := $(ARC_CROSS_COMPILE)
|
|
|
|
endif
|
|
|
|
|
2014-12-24 14:00:29 +00:00
|
|
|
ifdef CONFIG_ARC_MMU_VER
|
|
|
|
CONFIG_MMU = 1
|
|
|
|
endif
|
|
|
|
|
2015-02-03 10:58:19 +00:00
|
|
|
ifdef CONFIG_CPU_ARC750D
|
|
|
|
PLATFORM_CPPFLAGS += -marc700
|
|
|
|
endif
|
|
|
|
|
2015-02-03 10:58:11 +00:00
|
|
|
ifdef CONFIG_CPU_ARC770D
|
2015-02-03 10:58:19 +00:00
|
|
|
PLATFORM_CPPFLAGS += -marc700 -mlock -mswape
|
2015-02-03 10:58:11 +00:00
|
|
|
endif
|
|
|
|
|
2015-01-13 15:35:46 +00:00
|
|
|
ifdef CONFIG_CPU_ARCEM6
|
|
|
|
PLATFORM_CPPFLAGS += -marcem
|
|
|
|
endif
|
|
|
|
|
|
|
|
ifdef CONFIG_CPU_ARCHS34
|
2016-06-16 08:55:00 +00:00
|
|
|
PLATFORM_CPPFLAGS += -mcpu=archs
|
2015-01-13 15:35:46 +00:00
|
|
|
endif
|
|
|
|
|
|
|
|
ifdef CONFIG_CPU_ARCHS38
|
2016-06-16 08:55:00 +00:00
|
|
|
PLATFORM_CPPFLAGS += -mcpu=archs
|
2015-01-13 15:35:46 +00:00
|
|
|
endif
|
|
|
|
|
2014-07-30 05:08:23 +00:00
|
|
|
PLATFORM_CPPFLAGS += -ffixed-r25 -D__ARC__ -gdwarf-2
|
2014-02-04 08:56:14 +00:00
|
|
|
|
|
|
|
# Needed for relocation
|
|
|
|
LDFLAGS_FINAL += -pie
|
|
|
|
|
|
|
|
# Load address for standalone apps
|
|
|
|
CONFIG_STANDALONE_LOAD_ADDR ?= 0x82000000
|