]> git.ipfire.org Git - people/ms/ipfire-3.x.git/blob - initscripts/initscripts.nm
systemd: Remove udev rules for "predictable" network device names
[people/ms/ipfire-3.x.git] / initscripts / initscripts.nm
1 ###############################################################################
2 # IPFire.org - An Open Source Firewall Solution #
3 # Copyright (C) - IPFire Development Team <info@ipfire.org> #
4 ###############################################################################
5
6 name = initscripts
7 epoch = 1
8 version = 2.99
9 release = 19
10
11 groups = System/Boot
12 url =
13 license = GPLv3+
14 summary = The set of scripts that initalize the system.
15
16 description
17 The initscripts package contains the basic system scripts used to boot
18 your system and shut the system down cleanly.
19 end
20
21 # Nothing to download.
22 sources =
23
24 build
25 requires
26 glib2-devel
27 popt-devel
28 shadow-utils
29 systemd-units
30 end
31
32 DIR_APP = %{DIR_SOURCE}
33
34 prepare_cmds
35 cd src && make clean
36 end
37
38 build
39 cd src && make %{PARALLELISMFLAGS}
40 end
41
42 test
43 cd src && make test
44 end
45
46 install
47 cd src && make install clean DESTDIR=%{BUILDROOT}
48
49 # Install rc.local
50 mkdir -pv %{BUILDROOT}%{sysconfdir}
51 install -v -m 755 %{DIR_SOURCE}/rc.local %{BUILDROOT}%{sysconfdir}/rc.local
52
53 # Install udev rules
54 mkdir -pv %{BUILDROOT}%{prefix}/lib/udev/rules.d/
55 cp -vf %{DIR_SOURCE}/udev/* %{BUILDROOT}%{prefix}/lib/udev/rules.d/
56 end
57 end
58
59 packages
60 package %{name}
61 groups += Base
62
63 requires
64 bash
65 coreutils
66 e2fsprogs
67 grep
68 iproute2
69 module-init-tools
70 procps
71 sed
72 system-release
73 udev
74 util-linux
75 end
76
77 provides
78 /bin/ipcalc
79 end
80
81 conflicts
82 filesystem < 002
83 end
84
85 datafiles
86 /etc/rc.local
87 end
88
89 prerequires
90 coreutils
91 shadow-utils
92 end
93
94 script prein
95 groupadd -g 22 -r -f utmp
96 end
97
98 script postin
99 touch /var/log/{b,w}tmp /var/run/utmp
100 chown root:utmp /var/log/{b,w}tmp /var/run/utmp
101 chmod 664 /var/log/wtmp /var/run/utmp
102 chmod 600 /var/log/btmp
103
104 # Just search for new unit files that were just installed.
105 /bin/systemctl daemon-reload >/dev/null 2>&1 || :
106
107 # Enable rc.local as default.
108 /bin/systemctl --no-reload enable rc-local.service >/dev/null 2>&1 || :
109 end
110
111 # Disable the service that is to be removed and stop it if it is still running.
112 script preun
113 /bin/systemctl --no-reload disable rc-local.service >/dev/null 2>&1 || :
114 /bin/systemctl stop rc-local.service >/dev/null 2>&1 || :
115 end
116
117 # Just tell systemd that unitfiles have been removed.
118 script postun
119 /bin/systemctl daemon-reload >/dev/null 2>&1 || :
120 end
121 end
122
123 package %{name}-debuginfo
124 template DEBUGINFO
125 end
126 end