blob: ca4a9e72c090a976903586934236b76471fabb0b [file] [log] [blame]
Dirk Behme7d75a102008-12-14 09:47:13 +01001#
2# (C) Copyright 2002
Detlev Zundelf1b3f2b2009-05-13 10:54:10 +02003# Gary Jennejohn, DENX Software Engineering, <garyj@denx.de>
Dirk Behme7d75a102008-12-14 09:47:13 +01004#
Wolfgang Denkd79de1d2013-07-08 09:37:19 +02005# SPDX-License-Identifier: GPL-2.0+
Dirk Behme7d75a102008-12-14 09:47:13 +01006#
Kumar Gala438eded2009-09-01 11:24:45 -05007PLATFORM_RELFLAGS += -fno-common -ffixed-r8 -msoft-float
Dirk Behme7d75a102008-12-14 09:47:13 +01008
Aneesh V5ccb4242012-03-08 07:20:20 +00009# If armv7-a is not supported by GCC fall-back to armv5, which is
10# supported by more tool-chains
11PF_CPPFLAGS_ARMV7 := $(call cc-option, -march=armv7-a, -march=armv5)
12PLATFORM_CPPFLAGS += $(PF_CPPFLAGS_ARMV7)
13
Dirk Behme7d75a102008-12-14 09:47:13 +010014# =========================================================================
15#
16# Supply options according to compiler version
17#
18# =========================================================================
Wolfgang Denk9209ed52011-11-01 20:54:02 +000019PF_RELFLAGS_SLB_AT := $(call cc-option,-mshort-load-bytes,$(call cc-option,-malignment-traps,))
20PLATFORM_RELFLAGS += $(PF_RELFLAGS_SLB_AT)
Albert ARIBAUDd6d4ec82012-10-09 09:28:15 +000021
22# SEE README.arm-unaligned-accesses
23PF_NO_UNALIGNED := $(call cc-option, -mno-unaligned-access,)
24PLATFORM_NO_UNALIGNED := $(PF_NO_UNALIGNED)
25
Stefano Babic5ba59302012-04-03 04:32:56 +000026ifneq ($(CONFIG_IMX_CONFIG),)
Benoît Thébaudeaucba1dd82013-04-11 09:35:50 +000027ifdef CONFIG_SPL
28ifdef CONFIG_SPL_BUILD
29ALL-y += $(OBJTREE)/SPL
30endif
31else
Otavio Salvador50f4b5e2013-02-11 04:33:51 +000032ALL-y += $(obj)u-boot.imx
Stefano Babic5ba59302012-04-03 04:32:56 +000033endif
Benoît Thébaudeaucba1dd82013-04-11 09:35:50 +000034endif