From 07f3fe702b6e426a1e5019179e5c94c4dc6825c6 Mon Sep 17 00:00:00 2001 From: Mario Limonciello Date: Thu, 14 May 2020 15:55:26 -0500 Subject: [PATCH] trivial: if not specified try to use some better dbx defaults --- meson.build | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/meson.build b/meson.build index 7106de70b..766bf8776 100644 --- a/meson.build +++ b/meson.build @@ -289,11 +289,16 @@ if build_standalone and get_option('plugin_uefi') efi_app_location = join_paths(libexecdir, 'fwupd', 'efi') conf.set_quoted ('EFI_APP_LOCATION', efi_app_location) - # e.g. could be: - # * /usr/share/dbxtool for Red Hat - # * /usr/share/secureboot/updates/dbx for Ubuntu efi_dbxdir = get_option('efi_dbxdir') + if efi_dbxdir == '' + foreach dir : ['/usr/share/secureboot/updates/dbx', '/usr/share/dbxtool'] + if run_command('[', '-d', dir, ']').returncode() == 0 + efi_dbxdir = dir + endif + endforeach + endif if efi_dbxdir != '' + message('efi-dbxdir: "@0@"'.format(efi_dbxdir)) conf.set_quoted ('FWUPD_EFI_DBXDIR', efi_dbxdir) endif