From 130c2d6373ccb1cfecd80f37cb8bfcf8b835e46b Mon Sep 17 00:00:00 2001 From: Philip Withnall Date: Tue, 17 Oct 2023 15:04:19 +0100 Subject: [PATCH] build: Fix -Dlibelf=disabled on Linux Commit f6c40b1d fixed libelf detection on FreeBSD (where the library has no pkg-config file and needs to be found via `find_library()`), but broke `-Dlibelf=disabled` on Linux, as `get_option('libelf')` was no longer checked. Signed-off-by: Philip Withnall Fixes: #3120 --- gio/meson.build | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gio/meson.build b/gio/meson.build index 9239e3caa..f9fdf6ead 100644 --- a/gio/meson.build +++ b/gio/meson.build @@ -935,7 +935,7 @@ endif # Dependencies used by executables below have_libelf = false libelf = dependency('libelf', version : '>= 0.8.12', required : false) -if libelf.found() +if libelf.found() and get_option('libelf').allowed() have_libelf = true else # This fallback is necessary on *BSD. elfutils isn't the only libelf