Debian Codegraph @

runlevels/meson.build

raw
1 runlevel_dir =get_option('sysconfdir') / 'runlevels'
2
3 sysinit = []
4 sysinit_linux = [
5 'cgroups',
6 'devfs',
7 'dmesg',
8 'sysfs']
9 if os == 'linux'
10 sysinit += sysinit_linux
11 endif
12
13 boot = [
14 'bootmisc',
15 'fsck',
16 'hostname',
17 'localmount',
18 'loopback',
19 'root',
20 'swap',
21 'sysctl']
22 boot_bsd = [
23 'hostid',
24 'newsyslog',
25 'savecore',
26 'syslogd',
27 'urandom']
28 boot_freebsd = [
29 'adjkerntz',
30 'dumpon',
31 'modules',
32 'syscons']
33 boot_linux = [
34 'binfmt',
35 'hwclock',
36 'keymaps',
37 'modules',
38 'mtab',
39 'procfs',
40 'save-keymaps',
41 'save-termencoding',
42 'seedrng',
43 'termencoding']
44 boot_netbsd = [
45 'devdb',
46 'swap-blk',
47 'tys',
48 'wscons']
49 if get_option('newnet')
50 boot += [
51 'network',
52 'staticroute']
53 endif
54 if os == 'DragonFly'
55 boot += boot_bsd
56 elif os == 'freebsd'
57 boot += boot_bsd + boot_freebsd
58 elif os == 'linux'
59 boot += boot_linux
60 elif os == 'netbsd'
61 boot += boot_bsd + boot_netbsd
62 endif
63
64 default = [
65 'local',
66 'netmount']
67
68 nonetwork=['local']
69
70 shutdown = ['savecache']
71 shutdown_linux = [
72 'killprocs',
73 'mount-ro']
74 if os == 'linux'
75 shutdown += shutdown_linux
76 endif
77
78 runlevels = {
79 'sysinit': sysinit,
80 'boot': boot,
81 'default': default,
82 'nonetwork': nonetwork,
83 'shutdown': shutdown
84 }
85
86 foreach runlevel: runlevels.keys()
87 foreach service: runlevels[runlevel]
88 install_symlink(service,
89 install_dir: runlevel_dir / runlevel,
90 pointing_to: init_d_dir / service)
91 endforeach
92 if get_option('sysvinit') == true and os == 'linux' and runlevel == 'default'
93 foreach tty : get_option('agetty')
94 install_symlink('agetty.' + tty,
95 install_dir: runlevel_dir / runlevel,
96 pointing_to: init_d_dir / 'agetty.' + tty)
97 endforeach
98 endif
99 endforeach