]> git.ipfire.org Git - thirdparty/openembedded/openembedded-core.git/commit
systemd.bbclass: do not automatically add Also services
authorAdrian Freihofer <adrian.freihofer@siemens.com>
Thu, 12 Dec 2024 15:55:25 +0000 (16:55 +0100)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Mon, 16 Dec 2024 22:38:36 +0000 (22:38 +0000)
commitf836d80eb48a2a2f9b1e66980021755cf0ca2a26
treeecd7ab7b242ec0f35f67d004784ac2df0a5cb062
parent0eda7131bf743719d6586ccd36d99cbe11c88262
systemd.bbclass: do not automatically add Also services

Starting a systemd service “Also” does not mean that both services
must be in the same package. However, the systemd.bbclass enforces
this.

Example:
  a.service:
    [Install]
    Also=b.service
If a.service is packed in package A, b.service is automatically packed
into package A as well. This happens even if b.service is explicitly
added to package B using FILES and SYSTEMD_SERVICE variables.

The automatic packing of socket files with the corresponding service
files is probably a widely used feature of systemd.bbclass. This bahavior
does not change.

Adding regular service files to a package just because it is another
service in the same package that "Also" uses the service is a bug that
this commit fixes.

Signed-off-by: Adrian Freihofer <adrian.freihofer@siemens.com>
Signed-off-by: Mathieu Dubois-Briand <mathieu.dubois-briand@bootlin.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
meta/classes-recipe/systemd.bbclass