From c61bfdc8a34fea1c6ea97ac0fb9c99f34f980381 Mon Sep 17 00:00:00 2001 From: Matthew Garrett Date: Fri, 19 Feb 2021 13:47:10 -0800 Subject: build: Import gnu-efi as a submodule and build against it Shim is rather more friendly with EFI internals than most code, and as a result can end up making assumptions that are out of step with those made by gnu-efi. Since both projects are developed independently, and since distributions are often trying to build versions of shim against whatever version of gnu-efi they are shipping, this can result in awkward build failures. The easiest way to handle this is to use a git submodule and import a known-good version of shim directly into the build tree. Given static linking, this will also make reproducible builds easier. Plus some changes from pjones: - Fix up some more include paths - more fine grained clean rules - use our make ARCH - use an rhboot/ repo for the gnu-efi remote Signed-off-by: Matthew Garrett --- Makefile | 27 +++++++++++++++++++++++---- 1 file changed, 23 insertions(+), 4 deletions(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index 6c9083d2..c1d13947 100644 --- a/Makefile +++ b/Makefile @@ -55,6 +55,9 @@ FALLBACK_SRCS = $(foreach source,$(ORIG_FALLBACK_SRCS),$(TOPDIR)/$(source)) all: $(TARGETS) +update : + git submodule update --init --recursive + shim.crt: $(TOPDIR)/make-certs shim shim@xn--u4h.net all codesign 1.3.6.1.4.1.311.10.3.1