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