diff options
| author | Peter Jones <pjones@redhat.com> | 2019-11-22 15:14:22 -0500 |
|---|---|---|
| committer | Javier Martinez Canillas <javier@dowhile0.org> | 2021-02-16 09:12:48 +0100 |
| commit | 9b0c281db4ca94ef4299911bd966eac8f75877f2 (patch) | |
| tree | 586793f6035d835c043a9d0b16ba2323e8d82198 | |
| parent | a6c726fc81e53fff07942d0d50a7d274bedb4cb6 (diff) | |
| download | efi-boot-shim-9b0c281db4ca94ef4299911bd966eac8f75877f2.tar.gz efi-boot-shim-9b0c281db4ca94ef4299911bd966eac8f75877f2.zip | |
Make httpboot.c always get built.
This is a backport from devel of:
commit 634fd72ac6a6c6c9010c32506d524586826a8637
Author: Peter Jones <pjones@redhat.com>
Date: Fri Nov 22 15:14:22 2019 -0500
Make httpboot.c always get built.
Signed-off-by: Peter Jones <pjones@redhat.com>
| -rw-r--r-- | .github/workflows/pullrequest.yml | 4 | ||||
| -rw-r--r-- | .github/workflows/push.yml | 16 | ||||
| -rw-r--r-- | BUILDING | 2 | ||||
| -rw-r--r-- | Make.defaults | 4 | ||||
| -rw-r--r-- | Makefile | 9 | ||||
| -rw-r--r-- | shim.c | 2 |
6 files changed, 12 insertions, 25 deletions
diff --git a/.github/workflows/pullrequest.yml b/.github/workflows/pullrequest.yml index 3f68cbbf..2821b2f4 100644 --- a/.github/workflows/pullrequest.yml +++ b/.github/workflows/pullrequest.yml @@ -56,8 +56,8 @@ jobs: - name: Do the build on ${{ matrix.distro }} for ${{ matrix.efiarch }} id: build run: | - make -s ARCH=${{ matrix.makearch }} PREFIX=/usr LIBDIR=${{ matrix.libdir }} DESTDIR=/destdir EFIDIR=test ENABLE_HTTPBOOT=true ENABLE_SHIM_HASH=true clean all - make -s ARCH=${{ matrix.makearch }} PREFIX=/usr LIBDIR=${{ matrix.libdir }} DESTDIR=/destdir EFIDIR=test ENABLE_HTTPBOOT=true ENABLE_SHIM_HASH=true install + make -s ARCH=${{ matrix.makearch }} PREFIX=/usr LIBDIR=${{ matrix.libdir }} DESTDIR=/destdir EFIDIR=test ENABLE_SHIM_HASH=true clean all + make -s ARCH=${{ matrix.makearch }} PREFIX=/usr LIBDIR=${{ matrix.libdir }} DESTDIR=/destdir EFIDIR=test ENABLE_SHIM_HASH=true install echo 'results:' find /destdir -type f # - name: Archive production artifacts diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index d3ebbbf8..f4e59355 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -16,10 +16,10 @@ jobs: - name: Checkout uses: actions/checkout@v2 - name: Do the build - run: make PREFIX=/usr LIBDIR=/usr/lib64 DESTDIR=/destdir EFIDIR=test ENABLE_HTTPBOOT=true ENABLE_SHIM_HASH=true clean all + run: make PREFIX=/usr LIBDIR=/usr/lib64 DESTDIR=/destdir EFIDIR=test ENABLE_SHIM_HASH=true clean all id: build - name: Install in /destdir - run: make PREFIX=/usr LIBDIR=/usr/lib64 DESTDIR=/destdir EFIDIR=test ENABLE_HTTPBOOT=true ENABLE_SHIM_HASH=true install + run: make PREFIX=/usr LIBDIR=/usr/lib64 DESTDIR=/destdir EFIDIR=test ENABLE_SHIM_HASH=true install id: install # - name: Archive production artifacts # uses: actions/upload-artifact@v2 @@ -35,10 +35,10 @@ jobs: - name: Checkout uses: actions/checkout@v2 - name: Do the build - run: make PREFIX=/usr LIBDIR=/usr/lib64 DESTDIR=/destdir EFIDIR=test ENABLE_HTTPBOOT=true ENABLE_SHIM_HASH=true clean all + run: make PREFIX=/usr LIBDIR=/usr/lib64 DESTDIR=/destdir EFIDIR=test ENABLE_SHIM_HASH=true clean all id: build - name: Install in /destdir - run: make PREFIX=/usr LIBDIR=/usr/lib64 DESTDIR=/destdir EFIDIR=test ENABLE_HTTPBOOT=true ENABLE_SHIM_HASH=true install + run: make PREFIX=/usr LIBDIR=/usr/lib64 DESTDIR=/destdir EFIDIR=test ENABLE_SHIM_HASH=true install id: install # - name: Archive production artifacts # uses: actions/upload-artifact@v2 @@ -54,10 +54,10 @@ jobs: - name: Checkout uses: actions/checkout@v2 - name: Do the build - run: make PREFIX=/usr LIBDIR=/usr/lib64 DESTDIR=/destdir EFIDIR=test ENABLE_HTTPBOOT=true ENABLE_SHIM_HASH=true clean all + run: make PREFIX=/usr LIBDIR=/usr/lib64 DESTDIR=/destdir EFIDIR=test ENABLE_SHIM_HASH=true clean all id: build - name: Install in /destdir - run: make PREFIX=/usr LIBDIR=/usr/lib64 DESTDIR=/destdir EFIDIR=test ENABLE_HTTPBOOT=true ENABLE_SHIM_HASH=true install + run: make PREFIX=/usr LIBDIR=/usr/lib64 DESTDIR=/destdir EFIDIR=test ENABLE_SHIM_HASH=true install id: install # - name: Archive production artifacts # uses: actions/upload-artifact@v2 @@ -73,10 +73,10 @@ jobs: - name: Checkout uses: actions/checkout@v2 - name: Do the build - run: make PREFIX=/usr LIBDIR=/usr/lib64 DESTDIR=/destdir EFIDIR=test ENABLE_HTTPBOOT=true ENABLE_SHIM_HASH=true clean all + run: make PREFIX=/usr LIBDIR=/usr/lib64 DESTDIR=/destdir EFIDIR=test ENABLE_SHIM_HASH=true clean all id: build - name: Install in /destdir - run: make PREFIX=/usr LIBDIR=/usr/lib64 DESTDIR=/destdir EFIDIR=test ENABLE_HTTPBOOT=true ENABLE_SHIM_HASH=true install + run: make PREFIX=/usr LIBDIR=/usr/lib64 DESTDIR=/destdir EFIDIR=test ENABLE_SHIM_HASH=true install id: install # - name: Archive production artifacts # uses: actions/upload-artifact@v2 @@ -31,8 +31,6 @@ Variables you could set to customize the build: generate keys during the build and sign MokManager and fallback with them, and the signed version will be what gets installed with the install targets -- ENABLE_HTTPBOOT - build support for http booting - DISABLE_EBS_PROTECTION On systems where a second stage bootloader is not used, and the Linux Kernel is embedded in the same EFI image as shim and booted directly diff --git a/Make.defaults b/Make.defaults index 8bfcf7e0..e58a2810 100644 --- a/Make.defaults +++ b/Make.defaults @@ -99,10 +99,6 @@ ifneq ($(origin OVERRIDE_SECURITY_POLICY), undefined) CFLAGS += -DOVERRIDE_SECURITY_POLICY endif -ifneq ($(origin ENABLE_HTTPBOOT), undefined) - CFLAGS += -DENABLE_HTTPBOOT -endif - ifneq ($(origin REQUIRE_TPM), undefined) CFLAGS += -DREQUIRE_TPM endif @@ -33,20 +33,15 @@ CFLAGS += -DENABLE_SHIM_CERT else TARGETS += $(MMNAME) $(FBNAME) endif -OBJS = shim.o mok.o netboot.o cert.o replacements.o tpm.o version.o errlog.o sbat.o sbat_data.o pe.o +OBJS = shim.o mok.o netboot.o cert.o replacements.o tpm.o version.o errlog.o sbat.o sbat_data.o pe.o httpboot.o KEYS = shim_cert.h ocsp.* ca.* shim.crt shim.csr shim.p12 shim.pem shim.key shim.cer -ORIG_SOURCES = shim.c mok.c netboot.c replacements.c tpm.c errlog.c sbat.c pe.c shim.h version.h $(wildcard include/*.h) +ORIG_SOURCES = shim.c mok.c netboot.c replacements.c tpm.c errlog.c sbat.c pe.c httpboot.c shim.h version.h $(wildcard include/*.h) MOK_OBJS = MokManager.o PasswordCrypt.o crypt_blowfish.o errlog.o sbat_data.o ORIG_MOK_SOURCES = MokManager.c PasswordCrypt.c crypt_blowfish.c shim.h $(wildcard include/*.h) FALLBACK_OBJS = fallback.o tpm.o errlog.o sbat_data.o ORIG_FALLBACK_SRCS = fallback.c SBATPATH = data/sbat.csv -ifneq ($(origin ENABLE_HTTPBOOT), undefined) - OBJS += httpboot.o - SOURCES += httpboot.c include/httpboot.h -endif - ifeq ($(SOURCE_DATE_EPOCH),) UNAME=$(shell uname -s -m -p -i -o) else @@ -1118,7 +1118,6 @@ EFI_STATUS start_image(EFI_HANDLE image_handle, CHAR16 *ImagePath) } data = sourcebuffer; datasize = sourcesize; -#if defined(ENABLE_HTTPBOOT) } else if (find_httpboot(li->DeviceHandle)) { efi_status = httpboot_fetch_buffer (image_handle, &sourcebuffer, @@ -1130,7 +1129,6 @@ EFI_STATUS start_image(EFI_HANDLE image_handle, CHAR16 *ImagePath) } data = sourcebuffer; datasize = sourcesize; -#endif } else { /* * Read the new executable off disk |
