xref: /openbmc/u-boot/arch/arm/Makefile (revision bdde6595)
1#
2# SPDX-License-Identifier:	GPL-2.0+
3#
4
5# Machine directory name.  This list is sorted alphanumerically
6# by CONFIG_* macro name.
7machine-$(CONFIG_ARCH_AT91)		+= at91
8machine-$(CONFIG_ARCH_BCM283X)		+= bcm283x
9machine-$(CONFIG_ARCH_DAVINCI)		+= davinci
10machine-$(CONFIG_ARCH_HIGHBANK)		+= highbank
11machine-$(CONFIG_ARCH_KEYSTONE)		+= keystone
12# TODO: rename CONFIG_KIRKWOOD -> CONFIG_ARCH_KIRKWOOD
13machine-$(CONFIG_KIRKWOOD)		+= kirkwood
14# TODO: rename CONFIG_TEGRA -> CONFIG_ARCH_TEGRA
15machine-$(CONFIG_ARCH_NOMADIK)		+= nomadik
16# TODO: rename CONFIG_ORION5X -> CONFIG_ARCH_ORION5X
17machine-$(CONFIG_ORION5X)		+= orion5x
18machine-$(CONFIG_TEGRA)			+= tegra
19machine-$(CONFIG_ARCH_UNIPHIER)		+= uniphier
20machine-$(CONFIG_ARCH_VERSATILE)	+= versatile
21
22machdirs := $(patsubst %,arch/arm/mach-%/,$(machine-y))
23
24PLATFORM_CPPFLAGS += $(patsubst %,-I$(srctree)/%include,$(machdirs))
25
26libs-y += $(machdirs)
27
28head-y := arch/arm/cpu/$(CPU)/start.o
29
30ifeq ($(CONFIG_SPL_BUILD),y)
31ifneq ($(CONFIG_SPL_START_S_PATH),)
32head-y := $(CONFIG_SPL_START_S_PATH:"%"=%)/start.o
33endif
34endif
35
36libs-y += arch/arm/cpu/$(CPU)/
37libs-y += arch/arm/cpu/
38libs-y += arch/arm/lib/
39
40ifeq ($(CONFIG_SPL_BUILD),y)
41ifneq (,$(CONFIG_MX23)$(CONFIG_MX35)$(filter $(SOC), mx25 mx27 mx5 mx6 mx31 mx35))
42libs-y += arch/arm/imx-common/
43endif
44else
45ifneq (,$(filter $(SOC), mx25 mx27 mx5 mx6 mx31 mx35 mxs vf610))
46libs-y += arch/arm/imx-common/
47endif
48endif
49
50ifneq (,$(filter $(SOC), armada-xp kirkwood))
51libs-y += arch/arm/mvebu-common/
52endif
53
54# deprecated
55-include $(machdirs)/config.mk
56