[Concept,04/12] x86: Move 16-bit binary rules to arch/x86/Makefile
Commit Message
From: Simon Glass <simon.glass@canonical.com>
The rules for extracting u-boot-x86-start16.bin and
u-boot-x86-reset16.bin are x86-specific but live in the
top-level Makefile.
Move them to arch/x86/Makefile where they belong, dropping the
outer ifdef CONFIG_X86 guard since that file is only included
for x86 builds.
Co-developed-by: Claude Opus 4.6 <noreply@anthropic.com>
Signed-off-by: Simon Glass <simon.glass@canonical.com>
---
Makefile | 10 ----------
arch/x86/Makefile | 8 ++++++++
2 files changed, 8 insertions(+), 10 deletions(-)
@@ -1694,16 +1694,6 @@ quiet_cmd_ldr = LD $@
cmd_ldr = $(LD) $(LDFLAGS_$(@F)) \
$(filter-out FORCE,$^) -o $@
-ifdef CONFIG_X86
-OBJCOPYFLAGS_u-boot-x86-start16.bin := -O binary -j .start16
-u-boot-x86-start16.bin: u-boot FORCE
- $(call if_changed,objcopy)
-
-OBJCOPYFLAGS_u-boot-x86-reset16.bin := -O binary -j .resetvec
-u-boot-x86-reset16.bin: u-boot FORCE
- $(call if_changed,objcopy)
-
-endif # CONFIG_X86
OBJCOPYFLAGS_u-boot-app.efi := $(OBJCOPYFLAGS_EFI)
u-boot-app.efi: u-boot dts/dt.dtb FORCE
@@ -25,3 +25,11 @@ head-$(CONFIG_$(PHASE_)X86_16BIT_INIT) += arch/x86/cpu/resetvec.o
libs-y += arch/x86/cpu/
libs-y += arch/x86/lib/
+
+OBJCOPYFLAGS_u-boot-x86-start16.bin := -O binary -j .start16
+u-boot-x86-start16.bin: u-boot FORCE
+ $(call if_changed,objcopy)
+
+OBJCOPYFLAGS_u-boot-x86-reset16.bin := -O binary -j .resetvec
+u-boot-x86-reset16.bin: u-boot FORCE
+ $(call if_changed,objcopy)