summaryrefslogtreecommitdiffstats
path: root/meta-oe
diff options
context:
space:
mode:
authorAndreas Müller <schnitzeltony@googlemail.com>2012-07-11 13:24:32 +0200
committerKoen Kooi <koen@dominion.thruhere.net>2012-07-16 09:39:05 +0200
commita5b2aea321b2851ed82828e6204c075a2329059c (patch)
tree06c57ad79e5cdcb0b8b62bb6e910c29c379fac8c /meta-oe
parent5ed19733f5193b752da650841a1383adb532fffd (diff)
downloadmeta-openembedded-a5b2aea321b2851ed82828e6204c075a2329059c.tar.gz
move systemd recipes to meta-systemd
Diffstat (limited to 'meta-oe')
-rw-r--r--meta-oe/recipes-core/systemd/systemd-compat-units.bb44
-rw-r--r--meta-oe/recipes-core/systemd/systemd-compat-units/machineid.service16
-rw-r--r--meta-oe/recipes-core/systemd/systemd-compat-units/run-postinsts.service17
-rw-r--r--meta-oe/recipes-core/systemd/systemd-machine-units_1.0.bb14
-rw-r--r--meta-oe/recipes-core/systemd/systemd-serialgetty.bb46
-rw-r--r--meta-oe/recipes-core/systemd/systemd-serialgetty/LICENSE339
-rw-r--r--meta-oe/recipes-core/systemd/systemd-serialgetty/serial-getty@.service32
-rw-r--r--meta-oe/recipes-core/systemd/systemd-speed-hacks.bb18
-rw-r--r--meta-oe/recipes-core/systemd/systemd-systemctl-native.bb15
-rwxr-xr-xmeta-oe/recipes-core/systemd/systemd-systemctl-native/systemctl91
-rw-r--r--meta-oe/recipes-core/systemd/systemd/format-replace-m-uclibc.patch389
-rw-r--r--meta-oe/recipes-core/systemd/systemd/paper-over-mkostemp.patch19
-rw-r--r--meta-oe/recipes-core/systemd/systemd_git.bb156
13 files changed, 0 insertions, 1196 deletions
diff --git a/meta-oe/recipes-core/systemd/systemd-compat-units.bb b/meta-oe/recipes-core/systemd/systemd-compat-units.bb
deleted file mode 100644
index c9a6b679e..000000000
--- a/meta-oe/recipes-core/systemd/systemd-compat-units.bb
+++ /dev/null
@@ -1,44 +0,0 @@
1DESCRIPTION = "Units to make systemd work better with existing sysvinit scripts"
2
3LICENSE = "MIT"
4LIC_FILES_CHKSUM = "file://${COREBASE}/LICENSE;md5=3f40d7994397109285ec7b81fdeb3b58"
5
6PR = "r15"
7
8inherit allarch
9
10SRC_URI = "file://*.service"
11
12do_install() {
13 install -d ${D}${systemd_unitdir}/system/basic.target.wants
14 install -d ${D}${systemd_unitdir}/system/sysinit.target.wants/
15 install -m 0644 ${WORKDIR}/run-postinsts.service ${D}${systemd_unitdir}/system
16 ln -sf ../run-postinsts.service ${D}${systemd_unitdir}/system/basic.target.wants/
17 ln -sf ../run-postinsts.service ${D}${systemd_unitdir}/system/sysinit.target.wants/
18
19 install -m 0644 ${WORKDIR}/machineid.service ${D}${systemd_unitdir}/system
20 ln -sf ../machineid.service ${D}${systemd_unitdir}/system/sysinit.target.wants/
21 ln -sf ../machineid.service ${D}${systemd_unitdir}/system/basic.target.wants/
22
23 # hack to make old style sysvinit postinsts succeed
24 install -d ${D}${bindir}
25 echo "echo 1" > ${D}${bindir}/runlevel
26 chmod 0755 ${D}${bindir}/runlevel
27}
28
29pkg_postinst_${PN} () {
30cd $D${sysconfdir}/init.d
31
32echo -n "Disabling the following sysv scripts: "
33
34for i in busybox-udhcpc dnsmasq hwclock.sh networking syslog syslog.busybox ; do
35 if [ -e $i ] ; then
36 echo -n "$i " ; ln -s /dev/null $D${systemd_unitdir}/system/$i.service
37 fi
38done ; echo
39}
40
41FILES_${PN} = "${systemd_unitdir}/system ${bindir}"
42RDPEPENDS_${PN} = "systemd"
43
44
diff --git a/meta-oe/recipes-core/systemd/systemd-compat-units/machineid.service b/meta-oe/recipes-core/systemd/systemd-compat-units/machineid.service
deleted file mode 100644
index cab8f76ab..000000000
--- a/meta-oe/recipes-core/systemd/systemd-compat-units/machineid.service
+++ /dev/null
@@ -1,16 +0,0 @@
1[Unit]
2Description=Machine ID first boot configure
3DefaultDependencies=no
4ConditionPathExists=|!/etc/machine-id
5After=remount-rootfs.service
6Before=sysinit.target
7
8[Service]
9ExecStart=/bin/systemd-machine-id-setup
10RemainAfterExit=No
11Type=oneshot
12StandardOutput=syslog
13
14[Install]
15WantedBy=basic.target
16WantedBy=sysinit.target
diff --git a/meta-oe/recipes-core/systemd/systemd-compat-units/run-postinsts.service b/meta-oe/recipes-core/systemd/systemd-compat-units/run-postinsts.service
deleted file mode 100644
index 879a25157..000000000
--- a/meta-oe/recipes-core/systemd/systemd-compat-units/run-postinsts.service
+++ /dev/null
@@ -1,17 +0,0 @@
1[Unit]
2Description=Run pending postinsts
3DefaultDependencies=no
4ConditionPathExists=|/etc/rcS.d/S98run-postinsts
5After=remount-rootfs.service
6Before=sysinit.target
7
8[Service]
9ExecStart=/etc/rcS.d/S98run-postinsts
10RemainAfterExit=No
11Type=oneshot
12StandardOutput=syslog
13TimeoutSec=0
14
15[Install]
16WantedBy=basic.target
17WantedBy=sysinit.target
diff --git a/meta-oe/recipes-core/systemd/systemd-machine-units_1.0.bb b/meta-oe/recipes-core/systemd/systemd-machine-units_1.0.bb
deleted file mode 100644
index f33b2a983..000000000
--- a/meta-oe/recipes-core/systemd/systemd-machine-units_1.0.bb
+++ /dev/null
@@ -1,14 +0,0 @@
1DESCRIPTION = "Machine specific systemd units"
2
3LICENSE = "MIT"
4LIC_FILES_CHKSUM = "file://${COREBASE}/LICENSE;md5=3f40d7994397109285ec7b81fdeb3b58"
5
6PACKAGE_ARCH = "${MACHINE_ARCH}"
7
8PR = "r1"
9
10inherit systemd
11SYSTEMD_SERVICE = ""
12SYSTEMD_PACKAGES = "${PN}"
13NATIVE_SYSTEMD_SUPPORT = "1"
14ALLOW_EMPTY_${PN} = "1"
diff --git a/meta-oe/recipes-core/systemd/systemd-serialgetty.bb b/meta-oe/recipes-core/systemd/systemd-serialgetty.bb
deleted file mode 100644
index c3106722f..000000000
--- a/meta-oe/recipes-core/systemd/systemd-serialgetty.bb
+++ /dev/null
@@ -1,46 +0,0 @@
1DESCRIPTION = "Systemd serial config"
2LICENSE = "GPLv2+"
3LIC_FILES_CHKSUM = "file://${WORKDIR}/LICENSE;md5=751419260aa954499f7abaabaa882bbe"
4
5PR = "r3"
6
7SERIAL_CONSOLE ?= "115200 ttyS0"
8
9SRC_URI = "file://LICENSE \
10 file://serial-getty@.service"
11
12def get_serial_console_value(d, index):
13 c = d.getVar('SERIAL_CONSOLE', True)
14
15 if len(c):
16 return c.split()[index]
17
18 return ""
19
20def get_baudrate(d):
21 return get_serial_console_value(d, 0)
22
23def get_console(d):
24 return get_serial_console_value(d, 1)
25
26do_install() {
27 if [ ! ${@get_baudrate(d)} = "" ]; then
28 sed -i -e s/\@BAUDRATE\@/${@get_baudrate(d)}/g ${WORKDIR}/serial-getty@.service
29 install -d ${D}${systemd_unitdir}/system/
30 install -d ${D}${sysconfdir}/systemd/system/getty.target.wants/
31 install ${WORKDIR}/serial-getty@.service ${D}${systemd_unitdir}/system/
32
33 # enable the service
34 ln -sf ${systemd_unitdir}/system/serial-getty@.service \
35 ${D}${sysconfdir}/systemd/system/getty.target.wants/serial-getty@${@get_console(d)}.service
36 fi
37}
38
39PACKAGES = "${PN} ${PN}-dbg ${PN}-dev ${PN}-doc"
40
41RRECOMMENDS_${PN} = ""
42RDEPENDS_${PN} = "systemd"
43
44# This is a machine specific file
45FILES_${PN} = "${systemd_unitdir}/system/serial-getty@.service ${sysconfdir}"
46PACKAGE_ARCH = "${MACHINE_ARCH}"
diff --git a/meta-oe/recipes-core/systemd/systemd-serialgetty/LICENSE b/meta-oe/recipes-core/systemd/systemd-serialgetty/LICENSE
deleted file mode 100644
index d511905c1..000000000
--- a/meta-oe/recipes-core/systemd/systemd-serialgetty/LICENSE
+++ /dev/null
@@ -1,339 +0,0 @@
1 GNU GENERAL PUBLIC LICENSE
2 Version 2, June 1991
3
4 Copyright (C) 1989, 1991 Free Software Foundation, Inc.,
5 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
6 Everyone is permitted to copy and distribute verbatim copies
7 of this license document, but changing it is not allowed.
8
9 Preamble
10
11 The licenses for most software are designed to take away your
12freedom to share and change it. By contrast, the GNU General Public
13License is intended to guarantee your freedom to share and change free
14software--to make sure the software is free for all its users. This
15General Public License applies to most of the Free Software
16Foundation's software and to any other program whose authors commit to
17using it. (Some other Free Software Foundation software is covered by
18the GNU Lesser General Public License instead.) You can apply it to
19your programs, too.
20
21 When we speak of free software, we are referring to freedom, not
22price. Our General Public Licenses are designed to make sure that you
23have the freedom to distribute copies of free software (and charge for
24this service if you wish), that you receive source code or can get it
25if you want it, that you can change the software or use pieces of it
26in new free programs; and that you know you can do these things.
27
28 To protect your rights, we need to make restrictions that forbid
29anyone to deny you these rights or to ask you to surrender the rights.
30These restrictions translate to certain responsibilities for you if you
31distribute copies of the software, or if you modify it.
32
33 For example, if you distribute copies of such a program, whether
34gratis or for a fee, you must give the recipients all the rights that
35you have. You must make sure that they, too, receive or can get the
36source code. And you must show them these terms so they know their
37rights.
38
39 We protect your rights with two steps: (1) copyright the software, and
40(2) offer you this license which gives you legal permission to copy,
41distribute and/or modify the software.
42
43 Also, for each author's protection and ours, we want to make certain
44that everyone understands that there is no warranty for this free
45software. If the software is modified by someone else and passed on, we
46want its recipients to know that what they have is not the original, so
47that any problems introduced by others will not reflect on the original
48authors' reputations.
49
50 Finally, any free program is threatened constantly by software
51patents. We wish to avoid the danger that redistributors of a free
52program will individually obtain patent licenses, in effect making the
53program proprietary. To prevent this, we have made it clear that any
54patent must be licensed for everyone's free use or not licensed at all.
55
56 The precise terms and conditions for copying, distribution and
57modification follow.
58
59 GNU GENERAL PUBLIC LICENSE
60 TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
61
62 0. This License applies to any program or other work which contains
63a notice placed by the copyright holder saying it may be distributed
64under the terms of this General Public License. The "Program", below,
65refers to any such program or work, and a "work based on the Program"
66means either the Program or any derivative work under copyright law:
67that is to say, a work containing the Program or a portion of it,
68either verbatim or with modifications and/or translated into another
69language. (Hereinafter, translation is included without limitation in
70the term "modification".) Each licensee is addressed as "you".
71
72Activities other than copying, distribution and modification are not
73covered by this License; they are outside its scope. The act of
74running the Program is not restricted, and the output from the Program
75is covered only if its contents constitute a work based on the
76Program (independent of having been made by running the Program).
77Whether that is true depends on what the Program does.
78
79 1. You may copy and distribute verbatim copies of the Program's
80source code as you receive it, in any medium, provided that you
81conspicuously and appropriately publish on each copy an appropriate
82copyright notice and disclaimer of warranty; keep intact all the
83notices that refer to this License and to the absence of any warranty;
84and give any other recipients of the Program a copy of this License
85along with the Program.
86
87You may charge a fee for the physical act of transferring a copy, and
88you may at your option offer warranty protection in exchange for a fee.
89
90 2. You may modify your copy or copies of the Program or any portion
91of it, thus forming a work based on the Program, and copy and
92distribute such modifications or work under the terms of Section 1
93above, provided that you also meet all of these conditions:
94
95 a) You must cause the modified files to carry prominent notices
96 stating that you changed the files and the date of any change.
97
98 b) You must cause any work that you distribute or publish, that in
99 whole or in part contains or is derived from the Program or any
100 part thereof, to be licensed as a whole at no charge to all third
101 parties under the terms of this License.
102
103 c) If the modified program normally reads commands interactively
104 when run, you must cause it, when started running for such
105 interactive use in the most ordinary way, to print or display an
106 announcement including an appropriate copyright notice and a
107 notice that there is no warranty (or else, saying that you provide
108 a warranty) and that users may redistribute the program under
109 these conditions, and telling the user how to view a copy of this
110 License. (Exception: if the Program itself is interactive but
111 does not normally print such an announcement, your work based on
112 the Program is not required to print an announcement.)
113
114These requirements apply to the modified work as a whole. If
115identifiable sections of that work are not derived from the Program,
116and can be reasonably considered independent and separate works in
117themselves, then this License, and its terms, do not apply to those
118sections when you distribute them as separate works. But when you
119distribute the same sections as part of a whole which is a work based
120on the Program, the distribution of the whole must be on the terms of
121this License, whose permissions for other licensees extend to the
122entire whole, and thus to each and every part regardless of who wrote it.
123
124Thus, it is not the intent of this section to claim rights or contest
125your rights to work written entirely by you; rather, the intent is to
126exercise the right to control the distribution of derivative or
127collective works based on the Program.
128
129In addition, mere aggregation of another work not based on the Program
130with the Program (or with a work based on the Program) on a volume of
131a storage or distribution medium does not bring the other work under
132the scope of this License.
133
134 3. You may copy and distribute the Program (or a work based on it,
135under Section 2) in object code or executable form under the terms of
136Sections 1 and 2 above provided that you also do one of the following:
137
138 a) Accompany it with the complete corresponding machine-readable
139 source code, which must be distributed under the terms of Sections
140 1 and 2 above on a medium customarily used for software interchange; or,
141
142 b) Accompany it with a written offer, valid for at least three
143 years, to give any third party, for a charge no more than your
144 cost of physically performing source distribution, a complete
145 machine-readable copy of the corresponding source code, to be
146 distributed under the terms of Sections 1 and 2 above on a medium
147 customarily used for software interchange; or,
148
149 c) Accompany it with the information you received as to the offer
150 to distribute corresponding source code. (This alternative is
151 allowed only for noncommercial distribution and only if you
152 received the program in object code or executable form with such
153 an offer, in accord with Subsection b above.)
154
155The source code for a work means the preferred form of the work for
156making modifications to it. For an executable work, complete source
157code means all the source code for all modules it contains, plus any
158associated interface definition files, plus the scripts used to
159control compilation and installation of the executable. However, as a
160special exception, the source code distributed need not include
161anything that is normally distributed (in either source or binary
162form) with the major components (compiler, kernel, and so on) of the
163operating system on which the executable runs, unless that component
164itself accompanies the executable.
165
166If distribution of executable or object code is made by offering
167access to copy from a designated place, then offering equivalent
168access to copy the source code from the same place counts as
169distribution of the source code, even though third parties are not
170compelled to copy the source along with the object code.
171
172 4. You may not copy, modify, sublicense, or distribute the Program
173except as expressly provided under this License. Any attempt
174otherwise to copy, modify, sublicense or distribute the Program is
175void, and will automatically terminate your rights under this License.
176However, parties who have received copies, or rights, from you under
177this License will not have their licenses terminated so long as such
178parties remain in full compliance.
179
180 5. You are not required to accept this License, since you have not
181signed it. However, nothing else grants you permission to modify or
182distribute the Program or its derivative works. These actions are
183prohibited by law if you do not accept this License. Therefore, by
184modifying or distributing the Program (or any work based on the
185Program), you indicate your acceptance of this License to do so, and
186all its terms and conditions for copying, distributing or modifying
187the Program or works based on it.
188
189 6. Each time you redistribute the Program (or any work based on the
190Program), the recipient automatically receives a license from the
191original licensor to copy, distribute or modify the Program subject to
192these terms and conditions. You may not impose any further
193restrictions on the recipients' exercise of the rights granted herein.
194You are not responsible for enforcing compliance by third parties to
195this License.
196
197 7. If, as a consequence of a court judgment or allegation of patent
198infringement or for any other reason (not limited to patent issues),
199conditions are imposed on you (whether by court order, agreement or
200otherwise) that contradict the conditions of this License, they do not
201excuse you from the conditions of this License. If you cannot
202distribute so as to satisfy simultaneously your obligations under this
203License and any other pertinent obligations, then as a consequence you
204may not distribute the Program at all. For example, if a patent
205license would not permit royalty-free redistribution of the Program by
206all those who receive copies directly or indirectly through you, then
207the only way you could satisfy both it and this License would be to
208refrain entirely from distribution of the Program.
209
210If any portion of this section is held invalid or unenforceable under
211any particular circumstance, the balance of the section is intended to
212apply and the section as a whole is intended to apply in other
213circumstances.
214
215It is not the purpose of this section to induce you to infringe any
216patents or other property right claims or to contest validity of any
217such claims; this section has the sole purpose of protecting the
218integrity of the free software distribution system, which is
219implemented by public license practices. Many people have made
220generous contributions to the wide range of software distributed
221through that system in reliance on consistent application of that
222system; it is up to the author/donor to decide if he or she is willing
223to distribute software through any other system and a licensee cannot
224impose that choice.
225
226This section is intended to make thoroughly clear what is believed to
227be a consequence of the rest of this License.
228
229 8. If the distribution and/or use of the Program is restricted in
230certain countries either by patents or by copyrighted interfaces, the
231original copyright holder who places the Program under this License
232may add an explicit geographical distribution limitation excluding
233those countries, so that distribution is permitted only in or among
234countries not thus excluded. In such case, this License incorporates
235the limitation as if written in the body of this License.
236
237 9. The Free Software Foundation may publish revised and/or new versions
238of the General Public License from time to time. Such new versions will
239be similar in spirit to the present version, but may differ in detail to
240address new problems or concerns.
241
242Each version is given a distinguishing version number. If the Program
243specifies a version number of this License which applies to it and "any
244later version", you have the option of following the terms and conditions
245either of that version or of any later version published by the Free
246Software Foundation. If the Program does not specify a version number of
247this License, you may choose any version ever published by the Free Software
248Foundation.
249
250 10. If you wish to incorporate parts of the Program into other free
251programs whose distribution conditions are different, write to the author
252to ask for permission. For software which is copyrighted by the Free
253Software Foundation, write to the Free Software Foundation; we sometimes
254make exceptions for this. Our decision will be guided by the two goals
255of preserving the free status of all derivatives of our free software and
256of promoting the sharing and reuse of software generally.
257
258 NO WARRANTY
259
260 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
261FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN
262OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
263PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED
264OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
265MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS
266TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE
267PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,
268REPAIR OR CORRECTION.
269
270 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
271WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
272REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
273INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
274OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
275TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY
276YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
277PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
278POSSIBILITY OF SUCH DAMAGES.
279
280 END OF TERMS AND CONDITIONS
281
282 How to Apply These Terms to Your New Programs
283
284 If you develop a new program, and you want it to be of the greatest
285possible use to the public, the best way to achieve this is to make it
286free software which everyone can redistribute and change under these terms.
287
288 To do so, attach the following notices to the program. It is safest
289to attach them to the start of each source file to most effectively
290convey the exclusion of warranty; and each file should have at least
291the "copyright" line and a pointer to where the full notice is found.
292
293 <one line to give the program's name and a brief idea of what it does.>
294 Copyright (C) <year> <name of author>
295
296 This program is free software; you can redistribute it and/or modify
297 it under the terms of the GNU General Public License as published by
298 the Free Software Foundation; either version 2 of the License, or
299 (at your option) any later version.
300
301 This program is distributed in the hope that it will be useful,
302 but WITHOUT ANY WARRANTY; without even the implied warranty of
303 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
304 GNU General Public License for more details.
305
306 You should have received a copy of the GNU General Public License along
307 with this program; if not, write to the Free Software Foundation, Inc.,
308 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
309
310Also add information on how to contact you by electronic and paper mail.
311
312If the program is interactive, make it output a short notice like this
313when it starts in an interactive mode:
314
315 Gnomovision version 69, Copyright (C) year name of author
316 Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
317 This is free software, and you are welcome to redistribute it
318 under certain conditions; type `show c' for details.
319
320The hypothetical commands `show w' and `show c' should show the appropriate
321parts of the General Public License. Of course, the commands you use may
322be called something other than `show w' and `show c'; they could even be
323mouse-clicks or menu items--whatever suits your program.
324
325You should also get your employer (if you work as a programmer) or your
326school, if any, to sign a "copyright disclaimer" for the program, if
327necessary. Here is a sample; alter the names:
328
329 Yoyodyne, Inc., hereby disclaims all copyright interest in the program
330 `Gnomovision' (which makes passes at compilers) written by James Hacker.
331
332 <signature of Ty Coon>, 1 April 1989
333 Ty Coon, President of Vice
334
335This General Public License does not permit incorporating your program into
336proprietary programs. If your program is a subroutine library, you may
337consider it more useful to permit linking proprietary applications with the
338library. If this is what you want to do, use the GNU Lesser General
339Public License instead of this License.
diff --git a/meta-oe/recipes-core/systemd/systemd-serialgetty/serial-getty@.service b/meta-oe/recipes-core/systemd/systemd-serialgetty/serial-getty@.service
deleted file mode 100644
index 8eeaab697..000000000
--- a/meta-oe/recipes-core/systemd/systemd-serialgetty/serial-getty@.service
+++ /dev/null
@@ -1,32 +0,0 @@
1# This file is part of systemd.
2#
3# systemd is free software; you can redistribute it and/or modify it
4# under the terms of the GNU General Public License as published by
5# the Free Software Foundation; either version 2 of the License, or
6# (at your option) any later version.
7
8[Unit]
9Description=Serial Getty on %I
10BindTo=dev-%i.device
11After=dev-%i.device systemd-user-sessions.service
12
13# If additional gettys are spawned during boot then we should make
14# sure that this is synchronized before getty.target, even though
15# getty.target didn't actually pull it in.
16Before=getty.target
17
18[Service]
19Environment=TERM=vt100
20ExecStart=-/sbin/agetty -s %I @BAUDRATE@
21Restart=always
22RestartSec=0
23UtmpIdentifier=%I
24TTYPath=/dev/%I
25TTYReset=yes
26TTYVHangup=yes
27KillMode=process
28IgnoreSIGPIPE=no
29
30# Some login implementations ignore SIGTERM, so we send SIGHUP
31# instead, to ensure that login terminates cleanly.
32KillSignal=SIGHUP
diff --git a/meta-oe/recipes-core/systemd/systemd-speed-hacks.bb b/meta-oe/recipes-core/systemd/systemd-speed-hacks.bb
deleted file mode 100644
index 8cfcc4c37..000000000
--- a/meta-oe/recipes-core/systemd/systemd-speed-hacks.bb
+++ /dev/null
@@ -1,18 +0,0 @@
1DESCRIPTION = "Collection of hacks to speed up systemd boot"
2LICENSE = "MIT"
3LIC_FILES_CHKSUM = "file://${COREBASE}/LICENSE;md5=3f40d7994397109285ec7b81fdeb3b58"
4
5PR = "r1"
6
7inherit allarch
8
9ALLOW_EMPTY_${PN} = "1"
10
11pkg_postinst_${PN} () {
12#!/bin/sh
13# I can run offline
14rm -f $D/lib/systemd/system/sysinit.target.wants/systemd-tmpfiles-setup.service
15
16rm -f $D/lib/systemd/system/sysinit.target.wants/sys-fs-fuse-connections.mount
17rm -f $D/lib/systemd/system/sysinit.target.wants/sys-kernel-debug.mount
18}
diff --git a/meta-oe/recipes-core/systemd/systemd-systemctl-native.bb b/meta-oe/recipes-core/systemd/systemd-systemctl-native.bb
deleted file mode 100644
index 7ca77ae18..000000000
--- a/meta-oe/recipes-core/systemd/systemd-systemctl-native.bb
+++ /dev/null
@@ -1,15 +0,0 @@
1DESCRIPTION = "Wrapper to enable of systemd services"
2
3LICENSE = "MIT"
4LIC_FILES_CHKSUM = "file://${COREBASE}/LICENSE;md5=3f40d7994397109285ec7b81fdeb3b58"
5
6PR = "r3"
7
8inherit native
9
10SRC_URI = "file://systemctl"
11
12do_install() {
13 install -d ${D}${bindir}
14 install -m 0755 ${WORKDIR}/systemctl ${D}${bindir}
15}
diff --git a/meta-oe/recipes-core/systemd/systemd-systemctl-native/systemctl b/meta-oe/recipes-core/systemd/systemd-systemctl-native/systemctl
deleted file mode 100755
index ff9e6a751..000000000
--- a/meta-oe/recipes-core/systemd/systemd-systemctl-native/systemctl
+++ /dev/null
@@ -1,91 +0,0 @@
1#!/bin/sh
2echo "Started $0 $*"
3
4ROOT=
5
6# parse command line params
7action=
8while [ $# != 0 ]; do
9 opt="$1"
10
11 case "$opt" in
12 enable)
13 shift
14
15 action="$opt"
16 services="$1"
17 cmd_args="1"
18 shift
19 ;;
20 disable)
21 shift
22
23 action="$opt"
24 services="$1"
25 cmd_args="1"
26 shift
27 ;;
28 --root=*)
29 ROOT=${opt##--root=}
30 cmd_args="0"
31 shift
32 ;;
33 *)
34 if [ "$cmd_args" = "1" ]; then
35 services="$services $opt"
36 shift
37 else
38 echo "'$opt' is an unkown option; exiting with error"
39 exit 1
40 fi
41 ;;
42 esac
43done
44
45for service in $services; do
46 echo "Try to find location of $service..."
47 # find service file
48 for p in $ROOT/etc/systemd/system \
49 $ROOT/lib/systemd/system \
50 $ROOT/usr/lib/systemd/system; do
51 if [ -e $p/$service ]; then
52 service_file=$p/$service
53 service_file=${service_file##$ROOT}
54 fi
55 done
56 if [ -z "$service_file" ]; then
57 echo "'$service' couldn't be found; exiting with error"
58 exit 1
59 fi
60 echo "Found $service in $service_file"
61
62 # create the required symbolic links
63 wanted_by=$(grep WantedBy $ROOT/$service_file \
64 | sed 's,WantedBy=,,g' \
65 | tr ',' '\n' \
66 | grep '\.target$')
67
68 for r in $wanted_by; do
69 echo "WantedBy=$r found in $service"
70 if [ "$action" = "enable" ]; then
71 mkdir -p $ROOT/etc/systemd/system/$r.wants
72 ln -s $service_file $ROOT/etc/systemd/system/$r.wants
73 echo "Enabled $service for $wanted_by."
74 else
75 rm -f $ROOT/etc/systemd/system/$r.wants/$service
76 rmdir --ignore-fail-on-non-empty -p $ROOT/etc/systemd/system/$r.wants
77 echo "Disabled $service for $wanted_by."
78 fi
79 done
80
81 # call us for the other required scripts
82 also=$(grep Also $ROOT/$service_file \
83 | sed 's,Also=,,g' \
84 | tr ',' '\n')
85 for a in $also; do
86 echo "Also=$a found in $service"
87 if [ "$action" = "enable" ]; then
88 $0 --root=$ROOT enable $a
89 fi
90 done
91done
diff --git a/meta-oe/recipes-core/systemd/systemd/format-replace-m-uclibc.patch b/meta-oe/recipes-core/systemd/systemd/format-replace-m-uclibc.patch
deleted file mode 100644
index dd86121bb..000000000
--- a/meta-oe/recipes-core/systemd/systemd/format-replace-m-uclibc.patch
+++ /dev/null
@@ -1,389 +0,0 @@
1Patch from Henning. %m is a glibc only thing. For uclibc we need to do it
2differently. So we use static strings instead of mallocing them and free'ing
3
4I dont know if upstream systemd have plans to make systemd work on non
5glibc system libraries if not then this patch would not make sense for
6upstream
7
8Signed-off-by: Khem Raj <raj.khem@gmail.com>
9
10Index: git/src/mount-setup.c
11===================================================================
12--- git.orig/src/mount-setup.c 2012-01-26 21:15:12.573084007 -0800
13+++ git/src/mount-setup.c 2012-01-26 21:15:16.005084174 -0800
14@@ -182,10 +182,10 @@
15 (void) fgets(buf, sizeof(buf), f);
16
17 for (;;) {
18- char *controller;
19+ char controller[30];
20 int enabled = 0;
21
22- if (fscanf(f, "%ms %*i %*i %i", &controller, &enabled) != 2) {
23+ if (fscanf(f, "%s %*i %*i %i", controller, &enabled) != 2) {
24
25 if (feof(f))
26 break;
27@@ -196,14 +196,12 @@
28 }
29
30 if (!enabled) {
31- free(controller);
32 continue;
33 }
34
35 r = set_put(controllers, controller);
36 if (r < 0) {
37 log_error("Failed to add controller to set.");
38- free(controller);
39 goto finish;
40 }
41 }
42@@ -273,7 +271,6 @@
43 p.fatal = false;
44
45 r = mount_one(&p, true);
46- free(controller);
47 free(where);
48
49 if (r < 0) {
50Index: git/src/socket-util.c
51===================================================================
52--- git.orig/src/socket-util.c 2012-01-26 21:15:12.593084008 -0800
53+++ git/src/socket-util.c 2012-01-26 21:15:16.005084174 -0800
54@@ -192,7 +192,7 @@
55 int socket_address_parse_netlink(SocketAddress *a, const char *s) {
56 int family;
57 unsigned group = 0;
58- char* sfamily = NULL;
59+ char sfamily[50];
60 assert(a);
61 assert(s);
62
63@@ -200,17 +200,14 @@
64 a->type = SOCK_RAW;
65
66 errno = 0;
67- if (sscanf(s, "%ms %u", &sfamily, &group) < 1)
68+ if (sscanf(s, "%49s %u", &sfamily, &group) < 1)
69 return errno ? -errno : -EINVAL;
70
71 if ((family = netlink_family_from_string(sfamily)) < 0)
72 if (safe_atoi(sfamily, &family) < 0) {
73- free(sfamily);
74 return -EINVAL;
75 }
76
77- free(sfamily);
78-
79 a->sockaddr.nl.nl_family = AF_NETLINK;
80 a->sockaddr.nl.nl_groups = group;
81
82Index: git/src/swap.c
83===================================================================
84--- git.orig/src/swap.c 2012-01-26 21:15:12.593084008 -0800
85+++ git/src/swap.c 2012-01-26 21:15:16.005084174 -0800
86@@ -1049,11 +1049,12 @@
87 (void) fscanf(m->proc_swaps, "%*s %*s %*s %*s %*s\n");
88
89 for (i = 1;; i++) {
90- char *dev = NULL, *d;
91+ char *d;
92+ char dev[20];
93 int prio = 0, k;
94
95 if ((k = fscanf(m->proc_swaps,
96- "%ms " /* device/file */
97+ "%19s " /* device/file */
98 "%*s " /* type of swap */
99 "%*s " /* swap size */
100 "%*s " /* used */
101@@ -1064,12 +1065,10 @@
102 break;
103
104 log_warning("Failed to parse /proc/swaps:%u.", i);
105- free(dev);
106 continue;
107 }
108
109 d = cunescape(dev);
110- free(dev);
111
112 if (!d)
113 return -ENOMEM;
114Index: git/src/tmpfiles.c
115===================================================================
116--- git.orig/src/tmpfiles.c 2012-01-26 21:15:12.617084010 -0800
117+++ git/src/tmpfiles.c 2012-01-26 23:17:01.185437712 -0800
118@@ -73,8 +73,8 @@
119 typedef struct Item {
120 ItemType type;
121
122- char *path;
123- char *argument;
124+ char path[50];
125+ char argument[50];
126 uid_t uid;
127 gid_t gid;
128 mode_t mode;
129@@ -822,7 +822,6 @@
130 case CREATE_CHAR_DEVICE:
131 case CREATE_BLOCK_DEVICE:
132 case IGNORE_PATH:
133- case RELABEL_PATH:
134 case RECURSIVE_RELABEL_PATH:
135 case WRITE_FILE:
136 break;
137@@ -858,8 +857,6 @@
138 static void item_free(Item *i) {
139 assert(i);
140
141- free(i->path);
142- free(i->argument);
143 free(i);
144 }
145
146@@ -906,7 +903,7 @@
147
148 static int parse_line(const char *fname, unsigned line, const char *buffer) {
149 Item *i, *existing;
150- char *mode = NULL, *user = NULL, *group = NULL, *age = NULL;
151+ char mode[50], user[50], group[50], age[50];
152 char type;
153 Hashmap *h;
154 int r, n = -1;
155@@ -923,18 +920,18 @@
156
157 if (sscanf(buffer,
158 "%c "
159- "%ms "
160- "%ms "
161- "%ms "
162- "%ms "
163- "%ms "
164+ "%s "
165+ "%s "
166+ "%s "
167+ "%s "
168+ "%s "
169 "%n",
170 &type,
171 &i->path,
172- &mode,
173- &user,
174- &group,
175- &age,
176+ mode,
177+ user,
178+ group,
179+ age,
180 &n) < 2) {
181 log_error("[%s:%u] Syntax error.", fname, line);
182 r = -EIO;
183@@ -944,7 +941,7 @@
184 if (n >= 0) {
185 n += strspn(buffer+n, WHITESPACE);
186 if (buffer[n] != 0 && (buffer[n] != '-' || buffer[n+1] != 0)) {
187- i->argument = unquote(buffer+n, "\"");
188+ strcpy(i->argument, unquote(buffer+n, "\""));
189 if (!i->argument) {
190 log_error("Out of memory");
191 return -ENOMEM;
192@@ -1096,11 +1093,6 @@
193 r = 0;
194
195 finish:
196- free(user);
197- free(group);
198- free(mode);
199- free(age);
200-
201 if (i)
202 item_free(i);
203
204Index: git/src/mount.c
205===================================================================
206--- git.orig/src/mount.c 2012-01-26 21:15:12.573084007 -0800
207+++ git/src/mount.c 2012-01-26 21:15:16.005084174 -0800
208@@ -24,6 +24,7 @@
209 #include <mntent.h>
210 #include <sys/epoll.h>
211 #include <signal.h>
212+#include <string.h>
213
214 #include "unit.h"
215 #include "mount.h"
216@@ -1561,7 +1562,13 @@
217 static int mount_load_proc_self_mountinfo(Manager *m, bool set_flags) {
218 int r = 0;
219 unsigned i;
220- char *device, *path, *options, *options2, *fstype, *d, *p, *o;
221+ char *d, *p, *o;
222+ char device[50];
223+ char path[50];
224+ char options[50];
225+ char options2[50];
226+ char fstype[50];
227+
228
229 assert(m);
230
231@@ -1570,26 +1577,26 @@
232 for (i = 1;; i++) {
233 int k;
234
235- device = path = options = options2 = fstype = d = p = o = NULL;
236+ d = p = o = NULL;
237
238 if ((k = fscanf(m->proc_self_mountinfo,
239 "%*s " /* (1) mount id */
240 "%*s " /* (2) parent id */
241 "%*s " /* (3) major:minor */
242 "%*s " /* (4) root */
243- "%ms " /* (5) mount point */
244- "%ms" /* (6) mount options */
245+ "%49s " /* (5) mount point */
246+ "%49s" /* (6) mount options */
247 "%*[^-]" /* (7) optional fields */
248 "- " /* (8) separator */
249- "%ms " /* (9) file system type */
250- "%ms" /* (10) mount source */
251- "%ms" /* (11) mount options 2 */
252+ "%49s " /* (9) file system type */
253+ "%49s" /* (10) mount source */
254+ "%49s" /* (11) mount options 2 */
255 "%*[^\n]", /* some rubbish at the end */
256- &path,
257- &options,
258- &fstype,
259- &device,
260- &options2)) != 5) {
261+ path,
262+ options,
263+ fstype,
264+ device,
265+ options2)) != 5) {
266
267 if (k == EOF)
268 break;
269@@ -1613,22 +1620,12 @@
270 r = k;
271
272 clean_up:
273- free(device);
274- free(path);
275- free(options);
276- free(options2);
277- free(fstype);
278 free(d);
279 free(p);
280 free(o);
281 }
282
283 finish:
284- free(device);
285- free(path);
286- free(options);
287- free(options2);
288- free(fstype);
289 free(d);
290 free(p);
291 free(o);
292Index: git/src/umount.c
293===================================================================
294--- git.orig/src/umount.c 2012-01-26 21:15:12.617084010 -0800
295+++ git/src/umount.c 2012-01-26 21:15:16.005084174 -0800
296@@ -60,7 +60,9 @@
297
298 static int mount_points_list_get(MountPoint **head) {
299 FILE *proc_self_mountinfo;
300- char *path, *p;
301+ char *p;
302+ char path[50];
303+
304 unsigned int i;
305 int r;
306
307@@ -72,17 +74,17 @@
308 for (i = 1;; i++) {
309 int k;
310 MountPoint *m;
311- char *root;
312+ char root[50];
313 bool skip_ro;
314
315- path = p = NULL;
316+ p = NULL;
317
318 if ((k = fscanf(proc_self_mountinfo,
319 "%*s " /* (1) mount id */
320 "%*s " /* (2) parent id */
321 "%*s " /* (3) major:minor */
322- "%ms " /* (4) root */
323- "%ms " /* (5) mount point */
324+ "%49s " /* (4) root */
325+ "%49s " /* (5) mount point */
326 "%*s" /* (6) mount options */
327 "%*[^-]" /* (7) optional fields */
328 "- " /* (8) separator */
329@@ -90,24 +92,21 @@
330 "%*s" /* (10) mount source */
331 "%*s" /* (11) mount options 2 */
332 "%*[^\n]", /* some rubbish at the end */
333- &root,
334- &path)) != 2) {
335+ root,
336+ path)) != 2) {
337 if (k == EOF)
338 break;
339
340 log_warning("Failed to parse /proc/self/mountinfo:%u.", i);
341
342- free(path);
343 continue;
344 }
345
346 /* If we encounter a bind mount, don't try to remount
347 * the source dir too early */
348 skip_ro = !streq(root, "/");
349- free(root);
350
351 p = cunescape(path);
352- free(path);
353
354 if (!p) {
355 r = -ENOMEM;
356@@ -152,28 +151,28 @@
357
358 for (i = 2;; i++) {
359 MountPoint *swap;
360- char *dev = NULL, *d;
361+ char *d;
362+ char dev[50];
363+
364 int k;
365
366 if ((k = fscanf(proc_swaps,
367- "%ms " /* device/file */
368+ "%50s " /* device/file */
369 "%*s " /* type of swap */
370 "%*s " /* swap size */
371 "%*s " /* used */
372 "%*s\n", /* priority */
373- &dev)) != 1) {
374+ dev)) != 1) {
375
376 if (k == EOF)
377 break;
378
379 log_warning("Failed to parse /proc/swaps:%u.", i);
380
381- free(dev);
382 continue;
383 }
384
385 if (endswith(dev, "(deleted)")) {
386- free(dev);
387 continue;
388 }
389
diff --git a/meta-oe/recipes-core/systemd/systemd/paper-over-mkostemp.patch b/meta-oe/recipes-core/systemd/systemd/paper-over-mkostemp.patch
deleted file mode 100644
index ca10440a8..000000000
--- a/meta-oe/recipes-core/systemd/systemd/paper-over-mkostemp.patch
+++ /dev/null
@@ -1,19 +0,0 @@
1uclibc does not have mkostemp() so we redefine it to use mkstemp()
2
3Signed-off-by: Khem Raj <raj.khem@gmail.com>
4
5Index: git/src/macro.h
6===================================================================
7--- git.orig/src/macro.h 2011-06-30 10:33:53.000000000 -0700
8+++ git/src/macro.h 2011-06-30 15:07:28.285270006 -0700
9@@ -27,6 +27,10 @@
10 #include <sys/uio.h>
11 #include <inttypes.h>
12
13+#ifdef __UCLIBC__
14+/* uclibc does not implement mkostemp GNU extention */
15+#define mkostemp(x,y) mkstemp(x)
16+#endif
17 #define _printf_attr_(a,b) __attribute__ ((format (printf, a, b)))
18 #define _sentinel_ __attribute__ ((sentinel))
19 #define _noreturn_ __attribute__((noreturn))
diff --git a/meta-oe/recipes-core/systemd/systemd_git.bb b/meta-oe/recipes-core/systemd/systemd_git.bb
deleted file mode 100644
index f4ca72a12..000000000
--- a/meta-oe/recipes-core/systemd/systemd_git.bb
+++ /dev/null
@@ -1,156 +0,0 @@
1DESCRIPTION = "Systemd a init replacement"
2HOMEPAGE = "http://www.freedesktop.org/wiki/Software/systemd"
3LICENSE = "GPLv2+"
4LIC_FILES_CHKSUM = "file://LICENSE;md5=751419260aa954499f7abaabaa882bbe"
5
6DEPENDS = "xz kmod docbook-sgml-dtd-4.1-native intltool-native gperf-native acl readline udev dbus libcap libcgroup tcp-wrappers"
7DEPENDS += "${@base_contains('DISTRO_FEATURES', 'pam', 'libpam', '', d)}"
8
9SERIAL_CONSOLE ?= "115200 /dev/ttyS0"
10
11SECTION = "base/shell"
12
13inherit gitpkgv
14PKGV = "v${GITPKGVTAG}"
15
16PV = "git"
17PR = "r27"
18
19inherit useradd pkgconfig autotools vala perlnative
20
21SRCREV = "3eff4208ffecedd778fec260f0d4b18e94dab443"
22
23SRC_URI = "git://anongit.freedesktop.org/systemd/systemd;protocol=git \
24 ${UCLIBCPATCHES} \
25 "
26UCLIBCPATCHES = ""
27UCLIBCPATCHES_libc-uclibc = "file://paper-over-mkostemp.patch \
28 file://format-replace-m-uclibc.patch \
29 "
30
31LDFLAGS_libc-uclibc_append = " -lrt"
32
33S = "${WORKDIR}/git"
34
35SYSTEMDDISTRO ?= "debian"
36SYSTEMDDISTRO_angstrom = "angstrom"
37
38# The gtk+ tools should get built as a separate recipe e.g. systemd-tools
39EXTRA_OECONF = " --with-distro=${SYSTEMDDISTRO} \
40 --with-rootprefix=${base_prefix} \
41 --with-rootlibdir=${base_libdir} \
42 ${@base_contains('DISTRO_FEATURES', 'pam', '--enable-pam', '--disable-pam', d)} \
43 --disable-gtk \
44 --enable-xz \
45 --disable-manpages \
46 --disable-coredump \
47 "
48
49# There's no docbook-xsl-native, so for the xsltproc check to false
50do_configure_prepend() {
51 sed -i /xsltproc/d configure.ac
52
53 # we only have /home/root, not /root
54 sed -i -e 's:=/root:=/home/root:g' units/*.service*
55}
56
57do_install() {
58 autotools_do_install
59 # provided by a seperate recipe
60 rm ${D}${systemd_unitdir}/system/serial-getty* -f
61
62 # provide support for initramfs
63 ln -s ${systemd_unitdir}/systemd ${D}/init
64
65 # create dir for journal
66 install -d ${D}${localstatedir}/log/journal
67
68 # create machine-id
69 # 20:12 < mezcalero> koen: you have three options: a) run systemd-machine-id-setup at install time, b) have / read-only and an empty file there (for stateless) and c) boot with / writable
70 touch ${D}${sysconfdir}/machine-id
71}
72
73python populate_packages_prepend (){
74 systemdlibdir = d.getVar("base_libdir", True)
75 do_split_packages(d, systemdlibdir, '^lib(.*)\.so\.*', 'lib%s', 'Systemd %s library', extra_depends='', allow_links=True)
76}
77
78PACKAGES =+ "${PN}-gui ${PN}-vconsole-setup ${PN}-initramfs ${PN}-analyze"
79
80USERADD_PACKAGES = "${PN}"
81GROUPADD_PARAM_${PN} = "-r lock"
82
83FILES_${PN}-analyze = "${bindir}/systemd-analyze"
84RDEPENDS_${PN}-analyze = "python-dbus"
85RRECOMMENDS_${PN}-analyze = "python-pycairo"
86
87FILES_${PN}-initramfs = "/init"
88RDEPENDS_${PN}-initramfs = "${PN}"
89
90FILES_${PN}-gui = "${bindir}/systemadm"
91
92FILES_${PN}-vconsole-setup = "${systemd_unitdir}/systemd-vconsole-setup \
93 ${systemd_unitdir}/system/systemd-vconsole-setup.service \
94 ${systemd_unitdir}/system/sysinit.target.wants/systemd-vconsole-setup.service"
95
96RRECOMMENDS_${PN}-vconsole-setup = "kbd kbd-consolefonts"
97
98FILES_${PN} = " ${base_bindir}/* \
99 ${datadir}/dbus-1/services \
100 ${datadir}/dbus-1/system-services \
101 ${datadir}/polkit-1 \
102 ${datadir}/${PN} \
103 ${sysconfdir} \
104 ${systemd_unitdir}/* \
105 ${systemd_unitdir}/system/* \
106 ${base_libdir}/udev/rules.d \
107 ${base_libdir}/security/*.so \
108 /cgroup \
109 ${bindir}/systemd* \
110 ${libdir}/tmpfiles.d/*.conf \
111 ${libdir}/systemd \
112 ${libdir}/binfmt.d \
113 ${libdir}/modules-load.d \
114 ${libdir}/sysctl.d \
115 ${localstatedir} \
116 ${libexecdir} \
117 "
118
119FILES_${PN}-dbg += "${systemd_unitdir}/.debug ${systemd_unitdir}/*/.debug ${base_libdir}/security/.debug/"
120FILES_${PN}-dev += "${base_libdir}/security/*.la ${datadir}/dbus-1/interfaces/"
121
122RDEPENDS_${PN} += "dbus-systemd udev-systemd"
123
124# kbd -> loadkeys,setfont
125# systemd calls 'modprobe -sab --', which busybox doesn't support due to lack
126# of blacklist support, so use proper modprobe from module-init-tools
127# And pull in the kernel modules mentioned in INSTALL
128# swapon -p is also not supported by busybox
129# busybox mount is broken
130RRECOMMENDS_${PN} += "systemd-serialgetty \
131 util-linux-agetty \
132 util-linux-swaponoff \
133 util-linux-fsck e2fsprogs-e2fsck \
134 module-init-tools \
135 util-linux-mount util-linux-umount \
136 kernel-module-autofs4 kernel-module-unix kernel-module-ipv6 \
137"
138
139# TODO:
140# u-a for runlevel and telinit
141
142pkg_postinst_systemd () {
143update-alternatives --install ${base_sbindir}/init init ${systemd_unitdir}/systemd 300
144update-alternatives --install ${base_sbindir}/halt halt ${base_bindir}/systemctl 300
145update-alternatives --install ${base_sbindir}/reboot reboot ${base_bindir}/systemctl 300
146update-alternatives --install ${base_sbindir}/shutdown shutdown ${base_bindir}/systemctl 300
147update-alternatives --install ${base_sbindir}/poweroff poweroff ${base_bindir}/systemctl 300
148}
149
150pkg_prerm_systemd () {
151update-alternatives --remove init ${systemd_unitdir}/systemd
152update-alternatives --remove halt ${base_bindir}/systemctl
153update-alternatives --remove reboot ${base_bindir}/systemctl
154update-alternatives --remove shutdown ${base_bindir}/systemctl
155update-alternatives --remove poweroff ${base_bindir}/systemctl
156}