mirror of
https://github.com/troglobit/finit.git
synced 2026-10-30 12:50:34 +00:00
Fix broken SYSROOT and add it to configure script.
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
This commit is contained in:
1 parent
57b167f9aa
commit
36c59e77b4
2 files changed
+13
-1
No files matched your search
@@ -53,6 +53,9 @@ result()
|
|||||||
echo "FIFO : $fifo"
|
echo "FIFO : $fifo"
|
||||||
echo "Config file : $config"
|
echo "Config file : $config"
|
||||||
echo "rcs.d/ directory : $rcsd"
|
echo "rcs.d/ directory : $rcsd"
|
||||||
|
if [ x"$sysroot" != x"" ]; then
|
||||||
|
echo "Swap rootfs to : $sysroot"
|
||||||
|
fi
|
||||||
echo "Default username : $defuser"
|
echo "Default username : $defuser"
|
||||||
echo "Default hostname : $defhost"
|
echo "Default hostname : $defhost"
|
||||||
echo "Default runlevel : $runlevel"
|
echo "Default runlevel : $runlevel"
|
||||||
@@ -131,6 +134,8 @@ usage()
|
|||||||
echo " files, or as built-in if --enable-static is given,"
|
echo " files, or as built-in if --enable-static is given,"
|
||||||
echo " defaults to all plugins. Exclude extension!"
|
echo " defaults to all plugins. Exclude extension!"
|
||||||
echo " --with-rcsd=RCSD Finit RCSD directory, default '\$sysconfdir/$confdir'"
|
echo " --with-rcsd=RCSD Finit RCSD directory, default '\$sysconfdir/$confdir'"
|
||||||
|
echo " --with-sysroot=PATH Some distributions keep a different (writable) rootfs"
|
||||||
|
echo " that is used at runtime, usually /sysroot or /mnt"
|
||||||
echo " --with-username=USER User for 'startx' .conf option, default: root"
|
echo " --with-username=USER User for 'startx' .conf option, default: root"
|
||||||
echo " --with-hostname=NAME Hostname, if /etc/hostname is missing, default: noname"
|
echo " --with-hostname=NAME Hostname, if /etc/hostname is missing, default: noname"
|
||||||
echo " --with-runlevel=LEVEL Runlevel to switch to after bootstrap (S), default: 2"
|
echo " --with-runlevel=LEVEL Runlevel to switch to after bootstrap (S), default: 2"
|
||||||
@@ -209,6 +214,10 @@ while [ "$*" != "" ]; do
|
|||||||
rcsd="$arg"
|
rcsd="$arg"
|
||||||
;;
|
;;
|
||||||
|
|
||||||
|
with-sysroot)
|
||||||
|
sysroot="$arg"
|
||||||
|
;;
|
||||||
|
|
||||||
with-usename)
|
with-usename)
|
||||||
defuser="$arg"
|
defuser="$arg"
|
||||||
;;
|
;;
|
||||||
@@ -337,6 +346,9 @@ fi
|
|||||||
echo "#define FINIT_FIFO \"$fifo\"" >> config.h
|
echo "#define FINIT_FIFO \"$fifo\"" >> config.h
|
||||||
echo "#define FINIT_CONF \"$config\"" >> config.h
|
echo "#define FINIT_CONF \"$config\"" >> config.h
|
||||||
echo "#define FINIT_RCSD \"$rcsd\"" >> config.h
|
echo "#define FINIT_RCSD \"$rcsd\"" >> config.h
|
||||||
|
if [ x"$sysroot" != x"" ]; then
|
||||||
|
echo "#define SYSROOT \"$sysroot\"" >> config.h
|
||||||
|
fi
|
||||||
echo "#define PLUGIN_PATH \"$plugindir\"" >> config.h
|
echo "#define PLUGIN_PATH \"$plugindir\"" >> config.h
|
||||||
if [ x"$random" != x"" ]; then
|
if [ x"$random" != x"" ]; then
|
||||||
echo "#define RANDOMSEED \"$random\"" >> config.h
|
echo "#define RANDOMSEED \"$random\"" >> config.h
|
||||||
|
|||||||
@@ -139,7 +139,7 @@ int main(int argc, char* argv[])
|
|||||||
run("/bin/mount -n -o remount,rw /");
|
run("/bin/mount -n -o remount,rw /");
|
||||||
#endif
|
#endif
|
||||||
#ifdef SYSROOT
|
#ifdef SYSROOT
|
||||||
run(SYSROOT, "/", NULL, MS_MOVE, NULL);
|
mount(SYSROOT, "/", NULL, MS_MOVE, NULL);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
_d("Root FS up, calling hooks ...");
|
_d("Root FS up, calling hooks ...");
|
||||||
|
|||||||
Reference in new issue
Block a user