xref: /optee_os/core/arch/riscv/riscv.mk (revision 8e17e072793b1d3c3a89eb7c43ce8288a17ba945)
17f43e5c3SMarouene Boubakri# Setup compiler for the core module
27f43e5c3SMarouene Boubakriifeq ($(CFG_RV64_core),y)
37f43e5c3SMarouene Boubakriarch-bits-core := 64
47f43e5c3SMarouene Boubakrielse
57f43e5c3SMarouene Boubakriarch-bits-core := 32
67f43e5c3SMarouene Boubakriendif
77f43e5c3SMarouene BoubakriCROSS_COMPILE_core := $(CROSS_COMPILE$(arch-bits-core))
87f43e5c3SMarouene BoubakriCOMPILER_core := $(COMPILER)
97f43e5c3SMarouene Boubakri
107f43e5c3SMarouene Boubakriinclude mk/$(COMPILER_core).mk
117f43e5c3SMarouene Boubakri
127f43e5c3SMarouene Boubakri# Defines the cc-option macro using the compiler set for the core module
137f43e5c3SMarouene Boubakriinclude mk/cc-option.mk
147f43e5c3SMarouene Boubakri
157f43e5c3SMarouene BoubakriCFG_MMAP_REGIONS ?= 13
167f43e5c3SMarouene BoubakriCFG_RESERVED_VASPACE_SIZE ?= (1024 * 1024 * 10)
1796f43358SJens WiklanderCFG_NEX_DYN_VASPACE_SIZE ?= (1024 * 1024)
1896f43358SJens WiklanderCFG_TEE_DYN_VASPACE_SIZE ?= (1024 * 1024)
197f43e5c3SMarouene Boubakri
207f43e5c3SMarouene Boubakriifeq ($(CFG_RV64_core),y)
217f43e5c3SMarouene BoubakriCFG_KERN_LINKER_FORMAT ?= elf64-littleriscv
227f43e5c3SMarouene BoubakriCFG_KERN_LINKER_ARCH ?= riscv
237f43e5c3SMarouene Boubakrielse
247f43e5c3SMarouene Boubakriifeq ($(CFG_RV32_core),y)
257f43e5c3SMarouene BoubakriCFG_KERN_LINKER_FORMAT ?= elf32-littleriscv
267f43e5c3SMarouene BoubakriCFG_KERN_LINKER_ARCH ?= riscv
277f43e5c3SMarouene Boubakrielse
287f43e5c3SMarouene Boubakri$(error Error: CFG_RV64_core or CFG_RV32_core should be defined)
297f43e5c3SMarouene Boubakriendif
307f43e5c3SMarouene Boubakriendif
317f43e5c3SMarouene Boubakri
327f43e5c3SMarouene BoubakriCFG_CORE_RWDATA_NOEXEC ?= y
337f43e5c3SMarouene BoubakriCFG_CORE_RODATA_NOEXEC ?= n
347f43e5c3SMarouene Boubakriifeq ($(CFG_CORE_RODATA_NOEXEC),y)
357f43e5c3SMarouene Boubakri$(call force,CFG_CORE_RWDATA_NOEXEC,y)
367f43e5c3SMarouene Boubakriendif
377f43e5c3SMarouene Boubakri
385f7b832aSMarouene BoubakriCFG_MAX_CACHE_LINE_SHIFT ?= 6
395f7b832aSMarouene Boubakri
409d1a0f06SMarouene Boubakri# CFG_WITH_LPAE is ARM-related flag, however, it is used by core code.
419d1a0f06SMarouene Boubakri# In order to maintain the code logic, we set it when CFG_CORE_LARGE_PHYS_ADDR is set.
429d1a0f06SMarouene Boubakri# Platform configuration should accordingly set CFG_CORE_LARGE_PHYS_ADDR or not.
439d1a0f06SMarouene Boubakriifeq ($(CFG_CORE_LARGE_PHYS_ADDR),y)
449d1a0f06SMarouene Boubakri$(call force,CFG_WITH_LPAE,y)
459d1a0f06SMarouene Boubakriendif
469d1a0f06SMarouene Boubakri
4771214c12SAlvin Chang# Paged virtual-memory schemes (SvXX)
4871214c12SAlvin Chang# For RV32, the acceptable value is 32.
4971214c12SAlvin Chang# For RV64, the acceptable values are 39, 48, 57.
5071214c12SAlvin ChangCFG_RISCV_MMU_MODE ?= 39
5171214c12SAlvin Changifeq ($(CFG_RV64_core),y)
5271214c12SAlvin Chang$(call cfg-check-value,RISCV_MMU_MODE,39 48 57)
5371214c12SAlvin Changelse
5471214c12SAlvin Changifeq ($(CFG_RV32_core),y)
5571214c12SAlvin Chang$(call cfg-check-value,RISCV_MMU_MODE,32)
5671214c12SAlvin Changendif
5771214c12SAlvin Changendif
5871214c12SAlvin Chang
593cdf0b24SMarouene BoubakriCFG_RISCV_SBI	 ?= n
607c14296eSMarouene BoubakriCFG_RISCV_M_MODE ?= y
617c14296eSMarouene Boubakriifeq ($(CFG_RISCV_M_MODE),y)
627c14296eSMarouene Boubakriifeq ($(CFG_RISCV_S_MODE),y)
637c14296eSMarouene Boubakri$(error CFG_RISCV_M_MODE and CFG_RISCV_S_MODE cannot be both 'y')
647c14296eSMarouene Boubakrielse
657c14296eSMarouene Boubakri$(call force,CFG_RISCV_S_MODE,n)
663cdf0b24SMarouene Boubakri$(call force,CFG_RISCV_SBI,n)
677c14296eSMarouene Boubakriendif
687c14296eSMarouene Boubakriendif
697c14296eSMarouene Boubakriifeq ($(CFG_RISCV_S_MODE),y)
707c14296eSMarouene Boubakri$(call force,CFG_RISCV_M_MODE,n)
717c14296eSMarouene Boubakriendif
727c14296eSMarouene Boubakriifneq (y,$(call cfg-one-enabled,CFG_RISCV_M_MODE M CFG_RISCV_S_MODE))
737c14296eSMarouene Boubakri$(error Either CFG_RISCV_M_MODE or CFG_RISCV_S_MODE must be 'y')
747c14296eSMarouene Boubakriendif
757c14296eSMarouene Boubakri
769afe87e0SMarouene Boubakriifeq ($(CFG_RISCV_SBI_CONSOLE),y)
779afe87e0SMarouene Boubakri$(call force,CFG_RISCV_SBI,y)
789afe87e0SMarouene Boubakriendif
799afe87e0SMarouene Boubakri
8000eea924SMarouene Boubakriifeq ($(CFG_RISCV_SBI_MPXY),y)
8100eea924SMarouene Boubakri$(call force,CFG_RISCV_SBI,y)
8200eea924SMarouene Boubakriendif
8300eea924SMarouene Boubakri
84*8e17e072SMarouene Boubakriifeq ($(CFG_RISCV_SBI_MPXY_RPMI),y)
85*8e17e072SMarouene Boubakri$(call force,CFG_RISCV_SBI_MPXY,y)
86*8e17e072SMarouene Boubakriendif
87*8e17e072SMarouene Boubakri
88a30b4486SAlvin Chang# 'y' to let M-mode secure monitor handle the communication between OP-TEE OS
89a30b4486SAlvin Chang# and untrusted domain.
90a30b4486SAlvin ChangCFG_RISCV_WITH_M_MODE_SM ?= n
91a30b4486SAlvin Changifeq ($(CFG_RISCV_WITH_M_MODE_SM),y)
92a30b4486SAlvin Chang$(call force,CFG_RISCV_SBI,y)
93a30b4486SAlvin Changendif
94a30b4486SAlvin Chang
95d1c0af7dSMarouene Boubakri# Disable unsupported and other arch-specific flags
96d1c0af7dSMarouene Boubakri$(call force,CFG_CORE_FFA,n)
97d1c0af7dSMarouene Boubakri$(call force,CFG_SECURE_PARTITION,n)
98d1c0af7dSMarouene Boubakri$(call force,CFG_PAGED_USER_TA,n)
99d1c0af7dSMarouene Boubakri$(call force,CFG_WITH_PAGER,n)
100d1c0af7dSMarouene Boubakri$(call force,CFG_GIC,n)
101d1c0af7dSMarouene Boubakri$(call force,CFG_ARM_GICV3,n)
102d1c0af7dSMarouene Boubakri$(call force,CFG_WITH_VFP,n)
103d1c0af7dSMarouene Boubakri$(call force,CFG_WITH_STMM_SP,n)
104d1c0af7dSMarouene Boubakri$(call force,CFG_TA_BTI,n)
105d1c0af7dSMarouene Boubakri
10651b745faSEtienne Carriere# Enable generic timer
10751b745faSEtienne Carriere$(call force,CFG_CORE_HAS_GENERIC_TIMER,y)
10851b745faSEtienne Carriere
1097f43e5c3SMarouene Boubakricore-platform-cppflags	+= -I$(arch-dir)/include
1107f43e5c3SMarouene Boubakricore-platform-subdirs += \
111f303c856SMarouene Boubakri	$(addprefix $(arch-dir)/, kernel mm tee) $(platform-dir)
1127f43e5c3SMarouene Boubakri
113883402f5SYu Chien Peter Lin# Default values for "-mcmodel" compiler flag
114f65415b3SAlvin Changriscv-platform-mcmodel ?= medany
115883402f5SYu Chien Peter Lin
116883402f5SYu Chien Peter Linifeq ($(CFG_RV64_core),y)
117883402f5SYu Chien Peter LinISA_BASE = rv64ima
118883402f5SYu Chien Peter LinABI_BASE = lp64
119883402f5SYu Chien Peter Linelse
120883402f5SYu Chien Peter LinISA_BASE = rv32ima
121883402f5SYu Chien Peter LinABI_BASE = ilp32
122883402f5SYu Chien Peter Linendif
123883402f5SYu Chien Peter Linifeq ($(CFG_RISCV_FPU),y)
124883402f5SYu Chien Peter LinISA_D = fd
125883402f5SYu Chien Peter LinABI_D = d
126883402f5SYu Chien Peter Linendif
127883402f5SYu Chien Peter Linifeq ($(CFG_RISCV_ISA_C),y)
128883402f5SYu Chien Peter LinISA_C = c
129883402f5SYu Chien Peter Linendif
130883402f5SYu Chien Peter Linifeq ($(CFG_RISCV_ISA_ZBB),y)
131883402f5SYu Chien Peter LinISA_ZBB = _zbb
132883402f5SYu Chien Peter Linendif
133883402f5SYu Chien Peter Lin
134883402f5SYu Chien Peter Linriscv-isa = $(ISA_BASE)$(ISA_D)$(ISA_C)$(ISA_ZBB)_zicsr_zifencei
135883402f5SYu Chien Peter Linriscv-abi = $(ABI_BASE)$(ABI_D)
136f65415b3SAlvin Chang
13788dfa327SAlvin Changrv64-platform-cflags += -mcmodel=$(riscv-platform-mcmodel)
138883402f5SYu Chien Peter Linrv64-platform-cflags += -march=$(riscv-isa) -mabi=$(riscv-abi)
13988dfa327SAlvin Changrv64-platform-cflags += -Wno-missing-include-dirs
14088dfa327SAlvin Changrv32-platform-cflags += -mcmodel=$(riscv-platform-mcmodel)
141883402f5SYu Chien Peter Linrv32-platform-cflags += -march=$(riscv-isa) -mabi=$(riscv-abi)
1427f43e5c3SMarouene Boubakri
1437f43e5c3SMarouene Boubakrirv64-platform-cppflags += -DRV64=1 -D__LP64__=1
1447f43e5c3SMarouene Boubakrirv32-platform-cppflags += -DRV32=1 -D__ILP32__=1
1457f43e5c3SMarouene Boubakri
1467f43e5c3SMarouene Boubakriplatform-cflags-generic ?= -ffunction-sections -fdata-sections -pipe
1477c76fdcdSYu Chien Peter Linplatform-aflags-generic ?= -pipe -march=$(riscv-isa) -mabi=$(riscv-abi)
1487f43e5c3SMarouene Boubakri
1497f43e5c3SMarouene Boubakrirv64-platform-cflags-generic := -mstrict-align $(call cc-option,)
1507f43e5c3SMarouene Boubakri
1517f43e5c3SMarouene Boubakri# Optimize for size by default, usually gives good performance too
1527f43e5c3SMarouene BoubakriCFG_CC_OPT_LEVEL ?= 0
1537f43e5c3SMarouene Boubakriplatform-cflags-optimization ?= -O$(CFG_CC_OPT_LEVEL)
1547f43e5c3SMarouene Boubakri
1557f43e5c3SMarouene BoubakriCFG_DEBUG_INFO ?= y
1567f43e5c3SMarouene Boubakriifeq ($(CFG_DEBUG_INFO),y)
1577f43e5c3SMarouene Boubakriplatform-cflags-debug-info ?= -g3
1587f43e5c3SMarouene Boubakriplatform-aflags-debug-info ?= -g
1597f43e5c3SMarouene Boubakriendif
1607f43e5c3SMarouene Boubakri
1617f43e5c3SMarouene Boubakricore-platform-cflags += $(platform-cflags-optimization)
1627f43e5c3SMarouene Boubakricore-platform-cflags += $(platform-cflags-generic)
1637f43e5c3SMarouene Boubakricore-platform-cflags += $(platform-cflags-debug-info)
1647f43e5c3SMarouene Boubakri
1657f43e5c3SMarouene Boubakricore-platform-aflags += $(platform-aflags-generic)
1667f43e5c3SMarouene Boubakricore-platform-aflags += $(platform-aflags-debug-info)
1677f43e5c3SMarouene Boubakri
1687f43e5c3SMarouene Boubakriifeq ($(CFG_CORE_ASLR),y)
1697f43e5c3SMarouene Boubakricore-platform-cflags += -fpie
1707f43e5c3SMarouene Boubakriendif
1717f43e5c3SMarouene Boubakri
17227be144dSAlvin Changifeq ($(CFG_UNWIND),y)
17327be144dSAlvin Changcore-platform-cppflags += -fno-omit-frame-pointer
17427be144dSAlvin Changcore-platform-cflags += -fno-omit-frame-pointer
17527be144dSAlvin Changendif
17627be144dSAlvin Chang
1777f43e5c3SMarouene Boubakriifeq ($(CFG_RV64_core),y)
1787f43e5c3SMarouene Boubakricore-platform-cppflags += $(rv64-platform-cppflags)
1797f43e5c3SMarouene Boubakricore-platform-cflags += $(rv64-platform-cflags)
1807f43e5c3SMarouene Boubakricore-platform-cflags += $(rv64-platform-cflags-generic)
1817f43e5c3SMarouene Boubakricore-platform-cflags += $(rv64-platform-cflags-no-hard-float)
1827f43e5c3SMarouene Boubakricore-platform-aflags += $(rv64-platform-aflags)
1837f43e5c3SMarouene Boubakrielse
1847f43e5c3SMarouene Boubakricore-platform-cppflags += $(rv32-platform-cppflags)
1857f43e5c3SMarouene Boubakricore-platform-cflags += $(rv32-platform-cflags)
1867f43e5c3SMarouene Boubakricore-platform-cflags += $(rv32-platform-cflags-no-hard-float)
1877f43e5c3SMarouene Boubakriifeq ($(CFG_UNWIND),y)
1887f43e5c3SMarouene Boubakricore-platform-cflags += -funwind-tables
1897f43e5c3SMarouene Boubakriendif
1907f43e5c3SMarouene Boubakricore-platform-aflags += $(core_rv32-platform-aflags)
1917f43e5c3SMarouene Boubakricore-platform-aflags += $(rv32-platform-aflags)
1927f43e5c3SMarouene Boubakriendif
1937f43e5c3SMarouene Boubakri
1947f43e5c3SMarouene Boubakri# Provide default supported-ta-targets if not set by the platform config
1957f43e5c3SMarouene Boubakriifeq (,$(supported-ta-targets))
1967f43e5c3SMarouene Boubakrisupported-ta-targets = ta_rv32
1977f43e5c3SMarouene Boubakriifeq ($(CFG_RV64_core),y)
1987f43e5c3SMarouene Boubakrisupported-ta-targets += ta_rv64
1997f43e5c3SMarouene Boubakriendif
2007f43e5c3SMarouene Boubakriendif
2017f43e5c3SMarouene Boubakri
2027f43e5c3SMarouene Boubakrita-targets := $(if $(CFG_USER_TA_TARGETS),$(filter $(supported-ta-targets),$(CFG_USER_TA_TARGETS)),$(supported-ta-targets))
2037f43e5c3SMarouene Boubakriunsup-targets := $(filter-out $(ta-targets),$(CFG_USER_TA_TARGETS))
2047f43e5c3SMarouene Boubakriifneq (,$(unsup-targets))
2057f43e5c3SMarouene Boubakri$(error CFG_USER_TA_TARGETS contains unsupported value(s): $(unsup-targets). Valid values: $(supported-ta-targets))
2067f43e5c3SMarouene Boubakriendif
2077f43e5c3SMarouene Boubakri
2087f43e5c3SMarouene Boubakriifneq ($(filter ta_rv32,$(ta-targets)),)
2097f43e5c3SMarouene Boubakri# Variables for ta-target/sm "ta_rv32"
2107f43e5c3SMarouene BoubakriCFG_RV32_ta_rv32 := y
2117f43e5c3SMarouene Boubakriarch-bits-ta_rv32 := 32
2127f43e5c3SMarouene Boubakrita_rv32-platform-cppflags += $(rv32-platform-cppflags)
2137f43e5c3SMarouene Boubakrita_rv32-platform-cflags += $(rv32-platform-cflags)
2147f43e5c3SMarouene Boubakrita_rv32-platform-cflags += $(platform-cflags-optimization)
2157f43e5c3SMarouene Boubakrita_rv32-platform-cflags += $(platform-cflags-debug-info)
2167f43e5c3SMarouene Boubakrita_rv32-platform-cflags += -fpic
2177f43e5c3SMarouene Boubakri
2187f43e5c3SMarouene Boubakriifeq ($(CFG_UNWIND),y)
2197d6b0a05SAlvin Changta_rv32-platform-cflags += -fno-omit-frame-pointer
2207f43e5c3SMarouene Boubakrita_rv32-platform-cflags += -funwind-tables
2217f43e5c3SMarouene Boubakriendif
2227f43e5c3SMarouene Boubakrita_rv32-platform-aflags += $(platform-aflags-generic)
2237f43e5c3SMarouene Boubakrita_rv32-platform-aflags += $(platform-aflags-debug-info)
2247f43e5c3SMarouene Boubakrita_rv32-platform-aflags += $(rv32-platform-aflags)
2257f43e5c3SMarouene Boubakri
2267f43e5c3SMarouene Boubakrita_rv32-platform-cxxflags += -fpic
2277f43e5c3SMarouene Boubakrita_rv32-platform-cxxflags += $(rv32-platform-cxxflags)
2287f43e5c3SMarouene Boubakrita_rv32-platform-cxxflags += $(platform-cflags-optimization)
2297f43e5c3SMarouene Boubakrita_rv32-platform-cxxflags += $(platform-cflags-debug-info)
2307f43e5c3SMarouene Boubakri
2317f43e5c3SMarouene Boubakrita-mk-file-export-vars-ta_rv32 += CFG_RV32_ta_rv32
2327f43e5c3SMarouene Boubakrita-mk-file-export-vars-ta_rv32 += ta_rv32-platform-cppflags
2337f43e5c3SMarouene Boubakrita-mk-file-export-vars-ta_rv32 += ta_rv32-platform-cflags
2347f43e5c3SMarouene Boubakrita-mk-file-export-vars-ta_rv32 += ta_rv32-platform-aflags
2357f43e5c3SMarouene Boubakrita-mk-file-export-vars-ta_rv32 += ta_rv32-platform-cxxflags
2367f43e5c3SMarouene Boubakri
2377f43e5c3SMarouene Boubakrita-mk-file-export-add-ta_rv32 += CROSS_COMPILE ?= riscv32-unknown-linux-gnu-_nl_
2387f43e5c3SMarouene Boubakrita-mk-file-export-add-ta_rv32 += CROSS_COMPILE32 ?= $$(CROSS_COMPILE)_nl_
2397f43e5c3SMarouene Boubakrita-mk-file-export-add-ta_rv32 += CROSS_COMPILE_ta_rv32 ?= $$(CROSS_COMPILE32)_nl_
2407f43e5c3SMarouene Boubakrita-mk-file-export-add-ta_rv32 += COMPILER ?= gcc_nl_
2417f43e5c3SMarouene Boubakrita-mk-file-export-add-ta_rv32 += COMPILER_ta_rv32 ?= $$(COMPILER)_nl_
2427f43e5c3SMarouene Boubakrita-mk-file-export-add-ta_rv32 += PYTHON3 ?= python3_nl_
2437f43e5c3SMarouene Boubakriendif
2447f43e5c3SMarouene Boubakri
2457f43e5c3SMarouene Boubakriifneq ($(filter ta_rv64,$(ta-targets)),)
2467f43e5c3SMarouene Boubakri# Variables for ta-target/sm "ta_rv64"
2477f43e5c3SMarouene BoubakriCFG_RV64_ta_rv64 := y
2487f43e5c3SMarouene Boubakriarch-bits-ta_rv64 := 64
2497f43e5c3SMarouene Boubakrita_rv64-platform-cppflags += $(rv64-platform-cppflags)
2507f43e5c3SMarouene Boubakrita_rv64-platform-cflags += $(rv64-platform-cflags)
2517f43e5c3SMarouene Boubakrita_rv64-platform-cflags += $(platform-cflags-optimization)
2527f43e5c3SMarouene Boubakrita_rv64-platform-cflags += $(platform-cflags-debug-info)
2537f43e5c3SMarouene Boubakrita_rv64-platform-cflags += -fpic
2547f43e5c3SMarouene Boubakrita_rv64-platform-cflags += $(rv64-platform-cflags-generic)
2557d6b0a05SAlvin Changifeq ($(CFG_UNWIND),y)
2567d6b0a05SAlvin Changta_rv64-platform-cflags += -fno-omit-frame-pointer
2577d6b0a05SAlvin Changendif
2587f43e5c3SMarouene Boubakriifeq ($(rv64-platform-hard-float-enabled),y)
2597f43e5c3SMarouene Boubakrita_rv64-platform-cflags += $(rv64-platform-cflags-hard-float)
2607f43e5c3SMarouene Boubakrielse
2617f43e5c3SMarouene Boubakrita_rv64-platform-cflags += $(rv64-platform-cflags-no-hard-float)
2627f43e5c3SMarouene Boubakriendif
2637f43e5c3SMarouene Boubakrita_rv64-platform-aflags += $(platform-aflags-generic)
2647f43e5c3SMarouene Boubakrita_rv64-platform-aflags += $(platform-aflags-debug-info)
2657f43e5c3SMarouene Boubakrita_rv64-platform-aflags += $(rv64-platform-aflags)
2667f43e5c3SMarouene Boubakri
2677f43e5c3SMarouene Boubakrita_rv64-platform-cxxflags += -fpic
2687f43e5c3SMarouene Boubakrita_rv64-platform-cxxflags += $(platform-cflags-optimization)
2697f43e5c3SMarouene Boubakrita_rv64-platform-cxxflags += $(platform-cflags-debug-info)
2707f43e5c3SMarouene Boubakri
2717f43e5c3SMarouene Boubakrita-mk-file-export-vars-ta_rv64 += CFG_RV64_ta_rv64
2727f43e5c3SMarouene Boubakrita-mk-file-export-vars-ta_rv64 += ta_rv64-platform-cppflags
2737f43e5c3SMarouene Boubakrita-mk-file-export-vars-ta_rv64 += ta_rv64-platform-cflags
2747f43e5c3SMarouene Boubakrita-mk-file-export-vars-ta_rv64 += ta_rv64-platform-aflags
2757f43e5c3SMarouene Boubakrita-mk-file-export-vars-ta_rv64 += ta_rv64-platform-cxxflags
2767f43e5c3SMarouene Boubakri
2777f43e5c3SMarouene Boubakrita-mk-file-export-add-ta_rv64 += CROSS_COMPILE64 ?= $$(CROSS_COMPILE)_nl_
2787f43e5c3SMarouene Boubakrita-mk-file-export-add-ta_rv64 += CROSS_COMPILE_ta_rv64 ?= $$(CROSS_COMPILE64)_nl_
2797f43e5c3SMarouene Boubakrita-mk-file-export-add-ta_rv64 += COMPILER ?= gcc_nl_
2807f43e5c3SMarouene Boubakrita-mk-file-export-add-ta_rv64 += COMPILER_ta_rv64 ?= $$(COMPILER)_nl_
2817f43e5c3SMarouene Boubakrita-mk-file-export-add-ta_rv64 += PYTHON3 ?= python3_nl_
2827f43e5c3SMarouene Boubakriendif
2837f43e5c3SMarouene Boubakri
2847f43e5c3SMarouene Boubakri# Set cross compiler prefix for each TA target
2857f43e5c3SMarouene Boubakri$(foreach sm, $(ta-targets), $(eval CROSS_COMPILE_$(sm) ?= $(CROSS_COMPILE$(arch-bits-$(sm)))))
286