u-boot-brain/lib/efi_selftest/Makefile
Heinrich Schuchardt 8218f7b5fc efi_selftest: test start image
This pair of tests checks the StartImage boot service.

Each test loads an EFI application into memory and starts it.
One returns by calling the Exit boot service. The other returns directly.

The tests are not built on x86_64 because the relocation code for the efi
binary cannot be created.

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Signed-off-by: Alexander Graf <agraf@suse.de>
2018-01-22 23:09:14 +01:00

60 lines
1.6 KiB
Makefile

:
# (C) Copyright 2017, Heinrich Schuchardt <xypron.glpk@gmx.de>
#
# SPDX-License-Identifier: GPL-2.0+
#
# This file only gets included with CONFIG_EFI_LOADER set, so all
# object inclusion implicitly depends on it
CFLAGS_efi_selftest_miniapp.o := $(CFLAGS_EFI) -Os -ffreestanding
CFLAGS_REMOVE_efi_selftest_miniapp.o := $(CFLAGS_NON_EFI) -Os
obj-$(CONFIG_CMD_BOOTEFI_SELFTEST) += \
efi_selftest.o \
efi_selftest_controllers.o \
efi_selftest_console.o \
efi_selftest_devicepath.o \
efi_selftest_events.o \
efi_selftest_exitbootservices.o \
efi_selftest_gop.o \
efi_selftest_manageprotocols.o \
efi_selftest_snp.o \
efi_selftest_textoutput.o \
efi_selftest_tpl.o \
efi_selftest_util.o \
efi_selftest_watchdog.o
# TODO: As of v2018.01 the relocation code for the EFI application cannot
# be built on x86_64.
ifeq ($(CONFIG_X86_64),)
ifneq ($(CONFIG_CMD_BOOTEFI_SELFTEST),)
obj-y += \
efi_selftest_startimage_exit.o \
efi_selftest_startimage_return.o
targets += \
efi_miniapp_file_image_exit.h \
efi_miniapp_file_image_return.h \
efi_selftest_miniapp_exit.efi \
efi_selftest_miniapp_return.efi
$(obj)/efi_miniapp_file_image_exit.h: $(obj)/efi_selftest_miniapp_exit.efi
$(obj)/../../tools/file2include $(obj)/efi_selftest_miniapp_exit.efi > \
$(obj)/efi_miniapp_file_image_exit.h
$(obj)/efi_miniapp_file_image_return.h: $(obj)/efi_selftest_miniapp_return.efi
$(obj)/../../tools/file2include $(obj)/efi_selftest_miniapp_return.efi > \
$(obj)/efi_miniapp_file_image_return.h
$(obj)/efi_selftest_startimage_exit.o: $(obj)/efi_miniapp_file_image_exit.h
$(obj)/efi_selftest_startimage_return.o: $(obj)/efi_miniapp_file_image_return.h
endif
endif