]> git.pld-linux.org Git - packages/systemd.git/blame - systemd.spec
- applied upstream
[packages/systemd.git] / systemd.spec
CommitLineData
d374e721
JR
1# TODO:
2# - remove compat-pld-var-run.tmpfiles and maybe tmpfiles-not-fatal.patch
3# after enough packages provide their own tmpfiles.d configs for
4# /var/run directories
b63d2415
ER
5# - pldize vconsole setup:
6# - http://cgit.freedesktop.org/systemd/systemd/tree/src/vconsole/vconsole-setup.c
d374e721 7#
c3037397 8# Conditional build:
6c89bbd4
ER
9%bcond_without audit # without audit support
10%bcond_without cryptsetup # without cryptsetup support
23107006 11%bcond_without pam # PAM authentication support
dadb67fe 12%bcond_without plymouth # do not install plymouth units
23107006
TP
13%bcond_without selinux # without SELinux support
14%bcond_without tcpd # libwrap (tcp_wrappers) support
9c0b975d 15
c3037397 16Summary: A System and Service Manager
ede8d3e5 17Summary(pl.UTF-8): systemd - zarządca systemu i usług dla Linuksa
18Name: systemd
d833377f
JR
19Version: 183
20Release: 0.1
ede8d3e5 21License: GPL v2+
22Group: Base
440d1d13 23Source0: http://www.freedesktop.org/software/systemd/%{name}-%{version}.tar.xz
d833377f 24# Source0-md5: e1e5e0f376fa2a4cb4bc31a2161c09f2
4f25b6ac 25Source1: %{name}-sysv-convert
b0980573 26Source2: %{name}_booted.c
a3a953ae 27Source3: network.service
a3a953ae 28Source5: compat-pld-var-run.tmpfiles
d833377f
JR
29Source6: var-lock.mount
30Source7: var-run.mount
44410185
JR
31Source10: pld-storage-init-late.service
32Source11: pld-storage-init.service
33Source12: pld-wait-storage.service
34Source13: pld-storage-init.sh
50b8f452
ER
35Source14: pld-clean-tmp.service
36Source15: pld-clean-tmp.sh
7619c097 37Patch0: target-pld.patch
252e1bad 38Patch1: config-pld.patch
8e088cd5 39Patch2: shut-sysv-up.patch
2e1f31c8 40Patch3: pld-sysv-network.patch
d374e721 41Patch4: tmpfiles-not-fatal.patch
2be4e142 42Patch5: CVE-2012-1174.patch
371abfe3 43Patch6: ReleaseSession.patch
86d92a68 44Patch7: control-subcgroup.patch
3be4738a 45Patch8: kmsg-to-syslog.patch
ede8d3e5 46URL: http://www.freedesktop.org/wiki/Software/systemd
5b9bde26 47BuildRequires: acl-devel
6c89bbd4 48%{?with_audit:BuildRequires: audit-libs-devel}
6e34428f
MB
49BuildRequires: autoconf >= 2.63
50BuildRequires: automake >= 1:1.11
e4c66821 51BuildRequires: binutils >= 3:2.22.52.0.1-2
6e34428f 52%{?with_cryptsetup:BuildRequires: cryptsetup-luks-devel}
23107006 53BuildRequires: dbus-devel >= 1.3.2
c3037397 54BuildRequires: docbook-style-xsl
3fc7a1cc 55BuildRequires: gperf
5b9bde26 56BuildRequires: intltool >= 0.40.0
4389e6f9 57BuildRequires: kmod-devel >= 5
b82d0bf2 58BuildRequires: libcap-devel
def6d132 59%{?with_selinux:BuildRequires: libselinux-devel >= 2.1.0}
6c89bbd4
ER
60BuildRequires: libtool >= 2:2.2
61%{?with_tcpd:BuildRequires: libwrap-devel}
6e34428f 62BuildRequires: libxslt-progs
961baf80 63BuildRequires: m4
6c89bbd4 64%{?with_pam:BuildRequires: pam-devel}
23107006 65BuildRequires: pkgconfig >= 0.9.0
4cc1cb1d 66BuildRequires: rpmbuild(macros) >= 1.627
58fd72e9 67BuildRequires: udev-devel >= 1:172
58fd72e9 68BuildRequires: xz-devel
011bccb6 69Requires: %{name}-libs = %{version}-%{release}
c3037397 70Requires: %{name}-units = %{version}-%{release}
58d6217a 71Requires: /etc/os-release
2ff27c26 72Requires: SysVinit-tools
37b8df82 73Requires: agetty
b0980573 74Requires: dbus >= 1.4.16-6
7cb5cfc8 75Requires: filesystem >= 4.0-2
ed5c41d4 76Requires: libutempter
a2018b66 77Requires: rc-scripts >= 0.4.5.3-7
56701781 78Requires: setup >= 2.8.0-2
b0980573 79Requires: udev-core >= 1:175-5
fe6ae5ab 80Requires: udev-libs >= 1:172
e3134fe0 81Requires: virtual(module-tools)
4e5e9c32 82Suggests: %{name}-no-compat-tmpfiles
b0980573 83Suggests: ConsoleKit
2a61be78 84Suggests: fsck >= 2.20
e3134fe0 85Suggests: kmod >= 5
4b15486a 86Suggests: nss_myhostname
c35aa49c 87Suggests: service(klogd)
1cdd35cf 88Suggests: service(syslog)
fda563d5 89Provides: udev-acl
3baeefca
PG
90# systemd takes care of that and causes problems
91Conflicts: binfmt-detector
a6203073 92# sytemd wants pam with pam_systemd.so in system-auth...
3b292a99 93Conflicts: pam < 1:1.1.5-5
a6203073
JR
94# ...and sudo hates it
95Conflicts: sudo < 1:1.7.8p2-4
06d34666
JR
96# for prefdm script
97Conflicts: xinitrc-ng < 1.0
0fedd233
JR
98# systemd scripts use options not present in older versions
99Conflicts: kpartx < 0.4.9-7
100Conflicts: multipath-tools < 0.4.9-7
d833377f
JR
101# no tmpfs on /media, use /run/media/$USER for mounting
102Conflicts: udisks2 < 1.92.0
ede8d3e5 103BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
104
85879912
ER
105%define _libexecdir %{_prefix}/lib
106
ede8d3e5 107%description
1c239f8b 108systemd is a system and service manager for Linux, compatible with
ede8d3e5 109SysV and LSB init scripts. systemd provides aggressive parallelization
110capabilities, uses socket and D-Bus activation for starting services,
111offers on-demand starting of daemons, keeps track of processes using
112Linux cgroups, supports snapshotting and restoring of the system
113state, maintains mount and automount points and implements an
114elaborate transactional dependency-based service control logic. It can
1c239f8b 115work as a drop-in replacement for sysvinit.
ede8d3e5 116
117%description -l pl.UTF-8
118systemd jest zarządcą systemu i usług dla Linuksa, kompatybilny ze
119skryptami SysV i LSB. systemd udostępnia rozbudowane zdolności
120paralelizacji, do uruchamiania usług używa socketów oraz D-Busa,
121oferuje uruchamianie usług na życzenie, monitoruje procesy używając
122linuksowych cgroups, wspomaga zapisywanie (snapshot) i odczytywanie
123(restore) stanu systemu, zarządza (auto)mount pointami oraz
124implementuje starannie opracowaną transakcjonalną, bazującą na
d45dfc3a 125zależnościach logikę kontroli usług. Może pracować jako zastępca dla
ede8d3e5 126sysvinit.
127
c97dacdd
TP
128%package init
129Summary: systemd /sbin/init and LSB/SysV compatibility symlinks
5b9bde26 130Summary(pl.UTF-8): /sbin/init z systemd i dowiązania dla kompatybilności z LSB/SysV
c97dacdd 131Group: Base
d6829efa 132Requires: systemd
c97dacdd
TP
133Provides: readahead = 1:1.5.7-3
134Provides: virtual(init-daemon)
135Obsoletes: SysVinit
136Obsoletes: readahead < 1:1.5.7-3
137Obsoletes: virtual(init-daemon)
4e1559fc 138Conflicts: upstart
c97dacdd
TP
139
140%description init
141Install this package when you are ready to final switch to systemd.
142
5b9bde26
JB
143%description init -l pl.UTF-8
144Ten pakiet należy zainstalować po przygotowaniu się do ostatecznego
145przejścia na systemd.
146
c3037397
ER
147%package units
148Summary: Configuration files, directories and installation tool for systemd
5b9bde26 149Summary(pl.UTF-8): Pliki konfiguracyjne, katalogi i narzędzie instalacyjne dla systemd
c3037397 150Group: Base
c3037397 151Requires(post): coreutils
a8d86f01 152Requires(post): /bin/awk
c3037397
ER
153
154%description units
155Basic configuration files, directories and installation tool for the
156systemd system and service manager.
157
f341cd9b 158This is common config, use %{_sysconfdir}/systemd/system to override.
10ffdcd2 159
5b9bde26
JB
160%description units -l pl.UTF-8
161Podstawowe pliki konfiguracyjne, katalogi i narzędzie instalacyjne dla
162zarządcy systemu i usług systemd.
163
164Ten pakiet zawiera ogólną konfigurację, ustawienia można nadpisać
165poprzez katalog %{_sysconfdir}/systemd/system.
166
e4c66821
JB
167%package plymouth
168Summary: Plymouth support units for systemd
169Summary(pl.UTF-8): Jednostki wspierające Plymouth dla systemd
170Group: Base
171Requires: %{name}-units = %{version}-%{release}
216f25d7 172Requires: plymouth
e4c66821
JB
173
174%description plymouth
175Plymouth (graphical boot) support units for systemd.
176
177%description plymouth -l pl.UTF-8
178Jednostki wspierające Plymouth (graficzny start systemu) dla systemd.
179
4e5e9c32
ER
180%package analyze
181Summary: Tool for processing systemd profiling information
182Group: Base
183Requires: %{name} = %{version}-%{release}
184Requires: python-dbus
185Requires: python-modules
186Requires: python-pycairo
187Conflicts: %{name} < 44-3
188
189%description analyze
190'systemd-analyze blame' lists which systemd unit needed how much time
191to finish initialization at boot. 'systemd-analyze plot' renders an
192SVG visualizing the parallel start of units at boot.
193
011bccb6 194%package libs
5b9bde26
JB
195Summary: Shared systemd libraries
196Summary(pl.UTF-8): Biblioteki współdzielone systemd
011bccb6
BZ
197Group: Libraries
198
199%description libs
5b9bde26
JB
200Shared systemd libraries.
201
202%description libs -l pl.UTF-8
203Biblioteki współdzielone systemd.
011bccb6 204
961baf80
AF
205%package devel
206Summary: Header files for systemd libraries
207Summary(pl.UTF-8): Pliki nagłówkowe bibliotek systemd
208Group: Development/Libraries
011bccb6 209Requires: %{name}-libs = %{version}-%{release}
961baf80
AF
210
211%description devel
212Header files for systemd libraries.
213
214%description devel -l pl.UTF-8
215Pliki nagłówkowe bibliotek systemd.
216
5b9bde26
JB
217%package -n bash-completion-systemd
218Summary: bash-completion for systemd
219Summary(pl.UTF-8): Bashowe dopełnianie składni dla systemd
220Group: Applications/Shells
bbd3dce1 221Requires: %{name} = %{version}
5b9bde26
JB
222Requires: bash-completion
223
224%description -n bash-completion-systemd
225bash-completion for systemd.
226
227%description -n bash-completion-systemd -l pl.UTF-8
228Bashowe dopełnianie składni dla systemd
229
ae4d0acb
JR
230%package no-compat-tmpfiles
231Summary: Force update of packages that provide tmpfiles.d configuration
232Group: Base
bbd3dce1 233Requires: %{name} = %{version}-%{release}
ae4d0acb
JR
234Requires(post): sed > 4.0
235Conflicts: ConsoleKit-dirs < 0.4.5-7
236Conflicts: NetworkManager < 2:0.9.2.0-3
237Conflicts: Zope < 2.11.8-2
238Conflicts: amavisd-new < 1:2.7.0-1
ae4d0acb
JR
239Conflicts: apache-base < 2.2.21-4
240Conflicts: apache-mod_bw < 0.92-3
241Conflicts: apache-mod_fastcgi < 2.4.6-6
b0980573
ŁK
242Conflicts: apache1-base < 1.3.42-5
243Conflicts: apache1-mod_fastcgi < 2.4.6-2
ae4d0acb
JR
244Conflicts: asterisk < 10.0.1-2
245Conflicts: autossh-init < 1.4b-3
246Conflicts: balance < 3.54-2
247Conflicts: bind < 7:9.8.1.P1-4
248Conflicts: bopm < 3.1.3-4
249Conflicts: callweaver < 1.2.1-9
250Conflicts: cassandra-bin < 0.8.9-2
251Conflicts: clamav < 0.97.3-3
252Conflicts: cups < 1:1.5.0-10
253Conflicts: dbus < 1.4.16-4
254Conflicts: dovecot < 1:2.0.16-3
255Conflicts: dspam < 3.9.0-6
256Conflicts: fail2ban < 0.8.4-4
257Conflicts: filesystem < 4.0-3
258Conflicts: gammu-smsd < 1:1.31.0-3
a6203073
JR
259# Break gdm2.20 installs
260#Conflicts: gdm < 2:3.2.1.1-9
ae4d0acb
JR
261Conflicts: greylistd < 0.8.8-2
262Conflicts: inn < 2.4.6-7
263Conflicts: ipsec-tools < 0.8.0-3
264Conflicts: jabber-common < 0-9
265Conflicts: laptop-mode-tools < 1.58-2
266Conflicts: libgpod < 0.8.0-6
267Conflicts: libvirt-utils < 0.9.9-4
268Conflicts: lighttpd < 1.4.30-5
269Conflicts: lirc < 0.9.0-20
270Conflicts: mailman < 5:2.1.14-4
271Conflicts: memcached < 1.4.11-2
272Conflicts: mpd < 0.16.5-4
273Conflicts: mrtg < 2.17.0-3
274Conflicts: munin-common < 1.4.5-5
275Conflicts: nagios-nrpe < 2.13-2
276Conflicts: ndisc6-rdnssd < 1.0.1-3
277Conflicts: nscd < 6:2.14.1-5
278Conflicts: nss_ldapd-nslcd < 0.8.4-2
279Conflicts: openct < 0.6.20-3
280Conflicts: openl2tp < 1.8-3
281Conflicts: openldap-overlay-nssov < 2.4.28-4
282Conflicts: openldap-servers < 2.4.28-4
283Conflicts: openvpn < 2.2.2-2
ae4d0acb
JR
284Conflicts: pam-pam_mount < 2.12-3
285Conflicts: pam-pam_ssh < 1.97-2
286Conflicts: pcsc-lite < 1.8.1-2
287Conflicts: php-dirs < 1.2-3
288Conflicts: policyd < 2.0.10-3
289Conflicts: pound < 2.6-2
290Conflicts: pptp < 1.7.2-3
291Conflicts: proftpd-common < 2:1.3.4a-2
292Conflicts: pulseaudio-server < 1.1-2
293Conflicts: quagga < 0.99.20-3
294Conflicts: radvd < 1.8.5-2
295Conflicts: rc-scripts < 0.4.5.2-3
296Conflicts: red5 < 0.9.0-2
297Conflicts: redis-server < 2.4.2-4
298Conflicts: smokeping < 2.4.2-10
299Conflicts: smtp-gated < 1.4.17-2
300Conflicts: socat < 1.7.2.0-2
301Conflicts: speech-dispatcher < 0.7.1-2
302Conflicts: sphinx < 2.0.3-4
303Conflicts: splashutils < 1.5.4.3-3
304Conflicts: stunnel < 4.50-2
ae4d0acb
JR
305Conflicts: tenshi < 0.12-2
306Conflicts: tor < 0.2.2.35-2
307Conflicts: ucarp < 1.5.2-3
308Conflicts: udisks < 1.0.4-3
309Conflicts: util-vserver < 0.30.216-1.pre3002.3
310Conflicts: vpnc < 0.5.3-2
311Conflicts: web2ldap < 1.1.0rc1-2
312Conflicts: wesnoth-server < 1:1.10-2
313Conflicts: wpa_supplicant < 0.7.3-10
314Conflicts: xl2tpd < 1.3.0-2
315
316%description no-compat-tmpfiles
317Force update of packages that provide tmpfiles.d configuration
318
ede8d3e5 319%prep
320%setup -q
4c5b5ab6 321%patch0 -p1
252e1bad 322%patch1 -p1
a6203073 323%patch2 -p1
942c9075 324%patch3 -p1
d374e721 325%patch4 -p1
2be4e142 326%patch5 -p1
5e027d7a 327%patch6 -p1
86d92a68 328%patch7 -p1
3be4738a 329%patch8 -p1
b77423ae 330cp -p %{SOURCE2} src/systemd_booted.c
ede8d3e5 331
332%build
4c5b5ab6 333%{__aclocal} -I m4
ede8d3e5 334%{__autoconf}
6e34428f 335%{__autoheader}
ede8d3e5 336%{__automake}
9c0b975d 337%configure \
6c89bbd4
ER
338 %{__enable_disable audit} \
339 %{__enable_disable cryptsetup libcryptsetup} \
6f8c4458 340 --disable-gtk \
6c89bbd4 341 %{__enable_disable pam} \
4389e6f9 342 %{__enable_disable plymouth} \
6c89bbd4
ER
343 %{__enable_disable selinux} \
344 %{__enable_disable tcpd tcpwrap} \
345 --disable-silent-rules \
961baf80 346 --disable-static \
5b9bde26 347 --with-distro=pld \
391eea76 348 --with-rootprefix= \
4389e6f9
JR
349 --with-rootlibdir=/%{_lib} \
350 --enable-split-usr
e1d9cc15 351
ede8d3e5 352%{__make}
b77423ae 353./libtool --mode=link --tag=CC %{__cc} %{rpmcppflags} %{rpmcflags} -o systemd_booted %{rpmldflags} src/systemd_booted.c -L. -lsystemd-daemon
ede8d3e5 354
355%install
356rm -rf $RPM_BUILD_ROOT
24f95219 357install -d $RPM_BUILD_ROOT/var/lib/%{name}/coredump
23107006 358
ede8d3e5 359%{__make} install \
360 DESTDIR=$RPM_BUILD_ROOT
361
216f25d7 362./libtool --mode=install install -p -m755 systemd_booted $RPM_BUILD_ROOT/bin/systemd_booted
b77423ae 363
4389e6f9
JR
364# Main binary has been moved, but we don't want to break existing installs
365ln -s ../lib/systemd/systemd $RPM_BUILD_ROOT/bin/systemd
366
1dcb74bb 367# Create SysV compatibility symlinks. systemctl/systemd are smart
2a61be78 368# enough to detect the way they were called
c28b0c1c 369install -d $RPM_BUILD_ROOT/sbin
4389e6f9 370ln -s ../lib/systemd/systemd $RPM_BUILD_ROOT/sbin/init
1dcb74bb 371ln -s ../bin/systemctl $RPM_BUILD_ROOT/sbin/halt
372ln -s ../bin/systemctl $RPM_BUILD_ROOT/sbin/poweroff
23107006
TP
373ln -s ../bin/systemctl $RPM_BUILD_ROOT/sbin/reboot
374ln -s ../bin/systemctl $RPM_BUILD_ROOT/sbin/runlevel
1dcb74bb 375ln -s ../bin/systemctl $RPM_BUILD_ROOT/sbin/shutdown
376ln -s ../bin/systemctl $RPM_BUILD_ROOT/sbin/telinit
1dcb74bb 377
5d32f234 378ln -s ../modules $RPM_BUILD_ROOT%{_sysconfdir}/modules-load.d/modules.conf
44410185
JR
379
380# disable redundant SYSV services
381ln -s /dev/null $RPM_BUILD_ROOT%{systemdunitdir}/allowlogin.service
4cc1cb1d 382ln -s /dev/null $RPM_BUILD_ROOT%{systemdunitdir}/console.service
44410185
JR
383ln -s /dev/null $RPM_BUILD_ROOT%{systemdunitdir}/cpusets.service
384ln -s /dev/null $RPM_BUILD_ROOT%{systemdunitdir}/killall.service
385ln -s /dev/null $RPM_BUILD_ROOT%{systemdunitdir}/netfs.service
386ln -s /dev/null $RPM_BUILD_ROOT%{systemdunitdir}/random.service
5d32f234 387
f1586299 388# add static (non-NetworkManager) networking
216f25d7 389cp -p %{SOURCE3} $RPM_BUILD_ROOT%{systemdunitdir}/network.service
f1586299 390
5c8fe698 391# install compatibility tmpfiles configs
216f25d7 392cp -p %{SOURCE5} $RPM_BUILD_ROOT%{_sysconfdir}/tmpfiles.d/compat-pld-var-run.conf
5c8fe698 393
d833377f
JR
394# restore bind-mounts /var/run -> run and /var/lock -> /run/lock
395# we don't have those directories symlinked
396cp -p %{SOURCE6} $RPM_BUILD_ROOT%{systemdunitdir}/var-lock.mount
397cp -p %{SOURCE7} $RPM_BUILD_ROOT%{systemdunitdir}/var-run.mount
398
399# and remove tmp on tmpfs mount
400%{__rm} $RPM_BUILD_ROOT%{systemdunitdir}/tmp.mount
401
44410185 402# Install and enable storage subsystems support services (RAID, LVM, etc.)
216f25d7
ER
403cp -p %{SOURCE10} $RPM_BUILD_ROOT%{systemdunitdir}/pld-storage-init-late.service
404cp -p %{SOURCE11} $RPM_BUILD_ROOT%{systemdunitdir}/pld-storage-init.service
405cp -p %{SOURCE12} $RPM_BUILD_ROOT%{systemdunitdir}/pld-wait-storage.service
50b8f452 406cp -p %{SOURCE14} $RPM_BUILD_ROOT%{systemdunitdir}/pld-clean-tmp.service
216f25d7 407install -p %{SOURCE13} $RPM_BUILD_ROOT/lib/systemd/pld-storage-init
50b8f452 408install -p %{SOURCE15} $RPM_BUILD_ROOT/lib/systemd/pld-clean-tmp
44410185 409
50b8f452
ER
410ln -s ../pld-storage-init-late.service $RPM_BUILD_ROOT%{systemdunitdir}/local-fs.target.wants
411ln -s ../pld-storage-init.service $RPM_BUILD_ROOT%{systemdunitdir}/local-fs.target.wants
412ln -s ../pld-clean-tmp.service $RPM_BUILD_ROOT%{systemdunitdir}/local-fs.target.wants
c3037397 413
216f25d7
ER
414# handled by rc-local sysv service, no need for generator
415%{__rm} $RPM_BUILD_ROOT/lib/systemd/system-generators/systemd-rc-local-generator
216f25d7 416
2a61be78
TP
417# Make sure these directories are properly owned:
418# - halt,kexec,poweroff,reboot: generic ones used by ConsoleKit-systemd,
419# - syslog _might_ be used by some syslog implementation (none for now),
420# - isn't dbus populated by dbus-systemd only (so to be moved there)?
4cc1cb1d 421install -d $RPM_BUILD_ROOT%{systemdunitdir}/{dbus,halt,kexec,poweroff,reboot,syslog}.target.wants
961baf80
AF
422
423# Create new-style configuration files so that we can ghost-own them
70047b34 424touch $RPM_BUILD_ROOT%{_sysconfdir}/{hostname,locale.conf,machine-id,machine-info,timezone,vconsole.conf}
4bbef33c 425
9d8b5dfe 426# Install SysV conversion tool for systemd
4f25b6ac 427install -p %{SOURCE1} $RPM_BUILD_ROOT%{_bindir}
9d8b5dfe
BZ
428
429install -d $RPM_BUILD_ROOT/var/log
5a65c84e
TP
430:> $RPM_BUILD_ROOT/var/log/btmp
431:> $RPM_BUILD_ROOT/var/log/wtmp
a761f93e 432
5d32f234 433%{__rm} $RPM_BUILD_ROOT%{_mandir}/man1/systemadm.1*
5d32f234
TP
434
435%{__rm} -r $RPM_BUILD_ROOT%{_docdir}/%{name}
a86320a6 436%{__rm} $RPM_BUILD_ROOT/%{_lib}/security/pam_systemd.la
5d32f234
TP
437%{__rm} $RPM_BUILD_ROOT%{_libdir}/*.la
438
ede8d3e5 439%clean
440rm -rf $RPM_BUILD_ROOT
441
9638c72f 442%post
4bbef33c 443/bin/systemd-machine-id-setup > /dev/null 2>&1 || :
9638c72f 444/bin/systemctl daemon-reexec > /dev/null 2>&1 || :
c3037397 445
961baf80 446%postun
85879912 447if [ $1 -ge 1 ]; then
961baf80 448 /bin/systemctl try-restart systemd-logind.service >/dev/null 2>&1 || :
9638c72f 449fi
450
3edd52a6
TP
451%post libs -p /sbin/ldconfig
452%postun libs -p /sbin/ldconfig
011bccb6 453
961baf80 454%post units
85879912 455if [ $1 -eq 1 ]; then
961baf80
AF
456 # Try to read default runlevel from the old inittab if it exists
457 runlevel=$(/bin/awk -F ':' '$3 == "initdefault" && $1 !~ "^#" { print $2 }' /etc/inittab 2> /dev/null)
458 if [ -z "$runlevel" ] ; then
4cc1cb1d 459 target="%{systemdunitdir}/graphical.target"
961baf80 460 else
4cc1cb1d 461 target="%{systemdunitdir}/runlevel$runlevel.target"
961baf80
AF
462 fi
463
464 # And symlink what we found to the new-style default.target
f341cd9b 465 ln -s "$target" %{_sysconfdir}/systemd/system/default.target >/dev/null 2>&1 || :
cf819365
JR
466
467 # Setup hostname
468 [ -f /etc/sysconfig/network ] && . /etc/sysconfig/network
469 if [ -n "$HOSTNAME" -a "$HOSTNAME" != "pldmachine" ]; then
470 [ -f /etc/hostname ] && mv -f /etc/hostname /etc/hostname.rpmsave
471 echo $HOSTNAME > /etc/hostname
472 chmod 644 /etc/hostname
473 fi
44410185
JR
474
475 # Enable the services we install by default.
476 /bin/systemctl enable \
477 getty@.service \
478 network.service \
479 remote-fs.target \
480 systemd-readahead-replay.service \
481 systemd-readahead-collect.service >/dev/null 2>&1 || :
9638c72f 482fi
c3037397
ER
483
484%preun units
961baf80
AF
485if [ $1 -eq 0 ] ; then
486 /bin/systemctl disable \
487 getty@.service \
f1586299 488 network.service \
961baf80
AF
489 remote-fs.target \
490 systemd-readahead-replay.service \
491 systemd-readahead-collect.service >/dev/null 2>&1 || :
492
f341cd9b 493 %{__rm} -f %{_sysconfdir}/systemd/system/default.target >/dev/null 2>&1 || :
c3037397 494fi
9638c72f 495
961baf80 496%postun units
85879912 497if [ $1 -ge 1 ]; then
9638c72f 498 /bin/systemctl daemon-reload > /dev/null 2>&1 || :
499fi
500
f2a385f3 501%triggerpostun units -- %{name}-units < 43-7
44410185 502# Remove design fialures
44410185
JR
503rm -f %{_sysconfdir}/systemd/system/network.target.wants/ifcfg@*.service >/dev/null 2>&1 || :
504rm -f %{_sysconfdir}/systemd/system/network.target.wants/network-post.service >/dev/null 2>&1 || :
f3877668
JR
505rm -f %{_sysconfdir}/systemd/system/multi-user.target.wants/network-post.service >/dev/null 2>&1 || :
506/bin/systemctl reenable network.service >/dev/null 2>&1 || :
44410185 507
ae4d0acb 508%post no-compat-tmpfiles
a6203073 509%{__sed} -i -e '/^#/!s/^/# /g' %{_sysconfdir}/tmpfiles.d/compat-pld-var-run.conf
ae4d0acb 510
619d874f
ER
511%post plymouth
512%systemd_reload
513
514%postun plymouth
515%systemd_reload
516
ede8d3e5 517%files
518%defattr(644,root,root,755)
1c239f8b 519%doc DISTRO_PORTING README TODO
6e34428f 520/etc/dbus-1/system.d/org.freedesktop.hostname1.conf
961baf80
AF
521/etc/dbus-1/system.d/org.freedesktop.locale1.conf
522/etc/dbus-1/system.d/org.freedesktop.login1.conf
c3037397 523/etc/dbus-1/system.d/org.freedesktop.systemd1.conf
961baf80 524/etc/dbus-1/system.d/org.freedesktop.timedate1.conf
3edd52a6 525%ghost %config(noreplace) %{_sysconfdir}/machine-id
b77423ae
AF
526%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/hostname
527%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/locale.conf
528%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/machine-info
b77423ae
AF
529%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/timezone
530%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/vconsole.conf
5d32f234 531%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/systemd/*.conf
2a61be78 532%dir %{_sysconfdir}/systemd/user
44410185
JR
533%dir %{_sysconfdir}/systemd/system/*.target.wants
534%config(noreplace,missingok) %verify(not md5 mtime size) %{_sysconfdir}/systemd/system/*.target.wants/*.service
535%config(noreplace,missingok) %verify(not md5 mtime size) %{_sysconfdir}/systemd/system/*.target.wants/*.target
abd479ee 536/etc/xdg/systemd
1dcb74bb 537%attr(755,root,root) /bin/systemd
538%attr(755,root,root) /bin/systemd-ask-password
c76a8951 539%attr(755,root,root) /bin/systemd-journalctl
961baf80 540%attr(755,root,root) /bin/systemd-loginctl
7a76bc86 541%attr(755,root,root) /bin/systemd-machine-id-setup
1dcb74bb 542%attr(755,root,root) /bin/systemd-notify
543%attr(755,root,root) /bin/systemd-tty-ask-password-agent
d374e721
JR
544%attr(755,root,root) %{_bindir}/systemd-cat
545%attr(755,root,root) %{_bindir}/systemd-cgtop
23107006 546%attr(755,root,root) %{_bindir}/systemd-cgls
57cd0d13
ZU
547%attr(755,root,root) %{_bindir}/systemd-nspawn
548%attr(755,root,root) %{_bindir}/systemd-stdio-bridge
2a61be78 549%attr(755,root,root) %{_bindir}/systemd-sysv-convert
8a78a3e8 550%attr(755,root,root) /lib/systemd/pld-clean-tmp
44410185 551%attr(755,root,root) /lib/systemd/pld-storage-init
abd479ee 552%attr(755,root,root) /lib/systemd/systemd-*
c3037397 553%dir /lib/systemd/system-generators
4389e6f9 554%attr(755,root,root) /lib/systemd/systemd
5d32f234 555%attr(755,root,root) /lib/systemd/system-generators/systemd-*-generator
abd479ee 556%dir /lib/systemd/system-shutdown
1c239f8b 557/lib/udev/rules.d/99-systemd.rules
961baf80
AF
558/lib/udev/rules.d/70-uaccess.rules
559/lib/udev/rules.d/71-seat.rules
560/lib/udev/rules.d/73-seat-late.rules
3edd52a6
TP
561%dir %{_libexecdir}/systemd
562%{_libexecdir}/systemd/user
2a61be78 563%dir %{_libexecdir}/systemd/user-generators
89d58574 564%config(noreplace,missingok) %{_libexecdir}/tmpfiles.d/*.conf
961baf80
AF
565%{_datadir}/dbus-1/interfaces/org.freedesktop.hostname1.xml
566%{_datadir}/dbus-1/interfaces/org.freedesktop.locale1.xml
c3037397 567%{_datadir}/dbus-1/interfaces/org.freedesktop.systemd1.*.xml
961baf80 568%{_datadir}/dbus-1/interfaces/org.freedesktop.timedate1.xml
1c239f8b 569%{_datadir}/dbus-1/services/org.freedesktop.systemd1.service
6e34428f 570%{_datadir}/dbus-1/system-services/org.freedesktop.hostname1.service
961baf80
AF
571%{_datadir}/dbus-1/system-services/org.freedesktop.locale1.service
572%{_datadir}/dbus-1/system-services/org.freedesktop.login1.service
1c239f8b 573%{_datadir}/dbus-1/system-services/org.freedesktop.systemd1.service
961baf80 574%{_datadir}/dbus-1/system-services/org.freedesktop.timedate1.service
6e34428f 575%{_datadir}/polkit-1/actions/org.freedesktop.hostname1.policy
961baf80
AF
576%{_datadir}/polkit-1/actions/org.freedesktop.locale1.policy
577%{_datadir}/polkit-1/actions/org.freedesktop.login1.policy
578%{_datadir}/polkit-1/actions/org.freedesktop.systemd1.policy
579%{_datadir}/polkit-1/actions/org.freedesktop.timedate1.policy
580%dir %{_datadir}/systemd
581%{_datadir}/systemd/kbd-model-map
7a76bc86 582%{_mandir}/man1/systemd.1*
2a61be78 583%{_mandir}/man1/systemd-*.1*
6e34428f 584%{_mandir}/man5/binfmt.d.5*
1c239f8b 585%{_mandir}/man5/hostname.5*
586%{_mandir}/man5/locale.conf.5*
7a76bc86 587%{_mandir}/man5/machine-id.5*
6e34428f 588%{_mandir}/man5/machine-info.5*
1c239f8b 589%{_mandir}/man5/modules-load.d.5*
590%{_mandir}/man5/os-release.5*
6e34428f 591%{_mandir}/man5/sysctl.d.5*
89d58574 592%{_mandir}/man5/systemd.*.5*
2be4e142 593%{_mandir}/man5/systemd-journald.conf.5*
961baf80
AF
594%{_mandir}/man5/systemd-logind.conf.5*
595%{_mandir}/man5/timezone.5*
23107006 596%{_mandir}/man5/vconsole.conf.5*
1c239f8b 597%{_mandir}/man7/daemon.7*
598%{_mandir}/man7/sd-daemon.7*
c76a8951 599%{_mandir}/man7/sd-login.7*
1c239f8b 600%{_mandir}/man7/sd-readahead.7*
601%{_mandir}/man7/systemd.special.7*
24f95219
ER
602%dir /var/lib/%{name}
603%dir /var/lib/%{name}/coredump
a761f93e
TP
604%attr(640,root,root) %ghost /var/log/btmp
605%attr(664,root,utmp) %ghost /var/log/wtmp
c3037397 606
6c89bbd4 607%if %{with pam}
a86320a6 608%attr(755,root,root) /%{_lib}/security/pam_systemd.so
6c89bbd4
ER
609%{_mandir}/man8/pam_systemd.8*
610%endif
611
c97dacdd 612%files init
5b9bde26 613%defattr(644,root,root,755)
c97dacdd
TP
614%attr(755,root,root) /sbin/halt
615%attr(755,root,root) /sbin/init
616%attr(755,root,root) /sbin/poweroff
617%attr(755,root,root) /sbin/reboot
618%attr(755,root,root) /sbin/runlevel
619%attr(755,root,root) /sbin/shutdown
620%attr(755,root,root) /sbin/telinit
621%{_mandir}/man1/init.1
622%{_mandir}/man8/halt.8*
623%{_mandir}/man8/poweroff.8
624%{_mandir}/man8/reboot.8
625%{_mandir}/man8/runlevel.8*
626%{_mandir}/man8/shutdown.8*
627%{_mandir}/man8/telinit.8*
628
c3037397
ER
629%files units
630%defattr(644,root,root,755)
abd479ee
MB
631%dir %{_sysconfdir}/binfmt.d
632%dir %{_sysconfdir}/modules-load.d
5d32f234 633%config(noreplace,missingok) %verify(not md5 mtime size) %{_sysconfdir}/modules-load.d/modules.conf
abd479ee 634%dir %{_sysconfdir}/sysctl.d
c3037397
ER
635%dir %{_sysconfdir}/systemd
636%dir %{_sysconfdir}/systemd/system
637%dir %{_sysconfdir}/tmpfiles.d
7cb5cfc8 638%config(noreplace,missingok) %verify(not md5 mtime size) %{_sysconfdir}/tmpfiles.d/*.conf
85879912
ER
639%dir %{_libexecdir}/binfmt.d
640%dir %{_libexecdir}/modules-load.d
641%dir %{_libexecdir}/sysctl.d
3be4738a
JR
642# Don't package the kernel.core_pattern setting until systemd-coredump
643# is a part of an actual systemd release and it's made clear how to
644# get the core dumps out of the journal.
645#%{_libexecdir}/sysctl.d/coredump.conf
c3037397
ER
646%attr(755,root,root) /bin/systemctl
647%attr(755,root,root) /bin/systemd-tmpfiles
b77423ae 648%attr(755,root,root) /bin/systemd_booted
c3037397 649%{_mandir}/man1/systemctl.1*
89d58574 650%{_mandir}/man5/tmpfiles.d.5*
c3037397 651%{_mandir}/man8/systemd-tmpfiles.8*
961baf80 652%{_npkgconfigdir}/systemd.pc
c3037397 653
4cc1cb1d
ER
654%{systemdunitdir}/*.automount
655%{systemdunitdir}/*.mount
656%{systemdunitdir}/*.path
657%{systemdunitdir}/*.service
658%{systemdunitdir}/*.socket
659%{systemdunitdir}/*.target
660%{systemdunitdir}/*.timer
e4c66821
JB
661%if %{with plymouth}
662%exclude %{systemdunitdir}/plymouth*.service
663%exclude %{systemdunitdir}/systemd-ask-password-plymouth.*
664%endif
665%dir %{systemdunitdir}/basic.target.wants
666%dir %{systemdunitdir}/dbus.target.wants
667%dir %{systemdunitdir}/final.target.wants
668%dir %{systemdunitdir}/graphical.target.wants
669%dir %{systemdunitdir}/halt.target.wants
670%dir %{systemdunitdir}/kexec.target.wants
671%dir %{systemdunitdir}/local-fs.target.wants
672%dir %{systemdunitdir}/multi-user.target.wants
673%dir %{systemdunitdir}/poweroff.target.wants
674%dir %{systemdunitdir}/reboot.target.wants
675%dir %{systemdunitdir}/runlevel[12345].target.wants
676%dir %{systemdunitdir}/shutdown.target.wants
677%dir %{systemdunitdir}/sockets.target.wants
678%dir %{systemdunitdir}/sysinit.target.wants
679%dir %{systemdunitdir}/syslog.target.wants
680%config(noreplace,missingok) %{systemdunitdir}/basic.target.wants/*
681%config(noreplace,missingok) %{systemdunitdir}/final.target.wants/*
682%config(noreplace,missingok) %{systemdunitdir}/graphical.target.wants/*
683%config(noreplace,missingok) %{systemdunitdir}/local-fs.target.wants/*
684%config(noreplace,missingok) %{systemdunitdir}/multi-user.target.wants/getty.target
a2018b66 685%config(noreplace,missingok) %{systemdunitdir}/multi-user.target.wants/rc-local.service
e4c66821
JB
686%config(noreplace,missingok) %{systemdunitdir}/multi-user.target.wants/systemd-ask-password-wall.path
687%config(noreplace,missingok) %{systemdunitdir}/multi-user.target.wants/systemd-logind.service
688%config(noreplace,missingok) %{systemdunitdir}/multi-user.target.wants/systemd-user-sessions.service
689%config(noreplace,missingok) %{systemdunitdir}/runlevel[12345].target.wants/*
690%config(noreplace,missingok) %{systemdunitdir}/shutdown.target.wants/*
691%config(noreplace,missingok) %{systemdunitdir}/sockets.target.wants/*
8450fd95 692%{?with_cryptsetup:%config(noreplace,missingok) %{systemdunitdir}/sysinit.target.wants/cryptsetup.target}
e4c66821
JB
693%config(noreplace,missingok) %{systemdunitdir}/sysinit.target.wants/dev-hugepages.mount
694%config(noreplace,missingok) %{systemdunitdir}/sysinit.target.wants/dev-mqueue.mount
695%config(noreplace,missingok) %{systemdunitdir}/sysinit.target.wants/proc-sys-fs-binfmt_misc.automount
696%config(noreplace,missingok) %{systemdunitdir}/sysinit.target.wants/sys-*.mount
697%config(noreplace,missingok) %{systemdunitdir}/sysinit.target.wants/systemd-*
698
699%if %{with plymouth}
700%files plymouth
701%defattr(644,root,root,755)
702%{systemdunitdir}/plymouth-halt.service
703%{systemdunitdir}/plymouth-kexec.service
704%{systemdunitdir}/plymouth-poweroff.service
705%{systemdunitdir}/plymouth-quit-wait.service
706%{systemdunitdir}/plymouth-quit.service
707%{systemdunitdir}/plymouth-read-write.service
708%{systemdunitdir}/plymouth-reboot.service
709%{systemdunitdir}/plymouth-start.service
710%{systemdunitdir}/systemd-ask-password-plymouth.path
711%{systemdunitdir}/systemd-ask-password-plymouth.service
712%config(noreplace,missingok) %{systemdunitdir}/halt.target.wants/plymouth-halt.service
713%config(noreplace,missingok) %{systemdunitdir}/kexec.target.wants/plymouth-kexec.service
714%config(noreplace,missingok) %{systemdunitdir}/multi-user.target.wants/plymouth-quit.service
715%config(noreplace,missingok) %{systemdunitdir}/multi-user.target.wants/plymouth-quit-wait.service
716%config(noreplace,missingok) %{systemdunitdir}/poweroff.target.wants/plymouth-poweroff.service
717%config(noreplace,missingok) %{systemdunitdir}/reboot.target.wants/plymouth-reboot.service
718%config(noreplace,missingok) %{systemdunitdir}/sysinit.target.wants/plymouth-read-write.service
719%config(noreplace,missingok) %{systemdunitdir}/sysinit.target.wants/plymouth-start.service
720%endif
10ffdcd2 721
4e5e9c32
ER
722%files analyze
723%defattr(644,root,root,755)
724%attr(755,root,root) %{_bindir}/systemd-analyze
725
5b9bde26 726%files libs
6c89bbd4 727%defattr(644,root,root,755)
6ba1f779
MB
728%attr(755,root,root) /%{_lib}/libsystemd-daemon.so.*.*.*
729%attr(755,root,root) %ghost /%{_lib}/libsystemd-daemon.so.0
730%attr(755,root,root) /%{_lib}/libsystemd-id128.so.*.*.*
731%attr(755,root,root) %ghost /%{_lib}/libsystemd-id128.so.0
732%attr(755,root,root) /%{_lib}/libsystemd-journal.so.*.*.*
733%attr(755,root,root) %ghost /%{_lib}/libsystemd-journal.so.0
734%attr(755,root,root) /%{_lib}/libsystemd-login.so.*.*.*
735%attr(755,root,root) %ghost /%{_lib}/libsystemd-login.so.0
961baf80
AF
736
737%files devel
738%defattr(644,root,root,755)
89d58574 739%attr(755,root,root) %{_libdir}/libsystemd-daemon.so
c76a8951
BZ
740%attr(755,root,root) %{_libdir}/libsystemd-id128.so
741%attr(755,root,root) %{_libdir}/libsystemd-journal.so
89d58574 742%attr(755,root,root) %{_libdir}/libsystemd-login.so
5b9bde26 743%{_includedir}/%{name}
961baf80 744%{_pkgconfigdir}/libsystemd-daemon.pc
c76a8951
BZ
745%{_pkgconfigdir}/libsystemd-id128.pc
746%{_pkgconfigdir}/libsystemd-journal.pc
961baf80 747%{_pkgconfigdir}/libsystemd-login.pc
2be4e142 748%{_mandir}/man3/sd_booted.3*
c76a8951
BZ
749%{_mandir}/man3/sd_get_seats.3*
750%{_mandir}/man3/sd_get_sessions.3*
751%{_mandir}/man3/sd_get_uids.3*
2be4e142 752%{_mandir}/man3/sd_is_fifo.3*
c76a8951 753%{_mandir}/man3/sd_is_mq.3*
2be4e142
JR
754%{_mandir}/man3/sd_is_socket.3
755%{_mandir}/man3/sd_is_socket_inet.3
756%{_mandir}/man3/sd_is_socket_unix.3
757%{_mandir}/man3/sd_listen_fds.3*
c76a8951
BZ
758%{_mandir}/man3/sd_login_monitor_flush.3*
759%{_mandir}/man3/sd_login_monitor_get_fd.3*
760%{_mandir}/man3/sd_login_monitor_new.3*
761%{_mandir}/man3/sd_login_monitor_unref.3*
2be4e142
JR
762%{_mandir}/man3/sd_notify.3*
763%{_mandir}/man3/sd_notifyf.3
c76a8951
BZ
764%{_mandir}/man3/sd_pid_get_owner_uid.3*
765%{_mandir}/man3/sd_pid_get_session.3*
766%{_mandir}/man3/sd_pid_get_unit.3*
2be4e142 767%{_mandir}/man3/sd_readahead.3*
c76a8951
BZ
768%{_mandir}/man3/sd_seat_can_multi_session.3*
769%{_mandir}/man3/sd_seat_get_active.3*
770%{_mandir}/man3/sd_seat_get_sessions.3*
2be4e142
JR
771%{_mandir}/man3/sd_session_get_class.3*
772%{_mandir}/man3/sd_session_get_display.3*
c76a8951 773%{_mandir}/man3/sd_session_get_seat.3*
2be4e142
JR
774%{_mandir}/man3/sd_session_get_service.3*
775%{_mandir}/man3/sd_session_get_type.3*
c76a8951
BZ
776%{_mandir}/man3/sd_session_get_uid.3*
777%{_mandir}/man3/sd_session_is_active.3*
778%{_mandir}/man3/sd_uid_get_seats.3*
779%{_mandir}/man3/sd_uid_get_sessions.3*
780%{_mandir}/man3/sd_uid_get_state.3*
781%{_mandir}/man3/sd_uid_is_on_seat.3*
5b9bde26
JB
782
783%files -n bash-completion-systemd
784%defattr(644,root,root,755)
391eea76 785/etc/bash_completion.d/systemd-bash-completion.sh
ae4d0acb
JR
786
787%files no-compat-tmpfiles
788%defattr(644,root,root,755)
789# empty package
This page took 0.182082 seconds and 4 git commands to generate.