xref: /linux/arch/xtensa/boot/Makefile (revision e7d163f7666560c90b163907b9d96ec6207e0f6f)
14bedea94SChris Zankel#
24bedea94SChris Zankel# arch/xtensa/boot/Makefile
34bedea94SChris Zankel#
44bedea94SChris Zankel# This file is subject to the terms and conditions of the GNU General Public
54bedea94SChris Zankel# License.  See the file "COPYING" in the main directory of this archive
64bedea94SChris Zankel# for more details.
74bedea94SChris Zankel#
84bedea94SChris Zankel#
94bedea94SChris Zankel
104bedea94SChris Zankel
114bedea94SChris ZankelCFLAGS 		+= -fno-builtin -Iarch/$(ARCH)/boot/include
124bedea94SChris ZankelHOSTFLAGS	+= -Iarch/$(ARCH)/boot/include
134bedea94SChris Zankel
14*e7d163f7SChris ZankelBIG_ENDIAN	:= $(shell echo -e __XTENSA_EB__ | $(CC) -E - | grep -v "\#")
154bedea94SChris Zankel
164bedea94SChris Zankelexport CFLAGS
174bedea94SChris Zankelexport AFLAGS
184bedea94SChris Zankelexport BIG_ENDIAN
194bedea94SChris Zankel
20*e7d163f7SChris Zankelsubdir-y	:= lib
21*e7d163f7SChris Zankel
224bedea94SChris Zankel# Subdirs for the boot loader(s)
234bedea94SChris Zankel
244bedea94SChris Zankelbootdir-$(CONFIG_XTENSA_PLATFORM_ISS)	 += boot-elf
254bedea94SChris Zankelbootdir-$(CONFIG_XTENSA_PLATFORM_XT2000) += boot-redboot boot-elf
264bedea94SChris Zankel
274bedea94SChris Zankel
284bedea94SChris ZankelzImage zImage.initrd Image Image.initrd: $(bootdir-y)
294bedea94SChris Zankel
304bedea94SChris Zankel$(bootdir-y): $(addprefix $(obj)/,$(subdir-y)) \
314bedea94SChris Zankel	      $(addprefix $(obj)/,$(host-progs))
324bedea94SChris Zankel	$(Q)$(MAKE) $(build)=$(obj)/$@ $(MAKECMDGOALS)
334bedea94SChris Zankel
34