Bug 14536

Summary: Dev Manual, "Selecting an Initialization Manager", should mention INIT_MANAGER
Product: [Documentation] Development Manual Reporter: Robert P. J. Day <rpjday>
Component: developmentAssignee: Michael Opdenacker <michael.opdenacker>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: Medium+ CC: randy.macleod, richard.purdie
Version: unspecified   
Target Milestone: 4.3 M1   
Hardware: x86   
OS: Multiple   
Whiteboard:
OS type for building Yocto: --- Type of Regression: ---
Verified: Documentation change: Yes (doc changes required)

Description Robert P. J. Day 2021-08-31 11:22:21 UTC
A good deal of what is here:

https://docs.yoctoproject.org/dev-manual/common-tasks.html#selecting-an-initialization-manager

is subsumed by simply setting INIT_MANAGER appropriately, which will include the appropriate init setup file, such as with init-manager-systemd.inc:

# Use systemd for system initialization
DISTRO_FEATURES:append = " systemd"
DISTRO_FEATURES_BACKFILL_CONSIDERED:append = " sysvinit"
VIRTUAL-RUNTIME_init_manager ??= "systemd"
VIRTUAL-RUNTIME_initscripts ??= "systemd-compat-units"
VIRTUAL-RUNTIME_login_manager ??= "shadow-base"
VIRTUAL-RUNTIME_dev_manager ??= "systemd"

making most of that section unnecessary.
Comment 1 Michael Opdenacker 2023-01-03 18:44:01 UTC
Actually, setting INIT_MANAGER in local.conf doesn't work any more, at least in Poky which hardcodes it.

I regret this as setting this variable would very easy to do, and document too!

See my question on https://lore.kernel.org/openembedded-core/2893205d-57e1-e63e-5c12-c57c7bbcb924@crashcourse.ca/T/#t
Comment 2 Michael Opdenacker 2023-04-28 08:43:11 UTC
It's now possible again to set INIT_MANAGER in local.conf in Poky,
and the documentation now suggests to use this variable:

https://git.yoctoproject.org/yocto-docs/commit/?id=602c0e8f770516256dab04edfd887377303c06bb

Closing this bug.
Thanks!