[gnome-settings-daemon/wip/benzea/sysfs-backlight-switch: 39/40] meson: Fix GUdev assert on Linux



commit 4fa4d04555e3a85a2dcc10ff762640e1d47dcc20
Author: Benjamin Berg <bberg redhat com>
Date:   Thu Jan 24 15:40:48 2019 +0100

    meson: Fix GUdev assert on Linux
    
    GUdev is required to compile g-s-d on linux. Unfortunately the assertion
    would never be hit as is.

 meson.build | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
---
diff --git a/meson.build b/meson.build
index 29c9ca22..f2c8e50a 100644
--- a/meson.build
+++ b/meson.build
@@ -120,10 +120,12 @@ libgvc_dep = libgvc.get_variable('libgvc_dep')
 # GUdev integration (default enabled)
 enable_gudev = get_option('gudev')
 if enable_gudev
-  assert(enable_gudev, 'GUdev is not optional on Linux platforms')
   gudev_dep = dependency('gudev-1.0')
 endif
 config_h.set10('HAVE_GUDEV', enable_gudev)
+if host_is_linux
+  assert(enable_gudev, 'GUdev is not optional on Linux platforms')
+endif
 
 has_timerfd_create = cc.has_function('timerfd_create')
 config_h.set10('HAVE_TIMERFD', has_timerfd_create)


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]