2 # (C) Copyright 2000-2013
3 # Wolfgang Denk, DENX Software Engineering, wd@denx.de.
5 # SPDX-License-Identifier: GPL-2.0+
7 #########################################################################
14 #########################################################################
16 # Some architecture config.mk files need to know what CPUDIR is set to,
17 # so calculate CPUDIR before including ARCH/SOC/CPU config.mk files.
18 # Check if arch/$ARCH/cpu/$CPU exists, otherwise assume arch/$ARCH/cpu contains
20 CPUDIR=arch/$(ARCH)/cpu/$(CPU)
21 ifneq ($(SRCTREE)/$(CPUDIR),$(wildcard $(SRCTREE)/$(CPUDIR)))
22 CPUDIR=arch/$(ARCH)/cpu
25 sinclude $(TOPDIR)/arch/$(ARCH)/config.mk # include architecture dependend rules
26 sinclude $(TOPDIR)/$(CPUDIR)/config.mk # include CPU specific rules
29 sinclude $(TOPDIR)/$(CPUDIR)/$(SOC)/config.mk # include SoC specific rules
33 BOARDDIR = $(VENDOR)/$(BOARD)
39 sinclude $(TOPDIR)/board/$(BOARDDIR)/config.mk # include board specific rules
42 #########################################################################
44 RELFLAGS= $(PLATFORM_RELFLAGS)
46 OBJCOPYFLAGS += --gap-fill=0xff
48 CPPFLAGS = $(RELFLAGS)
49 CPPFLAGS += -pipe $(PLATFORM_CPPFLAGS)
51 LDFLAGS += $(PLATFORM_LDFLAGS)
52 LDFLAGS_FINAL += -Bstatic