summaryrefslogtreecommitdiff
path: root/sysutils/xfce4-systemload-plugin/files/patch-panel-plugin_meson.build
blob: 71eedf89264ef43eb9005f4f5d18661debef1402 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
--- panel-plugin/meson.build.orig	2025-05-20 08:31:51 UTC
+++ panel-plugin/meson.build
@@ -15,6 +15,25 @@ plugin_sources = [
   xfce_revision_h,
 ]
 
+dependencies = [
+  glib,
+  gtk,
+  libgtop,
+  libm,
+  libxfce4panel,
+  libxfce4ui,
+  libxfce4util,
+  upower_glib,
+  xfconf,
+]
+
+target_os = host_machine.system()
+if target_os == 'freebsd'
+  kvm_lib = cc.find_library('kvm', required : true)
+
+  dependencies += [ kvm_lib ]
+endif
+
 plugin_install_subdir = 'xfce4' / 'panel' / 'plugins'
 
 plugin_lib = shared_module(
@@ -27,17 +46,7 @@ plugin_lib = shared_module(
   include_directories: [
     include_directories('..'),
   ],
-  dependencies: [
-    glib,
-    gtk,
-    libgtop,
-    libm,
-    libxfce4panel,
-    libxfce4ui,
-    libxfce4util,
-    upower_glib,
-    xfconf,
-  ],
+  dependencies: dependencies,
   install: true,
   install_dir: get_option('prefix') / get_option('libdir') / plugin_install_subdir,
 )