Makefile x86 SMM: Move smm_wrap recipes
This is not used together with SMM_MODULES. Change-Id: I52621787cfa5a9e3863c150ce64f62aceb423eb4 Signed-off-by: Kyösti Mälkki <kyosti.malkki@gmail.com> Reviewed-on: http://review.coreboot.org/10014 Tested-by: build bot (Jenkins) Reviewed-by: Paul Menzel <paulepanter@users.sourceforge.net> Reviewed-by: Patrick Georgi <pgeorgi@google.com>
This commit is contained in:
parent
804c13982a
commit
e2edf71204
|
@ -34,22 +34,6 @@ smm-c-deps:=$$(OPTION_TABLE_H)
|
||||||
$(obj)/cpu/x86/smm/smm.o: $$(smm-objs) $(COMPILER_RT_smm)
|
$(obj)/cpu/x86/smm/smm.o: $$(smm-objs) $(COMPILER_RT_smm)
|
||||||
$(LD_smm) -nostdlib -r -o $@ $(COMPILER_RT_FLAGS_smm) --start-group $(smm-objs) $(COMPILER_RT_smm) --end-group
|
$(LD_smm) -nostdlib -r -o $@ $(COMPILER_RT_FLAGS_smm) --start-group $(smm-objs) $(COMPILER_RT_smm) --end-group
|
||||||
|
|
||||||
$(obj)/cpu/x86/smm/smm_wrap: $(obj)/cpu/x86/smm/smm.o $(src)/cpu/x86/smm/$(SMM_LDSCRIPT)
|
|
||||||
$(LD_smm) $(SMM_LDFLAGS) -nostdlib -nostartfiles -static -o $(obj)/cpu/x86/smm/smm.elf -T $(src)/cpu/x86/smm/$(SMM_LDSCRIPT) $(obj)/cpu/x86/smm/smm.o
|
|
||||||
$(NM_smm) -n $(obj)/cpu/x86/smm/smm.elf | sort > $(obj)/cpu/x86/smm/smm.map
|
|
||||||
$(OBJCOPY_smm) -O binary $(obj)/cpu/x86/smm/smm.elf $(obj)/cpu/x86/smm/smm
|
|
||||||
|
|
||||||
# change to the target path because objcopy will use the path name in its
|
|
||||||
# ELF symbol names.
|
|
||||||
$(obj)/cpu/x86/smm/smm_wrap.ramstage.manual: $(obj)/cpu/x86/smm/smm_wrap
|
|
||||||
@printf " OBJCOPY $(subst $(obj)/,,$(@))\n"
|
|
||||||
ifeq ($(CONFIG_ARCH_RAMSTAGE_X86_32),y)
|
|
||||||
cd $(obj)/cpu/x86/smm; $(OBJCOPY_smm) -I binary smm -O elf32-i386 -B i386 smm_wrap.ramstage.manual
|
|
||||||
else
|
|
||||||
cd $(obj)/cpu/x86/smm; $(OBJCOPY_smm) -I binary smm -O elf64-x86_64 -B x86_64 smm_wrap.ramstage.manual
|
|
||||||
endif
|
|
||||||
|
|
||||||
|
|
||||||
ifeq ($(CONFIG_SMM_MODULES),y)
|
ifeq ($(CONFIG_SMM_MODULES),y)
|
||||||
|
|
||||||
smmstub-y += smm_stub.S
|
smmstub-y += smm_stub.S
|
||||||
|
@ -97,6 +81,21 @@ endif
|
||||||
|
|
||||||
else # CONFIG_SMM_MODULES
|
else # CONFIG_SMM_MODULES
|
||||||
|
|
||||||
|
$(obj)/cpu/x86/smm/smm_wrap: $(obj)/cpu/x86/smm/smm.o $(src)/cpu/x86/smm/$(SMM_LDSCRIPT)
|
||||||
|
$(LD_smm) $(SMM_LDFLAGS) -nostdlib -nostartfiles -static -o $(obj)/cpu/x86/smm/smm.elf -T $(src)/cpu/x86/smm/$(SMM_LDSCRIPT) $(obj)/cpu/x86/smm/smm.o
|
||||||
|
$(NM_smm) -n $(obj)/cpu/x86/smm/smm.elf | sort > $(obj)/cpu/x86/smm/smm.map
|
||||||
|
$(OBJCOPY_smm) -O binary $(obj)/cpu/x86/smm/smm.elf $(obj)/cpu/x86/smm/smm
|
||||||
|
|
||||||
|
# change to the target path because objcopy will use the path name in its
|
||||||
|
# ELF symbol names.
|
||||||
|
$(obj)/cpu/x86/smm/smm_wrap.ramstage.manual: $(obj)/cpu/x86/smm/smm_wrap
|
||||||
|
@printf " OBJCOPY $(subst $(obj)/,,$(@))\n"
|
||||||
|
ifeq ($(CONFIG_ARCH_RAMSTAGE_X86_32),y)
|
||||||
|
cd $(obj)/cpu/x86/smm; $(OBJCOPY_smm) -I binary smm -O elf32-i386 -B i386 smm_wrap.ramstage.manual
|
||||||
|
else
|
||||||
|
cd $(obj)/cpu/x86/smm; $(OBJCOPY_smm) -I binary smm -O elf64-x86_64 -B x86_64 smm_wrap.ramstage.manual
|
||||||
|
endif
|
||||||
|
|
||||||
ramstage-$(CONFIG_HAVE_SMI_HANDLER) += smmrelocate.S
|
ramstage-$(CONFIG_HAVE_SMI_HANDLER) += smmrelocate.S
|
||||||
ifeq ($(CONFIG_HAVE_SMI_HANDLER),y)
|
ifeq ($(CONFIG_HAVE_SMI_HANDLER),y)
|
||||||
ramstage-srcs += $(obj)/cpu/x86/smm/smm_wrap.manual
|
ramstage-srcs += $(obj)/cpu/x86/smm/smm_wrap.manual
|
||||||
|
|
Loading…
Reference in New Issue