aboutsummaryrefslogtreecommitdiffstats
path: root/arch/x86/boot/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'arch/x86/boot/Makefile')
-rw-r--r--arch/x86/boot/Makefile14
1 files changed, 14 insertions, 0 deletions
diff --git a/arch/x86/boot/Makefile b/arch/x86/boot/Makefile
index f88458e83ef0..9695affeb584 100644
--- a/arch/x86/boot/Makefile
+++ b/arch/x86/boot/Makefile
@@ -94,6 +94,20 @@ $(obj)/vmlinux.bin: $(obj)/compressed/vmlinux FORCE
94 94
95SETUP_OBJS = $(addprefix $(obj)/,$(setup-y)) 95SETUP_OBJS = $(addprefix $(obj)/,$(setup-y))
96 96
97sed-offsets := -e 's/^00*/0/' \
98 -e 's/^\([0-9a-fA-F]*\) . \(input_data\|input_data_end\)$$/\#define \2 0x\1/p'
99
100quiet_cmd_offsets = OFFSETS $@
101 cmd_offsets = $(NM) $< | sed -n $(sed-offsets) > $@
102
103$(obj)/offsets.h: $(obj)/compressed/vmlinux FORCE
104 $(call if_changed,offsets)
105
106targets += offsets.h
107
108AFLAGS_header.o += -I$(obj)
109$(obj)/header.o: $(obj)/offsets.h
110
97LDFLAGS_setup.elf := -T 111LDFLAGS_setup.elf := -T
98$(obj)/setup.elf: $(src)/setup.ld $(SETUP_OBJS) FORCE 112$(obj)/setup.elf: $(src)/setup.ld $(SETUP_OBJS) FORCE
99 $(call if_changed,ld) 113 $(call if_changed,ld)