Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix #383: configure must expand FINIT_RUNPATH_ before define
This fixes an annying buglet that creeped in just before the v4.5 release causing none of the internal services to be registered properly: conf_save_service():Failed creating ${localstatedir}/run/finit/system/dbus.conf: No such file or directory plugin_run_hook():Calling modules-load hook n:o 5 (arg: 0x55c4c8133621) ... load():Scanning /etc/modules-load.d for config files ... cond_set_oneshot():hook/svc/plugin cond_set_oneshot_noupdate():hook/svc/plugin => /run/finit/cond/hook/svc/plugin cond_update():hook/svc/plugin parse_conf():*** Parsing /etc/finit.conf conf_save_service():Failed creating ${localstatedir}/run/finit/system/runparts.conf: No such file or directory The fix, like most, is simple when you find it. We must expand $runstatedir before creating the #define in config.h For convenience, here's the patch for the generated configure script: &<---------------------------[cut here]--------------------------- --- a/configure 2023-11-05 23:39:51.907334321 +0100 +++ b/configure 2023-11-05 23:39:58.339299795 +0100 @@ -15352,7 +15352,15 @@ printf "%s\n" "#define FINIT_EXECPATH_ \"$pkglibexecdir\"" >>confdefs.h -printf "%s\n" "#define FINIT_RUNPATH_ \"$runstatedir/finit/system\"" >>confdefs.h + finit_runpath="$runstatedir/finit/system" + finit_runpath=`( + test "x$prefix" = xNONE && prefix="$ac_default_prefix" + test "x$exec_prefix" = xNONE && exec_prefix="${prefix}" + eval echo \""$finit_runpath"\" + )` + + +printf "%s\n" "#define FINIT_RUNPATH_ \"$finit_runpath\"" >>confdefs.h &<---------------------------[cut here]--------------------------- Ensure you include the three empty lines for context at the end! Signed-off-by: Joachim Wiberg <[email protected]>
- Loading branch information