diff -Nru grub2-2.02~beta3/debian/changelog grub2-2.02~beta3/debian/changelog --- grub2-2.02~beta3/debian/changelog 2017-07-05 22:23:03.000000000 +0000 +++ grub2-2.02~beta3/debian/changelog 2017-09-25 19:34:10.000000000 +0000 @@ -1,3 +1,16 @@ +grub2 (2.02~beta3-4ubuntu7~test1) artful; urgency=medium + + * debian/patches/grub-install-extra-removable.patch, + debian/patches/install_signed.patch: Simplify installing signed MokManager + and fallback binaries. Shim no longer installs them as *.signed. + * debian/control: Add Breaks: for shim (<< 13~) due to the renamed mok/fb + binaries. + * debian/patches/makedev_deprecated.patch: sys/types.h will soon no longer + export makedev, major, etc. macros. Update the relevant places to use the + sys/sysmacros.h file instead. + + -- Mathieu Trudel-Lapierre Mon, 25 Sep 2017 15:34:10 -0400 + grub2 (2.02~beta3-4ubuntu6) artful; urgency=medium * debian/patches/mount-ext4-fs-with-crypto-enabled.patch: Allow grub to diff -Nru grub2-2.02~beta3/debian/control grub2-2.02~beta3/debian/control --- grub2-2.02~beta3/debian/control 2017-04-24 19:32:03.000000000 +0000 +++ grub2-2.02~beta3/debian/control 2017-09-25 19:34:10.000000000 +0000 @@ -93,7 +93,7 @@ Depends: grub-common (= ${binary:Version}), dpkg (>= 1.15.4) | install-info, ${shlibs:Depends}, ${misc:Depends} Replaces: grub, grub-legacy, ${legacy-doc-br}, grub-common (<< 1.99-1), grub-pc (<< 2.00-4), grub-ieee1275 (<< 2.00-4), grub-efi (<< 1.99-1), grub-coreboot (<< 2.00-4), grub-linuxbios (<< 1.99-1), grub-efi-ia32 (<< 2.00-4), grub-efi-amd64 (<< 2.00-4), grub-efi-ia64 (<< 2.00-4), grub-yeeloong (<< 2.00-4) Conflicts: grub-legacy -Breaks: grub (<< 0.97-54), ${legacy-doc-br}, shim (<< 0.9+1474479173.6c180c6-0ubuntu1~) +Breaks: grub (<< 0.97-54), ${legacy-doc-br}, shim (<< 13~) Multi-Arch: foreign Description: GRand Unified Bootloader (common files for version 2) This package contains common files shared by the distinct flavours of GRUB. diff -Nru grub2-2.02~beta3/debian/patches/grub-install-extra-removable.patch grub2-2.02~beta3/debian/patches/grub-install-extra-removable.patch --- grub2-2.02~beta3/debian/patches/grub-install-extra-removable.patch 2017-04-26 19:57:52.000000000 +0000 +++ grub2-2.02~beta3/debian/patches/grub-install-extra-removable.patch 2017-09-25 19:30:12.000000000 +0000 @@ -17,8 +17,8 @@ Patch-Name: grub-install-extra-removable.patch --- - util/grub-install.c | 124 +++++++++++++++++++++++++++++++++++++++++++++++++++- - 1 file changed, 122 insertions(+), 2 deletions(-) + util/grub-install.c | 121 +++++++++++++++++++++++++++++++++++++++++++++++++++- + 1 file changed, 119 insertions(+), 2 deletions(-) Index: b/util/grub-install.c =================================================================== @@ -63,7 +63,7 @@ {0, 0, 0, 0, 0, 0} }; -@@ -835,6 +844,105 @@ fill_core_services (const char *core_ser +@@ -835,6 +844,102 @@ fill_core_services (const char *core_ser free (sysv_plist); } @@ -109,7 +109,6 @@ + char *dst = NULL; + char *cur = NULL; + char *found = NULL; -+ char *fb_signed = NULL; + char *fb_file = NULL; + char *generic_efidir = NULL; + @@ -119,7 +118,6 @@ + grub_util_error ("%s", _("efi_suffix_upper not set")); + + efi_file = xasprintf ("BOOT%s.EFI", efi_suffix_upper); -+ fb_signed = xasprintf ("fb%s.efi.signed", efi_suffix); + fb_file = xasprintf ("fb%s.efi", efi_suffix); + + /* We need to install in $base_efidir/EFI/BOOT/$efi_file, but we @@ -157,19 +155,18 @@ + free (efi_file); + + /* Now try to also install fallback */ -+ efi_file = grub_util_path_concat (2, "/usr/lib/shim/", fb_signed); ++ efi_file = grub_util_path_concat (2, "/usr/lib/shim/", fb_file); + dst = grub_util_path_concat (2, generic_efidir, fb_file); + grub_install_copy_file (efi_file, dst, 0); + free (efi_file); + free (fb_file); -+ free (fb_signed); + free (dst); +} + int main (int argc, char *argv[]) { -@@ -852,6 +960,7 @@ main (int argc, char *argv[]) +@@ -852,6 +957,7 @@ main (int argc, char *argv[]) char *relative_grubdir; char **efidir_device_names = NULL; grub_device_t efidir_grub_dev = NULL; @@ -177,7 +174,7 @@ char *efidir_grub_devname; int efidir_is_mac = 0; int is_prep = 0; -@@ -884,6 +993,9 @@ main (int argc, char *argv[]) +@@ -884,6 +990,9 @@ main (int argc, char *argv[]) bootloader_id = xstrdup ("grub"); } @@ -187,7 +184,7 @@ if (!grub_install_source_directory) { if (!target) -@@ -1093,6 +1205,8 @@ main (int argc, char *argv[]) +@@ -1093,6 +1202,8 @@ main (int argc, char *argv[]) if (!efidir_is_mac && grub_strcmp (fs->name, "fat") != 0) grub_util_error (_("%s doesn't look like an EFI partition"), efidir); @@ -196,7 +193,7 @@ /* The EFI specification requires that an EFI System Partition must contain an "EFI" subdirectory, and that OS loaders are stored in subdirectories below EFI. Vendors are expected to pick names that do -@@ -1973,9 +2087,15 @@ main (int argc, char *argv[]) +@@ -1982,9 +2093,15 @@ main (int argc, char *argv[]) fprintf (config_dst_f, "configfile $prefix/grub.cfg\n"); fclose (config_dst_f); free (config_dst); diff -Nru grub2-2.02~beta3/debian/patches/install_signed.patch grub2-2.02~beta3/debian/patches/install_signed.patch --- grub2-2.02~beta3/debian/patches/install_signed.patch 2017-04-26 20:03:20.000000000 +0000 +++ grub2-2.02~beta3/debian/patches/install_signed.patch 2017-09-25 19:24:09.000000000 +0000 @@ -15,8 +15,8 @@ Patch-Name: install_signed.patch --- - util/grub-install.c | 196 +++++++++++++++++++++++++++++++++++++++------------- - 1 file changed, 149 insertions(+), 47 deletions(-) + util/grub-install.c | 195 +++++++++++++++++++++++++++++++++++++++------------- + 1 file changed, 148 insertions(+), 47 deletions(-) Index: b/util/grub-install.c =================================================================== @@ -216,7 +216,7 @@ { char *uuid = NULL; /* generic method (used on coreboot and ata mod). */ -@@ -1870,7 +1904,75 @@ main (int argc, char *argv[]) +@@ -1870,7 +1904,74 @@ main (int argc, char *argv[]) case GRUB_INSTALL_PLATFORM_IA64_EFI: { char *dst = grub_util_path_concat (2, efidir, efi_file); @@ -224,13 +224,12 @@ + if (uefi_secure_boot) + { + char *shim_signed = NULL; -+ char *mok_signed = NULL, *mok_file = NULL; ++ char *mok_file = NULL; + char *bootcsv = NULL; + char *config_dst; + FILE *config_dst_f; + + shim_signed = xasprintf ("/usr/lib/shim/shim%s.efi.signed", efi_suffix); -+ mok_signed = xasprintf ("mm%s.efi.signed", efi_suffix); + mok_file = xasprintf ("mm%s.efi", efi_suffix); + bootcsv = xasprintf ("BOOT%s.CSV", efi_suffix_upper); + @@ -262,7 +261,7 @@ + won't be for older releases); but if we have MokManager, + make sure it gets installed. */ + mok_src = grub_util_path_concat (2, "/usr/lib/shim/", -+ mok_signed); ++ mok_file); + mok_dst = grub_util_path_concat (2, efidir, + mok_file); + grub_install_copy_file (mok_src, diff -Nru grub2-2.02~beta3/debian/patches/makedev_deprecated.patch grub2-2.02~beta3/debian/patches/makedev_deprecated.patch --- grub2-2.02~beta3/debian/patches/makedev_deprecated.patch 1970-01-01 00:00:00.000000000 +0000 +++ grub2-2.02~beta3/debian/patches/makedev_deprecated.patch 2017-09-25 19:34:10.000000000 +0000 @@ -0,0 +1,55 @@ +--- + grub-core/osdep/devmapper/getroot.c | 1 + + grub-core/osdep/devmapper/hostdisk.c | 1 + + grub-core/osdep/linux/getroot.c | 1 + + grub-core/osdep/unix/getroot.c | 1 + + 4 files changed, 4 insertions(+) + +Index: b/grub-core/osdep/devmapper/getroot.c +=================================================================== +--- a/grub-core/osdep/devmapper/getroot.c ++++ b/grub-core/osdep/devmapper/getroot.c +@@ -26,6 +26,7 @@ + + #include + #include ++#include + #include + #include + #include +Index: b/grub-core/osdep/linux/getroot.c +=================================================================== +--- a/grub-core/osdep/linux/getroot.c ++++ b/grub-core/osdep/linux/getroot.c +@@ -21,6 +21,7 @@ + + #include + #include ++#include + #include + #include + #include +Index: b/grub-core/osdep/unix/getroot.c +=================================================================== +--- a/grub-core/osdep/unix/getroot.c ++++ b/grub-core/osdep/unix/getroot.c +@@ -104,6 +104,7 @@ + #endif + + #include ++#include + #include + + #if defined(HAVE_STRUCT_STATFS_F_FSTYPENAME) && defined(HAVE_STRUCT_STATFS_F_MNTFROMNAME) +Index: b/grub-core/osdep/devmapper/hostdisk.c +=================================================================== +--- a/grub-core/osdep/devmapper/hostdisk.c ++++ b/grub-core/osdep/devmapper/hostdisk.c +@@ -19,6 +19,7 @@ + #include + #include + #include ++#include + #include + #include + #include diff -Nru grub2-2.02~beta3/debian/patches/series grub2-2.02~beta3/debian/patches/series --- grub2-2.02~beta3/debian/patches/series 2017-07-05 18:42:37.000000000 +0000 +++ grub2-2.02~beta3/debian/patches/series 2017-09-25 19:34:10.000000000 +0000 @@ -65,3 +65,4 @@ efinet_set_dns_from_uefi_proto.patch support_initrd-less_boot.patch mount-ext4-fs-with-crypto-enabled.patch +makedev_deprecated.patch