OpenDingux / buildroot

Buildroot, making embedded Linux easy. Note that this is not the official repository, but only a mirror. The official Git repository is at http://git.buildroot.net/buildroot/. Do not open issues or file pull requests here.
http://buildroot.org
Other
63 stars 46 forks source link

od: Avoid subshell in rcS and rcK #104

Open glebm opened 1 year ago

glebm commented 1 year ago

We previously used ( ... ) subprocess for each init script to prevent the exit command from exiting rcS/K.

Instead, define the EXIT=return in rcS/K and use ${EXIT:-exit} in the scripts instead of the exit command.

${EXIT:-exit} will expand to exit if $EXIT is not set, allowing these scripts to be called directly as well.

This only applies to system scripts. We still use subshells in S99localscripts.sh to avoid breaking any user scripts.

NEEDS TESTING

glebm commented 1 year ago

Confirmed that this boots on rg350m and gets all the way to "Spawning getty..."