1 ###############################################################################
2 # IPFire.org - An Open Source Firewall Solution #
3 # Copyright (C) - IPFire Development Team <info@ipfire.org> #
4 ###############################################################################
10 maintainer = Stefan Schantl <stefan.schantl@ipfire.org>
12 url = http://www.freedesktop.org/wiki/Software/systemd
14 summary = A System and Service Manager.
17 systemd is a system and service manager for Linux, compatible with
18 SysV and LSB init scripts.
23 source_dl = http://cgit.freedesktop.org/systemd/snapshot/
41 configure_options += \
43 --libexecdir=/usr/lib \
46 --with-sysvinit-path= \
47 --with-sysvrcd-path= \
48 --with-udevrulesdir=/lib/udev/rules.d/ \
49 --with-pamlibdir=/lib/security
60 # Create sysv compatible symlinks.
61 mkdir -pv %{BUILDROOT}/sbin
62 ln -svf ../bin/systemd %{BUILDROOT}/sbin/init
63 ln -svf ../bin/systemctl %{BUILDROOT}/sbin/reboot
64 ln -svf ../bin/systemctl %{BUILDROOT}/sbin/halt
65 ln -svf ../bin/systemctl %{BUILDROOT}/sbin/poweroff
66 ln -svf ../bin/systemctl %{BUILDROOT}/sbin/shutdown
68 # Create empty machine-id file.
69 touch %{BUILDROOT}/etc/machine-id
71 # Copy locale and console settings
72 mkdir -pv %{BUILDROOT}/etc
73 cp -vf %{DIR_SOURCE}/locale.conf %{BUILDROOT}/etc/
74 cp -vf %{DIR_SOURCE}/vconsole.conf %{BUILDROOT}/etc/
76 # Recreate all targets
77 rm -rfv %{BUILDROOT}/etc/systemd/system/*.target.wants
78 mkdir -pv %{BUILDROOT}/lib/systemd/system/basic.target.wants
79 mkdir -pv %{BUILDROOT}/lib/systemd/system/default.target.wants
80 mkdir -pv %{BUILDROOT}/lib/systemd/system/dbus.target.wants
81 mkdir -pv %{BUILDROOT}/lib/systemd/system/syslog.target.wants
83 # Remove runlevel targets and graphical.target
84 rm -rfv %{BUILDROOT}/lib/systemd/system/runlevel*
85 rm -rfv %{BUILDROOT}/lib/systemd/system/graphical.target
87 # Set default target to multi-user
88 cd %{BUILDROOT}/lib/systemd/system && ln -svf multi-user.target default.target
90 # Replace absolute symlinks by relative ones.
91 cd %{BUILDROOT}/usr/lib/systemd/user/ && ln -svf ../../../../lib/systemd/system/bluetooth.target bluetooth.target
92 cd %{BUILDROOT}/usr/lib/systemd/user/ && ln -svf ../../../../lib/systemd/system/local-fs.target local-fs.target
93 cd %{BUILDROOT}/usr/lib/systemd/user/ && ln -svf ../../../../lib/systemd/system/printer.target printer.target
94 cd %{BUILDROOT}/usr/lib/systemd/user/ && ln -svf ../../../../lib/systemd/system/shutdown.target shutdown.target
95 cd %{BUILDROOT}/usr/lib/systemd/user/ && ln -svf ../../../../lib/systemd/system/sockets.target sockets.target
96 cd %{BUILDROOT}/usr/lib/systemd/user/ && ln -svf ../../../../lib/systemd/system/sound.target sound.target
97 cd %{BUILDROOT}/usr/lib/systemd/user/ && ln -svf ../../../../lib/systemd/system/swap.target swap.target
99 # Remove tmpfile for X11
100 rm -rfv %{BUILDROOT}/usr/lib/tmpfiles.d/x11.conf
102 # Remove unneeded symlink for xdg
103 rm -rfv %{BUILDROOT}/etc/xdg/systemd
118 # Generate Machine ID.
119 /bin/systemd-machine-id-setup > /dev/null 2>&1 || :
121 # Reexec systemd daemon.
122 /bin/systemctl daemon-reexec > /dev/null 2>&1 || :
124 # Make sure pam_systemd is enabled
125 if ! /bin/grep -q pam_systemd /etc/pam.d/system-auth-ac ; then
126 /usr/sbin/authconfig --update --nostart >/dev/null 2>&1 || :
129 /bin/grep -q pam_systemd /etc/pam.d/system-auth-ac || /usr/sbin/authconfig --updateall --nostart >/dev/null 2>&1 || :
134 # Restart login service after update
135 /bin/systemctl try-restart systemd-logind.service >/dev/null 2>&1 || :
139 # Package information for systemd-units
140 package %{name}-units
141 summary = Configuration files, directories and installation tool for systemd.
143 This package contains all needed configuration files, directories
144 and installation / configuration tool for systemd.
150 /etc/bash_completion.d/systemctl-bash-completion.sh
153 /bin/systemd-tmpfiles
154 /usr/share/man/man1/systemctl.*
158 # Enable default services.
161 remote-fs.target > /dev/null 2>&1 || :
165 # Disable default services.
168 remote-fs.target > /dev/null 2>&1 || :
172 # Reload service files
173 systemctl daemon-reload > /dev/null 2>&1 || :
177 package %{name}-devel