-
Notifications
You must be signed in to change notification settings - Fork 87
/
package.yml
239 lines (216 loc) · 9.67 KB
/
package.yml
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
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
name : systemd
version : '254.21'
release : 170
source :
- https://github.com/systemd/systemd-stable/archive/refs/tags/v254.21.tar.gz : f59e94af342447cc3d46148e47ab82814f2bded76ebb90f86f58d06051f1908d
license :
- LGPL-2.1-or-later
- GPL-2.0-or-later
component :
- system.base
- devel : system.devel
homepage : https://www.github.com/systemd/systemd
summary : System and Service Manager
description: |
systemd is a system and service manager for Linux, compatible with SysV and LSB init scripts. systemd provides aggressive parallelization capabilities, uses socket and D-Bus activation for starting services, offers on-demand starting of daemons, keeps track of processes using Linux control groups, supports snapshotting and restoring of the system state, maintains mount and automount points and implements an elaborate transactional dependency-based service control logic. It can work as a drop-in replacement for sysvinit.
autodep : false
emul32 : yes
libsplit : no
optimize :
- size
- lto
builddeps :
- pkgconfig32(blkid)
- pkgconfig32(bzip2)
- pkgconfig32(dbus-1)
- pkgconfig32(glib-2.0)
- pkgconfig32(gpg-error)
- pkgconfig32(libacl)
- pkgconfig32(libattr)
- pkgconfig32(libcap)
- pkgconfig32(libcurl)
- pkgconfig32(libdw)
- pkgconfig32(libgcrypt)
- pkgconfig32(liblzma)
- pkgconfig32(libssl)
- pkgconfig32(libxcrypt)
- pkgconfig32(libzstd)
- pkgconfig32(mount)
- pkgconfig32(pam)
- pkgconfig32(zlib)
- pkgconfig(audit)
- pkgconfig(libcryptsetup)
- pkgconfig(libfido2)
- pkgconfig(libidn2)
- pkgconfig(libkmod)
- pkgconfig(libpcre2-8)
- pkgconfig(libseccomp)
- pkgconfig(tss2-esys)
- docbook-xml
- gperf
- python-jinja
- python-pyelftools
- rsync
- sbsigntools
rundeps :
- 32bit :
- libcap2-32bit
- libgcrypt-32bit
- 32bit-devel :
- libcap2-32bit-devel
- libgcrypt-32bit-devel
- xz-32bit-devel
- zstd-32bit-devel
- devel :
- libcap2-devel
- libgcrypt-devel
- xz-devel
- zstd-devel
- font-terminus-console
- kernel-glue
- libgcrypt
setup : |
%apply_patches
if [[ ! -z "${EMUL32BUILD}" ]]; then
depends_emul32=false
else
depends_emul32=true
fi
%meson_configure --prefix=/usr \
--bindir=/usr/bin \
--sbindir=/usr/sbin \
-Dacl=true \
-Dapparmor=false \
-Daudit=$depends_emul32 \
-Dbpf-framework=false \
-Dbump-proc-sys-fs-nr-open=false \
-Dblkid=true \
-Dcreate-log-dirs=false \
-Ddefault-dnssec=no \
-Ddefault-hierarchy="unified" \
-Ddefault-kill-user-processes=false \
-Ddefault-llmnr=resolve \
-Ddefault-mdns=no \
-Ddefault-timeout-sec=30 \
-Ddefault-user-timeout-sec=30 \
-Ddns-over-tls='openssl' \
-Dhomed=false \
-Dhostnamed=$depends_emul32 \
-Dlibidn2=$depends_emul32 \
-Dinstall-sysconfdir=false \
-Dkernel-install=false \
-Dkmod=$depends_emul32 \
-Dlibcryptsetup=$depends_emul32 \
-Dlibcurl=true \
-Dlibfido2=$depends_emul32 \
-Dlink-udev-shared=false \
-Dlocaled=$depends_emul32 \
-Dman=$depends_emul32 \
-Dmachined=$depends_emul32 \
-Dmode=release \
-Dnetworkd=false \
-Dnscd=false \
-Dntp-servers='0.solus.pool.ntp.org 1.solus.pool.ntp.org 2.solus.pool.ntp.org 3.solus.pool.ntp.org' \
-Doomd=true \
-Dopenssl=true \
-Dpamlibdir=%libdir%/security \
-Dp11kit=false \
-Dpam=true \
-Dpcre2=$depends_emul32 \
-Dpolkit=true \
-Dresolve=true \
-Drootlibdir=%libdir% \
-Drootprefix=/usr \
-Dsbat-distro='solus' \
-Dsbat-distro-summary='Solus Project' \
-Dsbat-distro-pkgname='systemd' \
-Dsbat-distro-version="$version" \
-Dsbat-distro-url='https://getsol.us/' \
-Dseccomp=$depends_emul32 \
-Dselinux=false \
-Dsplit-usr=true \
-Dstatus-unit-format-default=combined \
-Dsysvinit-path="" \
-Dtimesyncd=$depends_emul32 \
-Dtpm=$depends_emul32 \
-Dtpm2=$depends_emul32 \
-Dusers-gid=100 \
-Duser-path=/usr/local/bin:/usr/local/sbin:/usr/bin:/usr/sbin \
-Duserdb=false
build : |
%ninja_build
install : |
%ninja_install
# Solus is responsible for its own glibc + PAM configuration, *not* systemd..
rm -rfv $installdir/usr/share/factory/*
# Only need to do the rest of the stuff on 64-bit build
if [[ ! -z "${EMUL32BUILD}" ]]; then
exit 0
fi
# Configure solus-specific-timeout values for units
install -Dm00644 -t $installdir/usr/lib/systemd/system.conf.d/ $pkgfiles/configs/timeouts.conf
install -Dm00644 -t $installdir/usr/lib/systemd/journald.conf.d/ $pkgfiles/configs/journald.conf
install -Dm00644 -t $installdir/usr/lib/systemd/system/service.d/ $pkgfiles/configs/10-timeout-abort.conf
# User config defaults
install -Dm00644 -t $installdir/usr/lib/systemd/user.conf.d/ $pkgfiles/configs/timeouts.conf
# Enable systemd-resolved by default
ln -sv ../systemd-resolved.service $installdir/usr/lib/systemd/system/sysinit.target.wants/systemd-resolved.service
# Enable systemd-timesyncd by default
ln -sv ../systemd-timesyncd.service $installdir/usr/lib/systemd/system/sysinit.target.wants/systemd-timesyncd.service
ln -sv systemd-timesyncd.service $installdir/usr/lib/systemd/system/dbus-org.freedesktop.timesync1.service
# Enable audit collection by default
install -dm00755 $installdir/usr/lib/systemd/system/systemd-journald.service.wants/
ln -sv ../systemd-journald-audit.socket $installdir/usr/lib/systemd/system/systemd-journald.service.wants/systemd-journald-audit.socket
ln -sv ../systemd-journald-audit.socket $installdir/usr/lib/systemd/system/sockets.target.wants/systemd-journald-audit.socket
# Enable user tmpfiles cleanup by default
install -dm00755 $installdir/usr/lib/systemd/user/timers.target.wants/
ln -sv ../systemd-tmpfiles-clean.timer $installdir/usr/lib/systemd/user/timers.target.wants/
# Enable remote-fs.target by default, allowing users to have mounts in their fstabs
ln -sv ../remote-fs.target $installdir/usr/lib/systemd/system/multi-user.target.wants/remote-fs.target
# Install compat dirs
install -dm00755 $installdir/{,usr/}lib64/udev
# Compat for old tools
ln -srv $installdir/usr/lib/systemd/systemd-udevd $installdir/usr/lib64/udev/udevd
ln -srv $installdir/usr/lib/systemd/systemd-udevd $installdir/lib64/udev/udevd
# Ensure that XDG_CONFIG_DIRS is set globally
install -Dm00755 $pkgfiles/50-xdg-config-dirs -t $installdir/usr/lib/systemd/system-environment-generators/
# We want systemd-update-helper, but not the RPM macros
rm -rv $installdir/usr/lib/rpm
# Stateless xinitrc.d path
install -Dm00755 xorg/50-systemd-user.sh -t $installdir/usr/share/defaults/etc/X11/xinit/xinitrc.d/
# Required basic support
install -m 00644 $pkgfiles/solus-base-groups.sysusers $installdir/usr/lib/sysusers.d/solus-base-groups.conf
# add fixed pam config
rm -rfv $installdir/usr/lib/pam.d
install -Dm00644 $pkgfiles/systemd-user.pam $installdir/usr/share/defaults/etc/pam.d/systemd-user
# Sign systemd-boot with our MOK key if it exists
if [[ -e $pkgfiles/secureboot-keys/MOK.key ]]; then
sbsign --key $pkgfiles/secureboot-keys/MOK.key \
--cert $pkgfiles/secureboot-keys/MOK.crt \
--output $installdir/usr/lib/systemd/boot/efi/systemd-bootx64.efi \
$installdir/usr/lib/systemd/boot/efi/systemd-bootx64.efi
install -Dm00644 $pkgfiles/secureboot-keys/MOK.cer $installdir/usr/lib/systemd/boot/solus-mok.cer
fi
# usr-merge
install -dm00755 $installdir/{sbin,bin}
ln -srv $installdir/usr/bin/udevadm $installdir/usr/sbin/udevadm
# Make sure systemd can be found
ln -srv $installdir/usr/lib/systemd/systemd $installdir/usr/bin/systemd
# Install compat links for usr-merge
for TOP in {bin,sbin}; do
pushd $installdir/usr/$TOP
for FILE in *; do
ln -srv $installdir/usr/$TOP/$FILE $installdir/$TOP/$FILE
done
popd
done
rm -rfv $installdir/usr/share/doc/
# We don't need 32-bit EFI binaries, probably
# TODO figure out if we actually don't need them. For now leave them in
# rm -v $installdir/usr/lib/systemd/boot/efi/{addonia32.efi.stub,linuxia32.efi.stub,systemd-bootia32.efi} \
# $installdir/usr/share/man/man7/linuxia32.efi.stub.7
# Stateless. Don't blindly convert any of these to recursive (-r) or force (-f)
# It's important that all additions and removals are investigated
rmdir -v $installdir/var/lib/systemd \
$installdir/var/lib \
$installdir/var