]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
Disable non-explicit sbatvars autodetection for cross builds.
authorJames Hilliard <james.hilliard1@gmail.com>
Sat, 10 Jul 2021 10:36:50 +0000 (04:36 -0600)
committerLuca Boccassi <luca.boccassi@gmail.com>
Sat, 10 Jul 2021 22:46:26 +0000 (23:46 +0100)
Since autodetection is unlikely to work reliably for cross builds
disable it unless explicitly enabled.

Signed-off-by: James Hilliard <james.hilliard1@gmail.com>
src/boot/efi/meson.build

index afdf739d9b7c0d190df1282aff0f13b378eb0601..62d826bec6762277658a529c32b0b2113e1bb6f5 100644 (file)
@@ -115,7 +115,7 @@ if have_gnu_efi
                             ['sbat-distro-url', 'BUG_REPORT_URL']]
                 foreach sbatvar : sbatvars
                         value = get_option(sbatvar[0])
-                        if value == '' or value == 'auto'
+                        if (value == '' and not meson.is_cross_build()) or value == 'auto'
                                 cmd = 'if [ -e /etc/os-release ]; then . /etc/os-release; else . /usr/lib/os-release; fi; echo $@0@'.format(sbatvar[1])
                                 value = run_command(sh, '-c', cmd).stdout().strip()
                                 message('@0@ (from @1@): @2@'.format(sbatvar[0], sbatvar[1], value))