always := $(generic-offsets-file)
targets := lib/asm-offsets.s
-$(obj)/$(generic-offsets-file): lib/asm-offsets.s FORCE
+$(obj)/$(generic-offsets-file): $(obj)/lib/asm-offsets.s FORCE
$(call filechk,offsets,__GENERIC_ASM_OFFSETS_H__)
#####
CFLAGS_asm-offsets.o := -DDO_DEPS_ONLY
-$(obj)/$(offsets-file): arch/$(ARCH)/lib/asm-offsets.s FORCE
+$(obj)/$(offsets-file): $(obj)/arch/$(ARCH)/lib/asm-offsets.s FORCE
$(call filechk,offsets,__ASM_OFFSETS_H__)
-include include/config/auto.conf
-include $(obj)/include/autoconf.mk
+UBOOTINCLUDE := -I$(obj)/include $(UBOOTINCLUDE)
+
KBUILD_CPPFLAGS += -DCONFIG_SPL_BUILD
ifeq ($(CONFIG_TPL_BUILD),y)
KBUILD_CPPFLAGS += -DCONFIG_TPL_BUILD
targets += $(obj)/dts/dt-platdata.o
$(obj)/dts/dt-platdata.o: $(obj)/dts/dt-platdata.c \
- include/generated/dt-structs-gen.h FORCE
+ include/generated/dt-structs-gen.h prepare FORCE
$(call if_changed,plat)
PHONY += dts_dir
$(sort $(u-boot-spl-init) $(u-boot-spl-main)): $(u-boot-spl-dirs) ;
PHONY += $(u-boot-spl-dirs)
-$(u-boot-spl-dirs): $(u-boot-spl-platdata)
+$(u-boot-spl-dirs): $(u-boot-spl-platdata) prepare
$(Q)$(MAKE) $(build)=$@
+PHONY += prepare
+prepare:
+ $(Q)$(MAKE) $(build)=$(obj)/.
+
quiet_cmd_cpp_lds = LDS $@
cmd_cpp_lds = $(CPP) -Wp,-MD,$(depfile) $(cpp_flags) $(LDPPFLAGS) -ansi \
-D__ASSEMBLY__ -x assembler-with-cpp -std=c99 -P -o $@ $<