]> git.proxmox.com Git - efi-boot-shim.git/blob - debian/rules
debian/rules, debian/shim.install: make sure the 'make install' step does what it...
[efi-boot-shim.git] / debian / rules
1 #!/usr/bin/make -f
2
3 # Other vendors, add your certs here. No sense in using
4 # dpkg-vendor --derives-from, because only Canonical-generated binaries will
5 # be signed with this key; so if you are building your own shim binary you
6 # should be building the other binaries also.
7 ifeq ($(shell dpkg-vendor --is ubuntu && echo yes),yes)
8 cert=debian/canonical-uefi-ca.der
9 distributor=ubuntu
10 else
11 cert=debian/debian-uefi-ca.der
12 distributor=debian
13 endif
14
15 ifeq ($(DEB_HOST_ARCH),amd64)
16 export EFI_ARCH := x64
17 endif
18
19 COMMON_OPTIONS = \
20 MAKELEVEL=0 \
21 EFI_PATH=/usr/lib \
22 ENABLE_SHIM_CERT=1 \
23 ENABLE_SBSIGN=1 \
24 VENDOR_CERT_FILE=$(cert) \
25 EFIDIR=$(distributor) \
26 $(NULL)
27
28 %:
29 dh $@ --parallel
30
31 override_dh_auto_clean:
32 dh_auto_clean -- MAKELEVEL=0
33 rm -f *.signed
34
35 override_dh_auto_build:
36 dh_auto_build -- $(COMMON_OPTIONS)
37
38 override_dh_auto_install:
39 dh_auto_install --destdir=debian/tmp -- $(COMMON_OPTIONS)
40
41 override_dh_fixperms:
42 dh_fixperms
43 chmod a-x debian/shim/usr/lib/shim/shim$(EFI_ARCH).efi