1include $(src)/Makefile.libfdt 2 3SECTIONS := text data $(SPECIAL_DATA_SECTIONS) 4 5# For CONFIG_OVERLAY_DTB, libfdt functionalities will be needed during runtime. 6ifneq ($(CONFIG_OVERLAY_DTB),y) 7OBJCOPYFLAGS := $(foreach s,$(SECTIONS),--rename-section .$(s)=.init.$(s)) 8nocov-y += libfdt.o 9endif 10 11obj-y += libfdt.o 12 13CFLAGS-y += -I$(srctree)/include/xen/libfdt/ 14 15$(obj)/libfdt.o: $(obj)/libfdt-temp.o FORCE 16 $(call if_changed,objcopy) 17 18$(obj)/libfdt-temp.o: $(addprefix $(obj)/,$(LIBFDT_OBJS)) FORCE 19 $(call if_changed,ld) 20 21targets += libfdt-temp.o $(LIBFDT_OBJS) 22