Gentoo Archives: gentoo-user

From: Mike Gilbert <floppym@g.o>
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] systemd_dounit
Date: Thu, 19 Feb 2015 04:29:55
Message-Id: CAJ0EP405DNAFcZyvYKgP3vFBwQD0kngeC2Sd03iguhkhEVH3Tw@mail.gmail.com
In Reply to: [gentoo-user] systemd_dounit by James
1 On Feb 18, 2015 11:12 PM, "James" <wireless@×××××××××××.com> wrote:
2 >
3 > Ok
4 >
5 > So I'm reading about systemd support in ebuilds; just trying to
6 > understand the beast wee bit better.
7 >
8 > In in this ebuild: www-misc/monitorix (A lightweight system monitoring
9 tool)f
10 >
11 > the newest version has added this line to the ebuild:
12 >
13 > "systemd_dounit docs/${PN}.service"
14 >
15 >
16 > Looking that the systemd.eclass, all I see is:
17 > "systemd_dounit <unit>...
18 > Install systemd unit(s). Uses doins, thus it is fatal in EAPI 4 and
19 > non-fatal in earlier EAPIs. "
20 >
21 > Which seems reasonable, but tells me nothing what the line does. I can
22 > speculate that monitorix becomes a registered process, if you are
23 > running systemd, but is otherwise ignored on a openrc based system?
24 >
25
26 systemd_dounit copies a service file to ${ED}/usr/lib/systemd/system.
27 Nothing more.
28
29 You would need some understanding of how systemd works to know what that
30 actually means for an end user. A service unit serves basically the same
31 purpose as an init script. They are ignored if you do not boot with
32 systemd.
33
34 > It would seem to me the devmanual needs some more "prose" so on can
35 > discern what the systemd.eclass is doing. And yea, I'm off to look
36 > at the code for systemd.eclass as I'm sure it's clear as mud.....
37 >
38 > The trouble is I find this code everywhere with google. So where
39 > is the best place to read the current systemd.eclass code and where
40 > do I look at the 9999 stuffage; ?should? I become curious about that
41 > eclass or other eclass codes.....?
42
43 The eclasses are all in /usr/portage/eclass.