mirror of
https://github.com/xen-project/xen.git
synced 2026-10-29 10:40:03 +01:00
x86: don't build with EFI support in shim-exclusive mode
There's no need for xen.efi at all, and there's also no need for EFI support in xen.gz since the shim runs in PVH mode, i.e. without any firmware (and hence by implication also without EFI one). The slightly odd looking use of $(space) is to ensure the new ifneq() evaluates consistently between "build" and "install" invocations of make. Signed-off-by: Jan Beulich <jbeulich@suse.com> Reviewed-by: Roger Pau Monné <roger.pau@citrix.com>
This commit is contained in:
1 parent
8856a914bf
commit
de58ea464f
1 file changed
+5
-1
@@ -80,7 +80,9 @@ x86_emulate.o: x86_emulate/x86_emulate.c x86_emulate/x86_emulate.h
|
||||
|
||||
efi-y := $(shell if [ ! -r $(BASEDIR)/include/xen/compile.h -o \
|
||||
-O $(BASEDIR)/include/xen/compile.h ]; then \
|
||||
echo '$(TARGET).efi'; fi)
|
||||
echo '$(TARGET).efi'; fi) \
|
||||
$(space)
|
||||
efi-$(CONFIG_PV_SHIM_EXCLUSIVE) :=
|
||||
|
||||
ifneq ($(build_id_linker),)
|
||||
notes_phdrs = --notes
|
||||
@@ -113,11 +115,13 @@ $(TARGET): $(TARGET)-syms $(efi-y) boot/mkelf32
|
||||
{ echo "No Multiboot2 header found" >&2; false; }
|
||||
mv $(TMP) $(TARGET)
|
||||
|
||||
ifneq ($(efi-y),)
|
||||
# Check if the compiler supports the MS ABI.
|
||||
export XEN_BUILD_EFI := $(shell $(CC) $(XEN_CFLAGS) -c efi/check.c -o efi/check.o 2>/dev/null && echo y)
|
||||
# Check if the linker supports PE.
|
||||
XEN_BUILD_PE := $(if $(XEN_BUILD_EFI),$(shell $(LD) -mi386pep --subsystem=10 -o efi/check.efi efi/check.o 2>/dev/null && echo y))
|
||||
CFLAGS-$(XEN_BUILD_EFI) += -DXEN_BUILD_EFI
|
||||
endif
|
||||
|
||||
ALL_OBJS := $(BASEDIR)/arch/x86/boot/built_in.o $(BASEDIR)/arch/x86/efi/built_in.o $(ALL_OBJS)
|
||||
EFI_OBJS-$(XEN_BUILD_EFI) := efi/relocs-dummy.o
|
||||
|
||||