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
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
|
--- meson.build.orig 2024-09-16 13:28:26 UTC
+++ meson.build
@@ -48,9 +48,15 @@ endif
endif
# Dependencies
-udev_dep = dependency('udev')
-gudev_dep = dependency('gudev-1.0', version: '>= 232')
+if host_machine.system() == 'linux'
+ udev_dep = dependency('udev')
+else
+ udev_dep = declare_dependency()
+ gudev_dep = declare_dependency()
+endif
+gudev_dep = dependency('gudev-1.0', version: '>= 232', required: false)
+
# PAM
libpam_dep = cc.find_library('pam')
pam_extensions_supported = cc.has_header_symbol(
@@ -123,23 +129,29 @@ endif
have_xdmcp = false
endif
# systemd
-logind_provider = get_option('logind-provider')
-systemd_dep = dependency('systemd', required: false)
-if logind_provider == 'systemd'
- libsystemd_dep = dependency('libsystemd')
- logind_dep = libsystemd_dep
- systemd_multiseat_x = find_program('systemd-multi-seat-x',
- required: false,
- dirs: [
- systemd_dep.get_variable(pkgconfig: 'systemdutildir'),
- '/lib/systemd',
- '/usr/lib/systemd',
- ])
- systemd_x_server = systemd_multiseat_x.found()? systemd_multiseat_x.path() : '/lib/systemd/systemd-multi-seat-x'
+if host_machine.system() == 'linux'
+ logind_provider = get_option('logind-provider')
+ systemd_dep = dependency('systemd', required: false)
+ if logind_provider == 'systemd'
+ libsystemd_dep = dependency('libsystemd')
+ logind_dep = libsystemd_dep
+ systemd_multiseat_x = find_program('systemd-multi-seat-x',
+ required: false,
+ dirs: [
+ systemd_dep.get_variable(pkgconfig: 'systemdutildir'),
+ '/lib/systemd',
+ '/usr/lib/systemd',
+ ])
+ systemd_x_server = systemd_multiseat_x.found()? systemd_multiseat_x.path() : '/lib/systemd/systemd-multi-seat-x'
+ else
+ elogind_dep = dependency('libelogind')
+ logind_dep = elogind_dep
+ systemd_x_server = 'disabled'
+ endif
else
- elogind_dep = dependency('libelogind')
- logind_dep = elogind_dep
- systemd_x_server = 'disabled'
+ systemd_dep = dependency('libconsolekit')
+ logind_dep = dependency('libconsolekit')
+ systemd_x_server = '/lib/systemd/systemd-multi-seat-x'
endif
# Plymouth
plymouth_dep = dependency('ply-boot-client', required: get_option('plymouth'))
@@ -292,7 +304,10 @@ conf.set_quoted('X_PATH', x_path)
conf.set('WITH_PLYMOUTH', plymouth_dep.found())
conf.set_quoted('X_SERVER', x_bin)
conf.set_quoted('X_PATH', x_path)
-conf.set('HAVE_UDEV', gudev_dep.found())
+# Avoid build failure when libgudev is installed
+if host_machine.system() == 'linux'
+ conf.set('HAVE_UDEV', gudev_dep.found())
+endif
conf.set('HAVE_UT_UT_HOST', utmp_has_host_field)
conf.set('HAVE_UT_UT_PID', utmp_has_pid_field)
conf.set('HAVE_UT_UT_ID', utmp_has_id_field)
@@ -304,6 +319,7 @@ conf.set('ENABLE_IPV6', get_option('ipv6'))
conf.set('HAVE_UT_UT_TV', utmp_has_tv_field)
conf.set('HAVE_UT_UT_SYSLEN', utmp_has_syslen_field)
conf.set('ENABLE_IPV6', get_option('ipv6'))
+conf.set('HAVE_SIGWAITINFO', cc.has_function('sigwaitinfo'))
configure_file(output: 'config.h', configuration: conf)
# Subdirs
|