--- /sys/src/9/boot/boot.c Sat Mar 28 08:11:48 2015+++ ../frontmods/boot/boot.c Fri Dec 7 23:24:22 2018@@ -9,6 +9,7 @@ { char cputype[64]; char buf[32];+ char bootcmd[64]; fmtinstall('r', errfmt); @@ -36,6 +37,7 @@ USED(argc); readfile("#e/cputype", cputype, sizeof(cputype));+ readfile("#e/bootcmd", bootcmd, sizeof(bootcmd)); /* setup the boot namespace */ bind("/boot", "/bin", MAFTER);@@ -44,5 +46,7 @@ snprint(buf, sizeof(buf), "/%s/bin", cputype); bind(buf, "/bin", MAFTER); bind("/rc/bin", "/bin", MAFTER);+ if(strcmp(bootcmd, "plan9rc")==0)+ exec("/boot/plan9rc", argv); exec("/bin/bootrc", argv); }
--- /sys/src/9/boot/boot.c Sat Mar 28 08:11:48 2015
+++ ../frontmods/boot/boot.c Fri Dec 7 23:24:22 2018
@@ -9,6 +9,7 @@
{
char cputype[64];
char buf[32];
+ char bootcmd[64];
fmtinstall('r', errfmt);
@@ -36,6 +37,7 @@
USED(argc);
readfile("#e/cputype", cputype, sizeof(cputype));
+ readfile("#e/bootcmd", bootcmd, sizeof(bootcmd));
/* setup the boot namespace */
bind("/boot", "/bin", MAFTER);
@@ -44,5 +46,7 @@
snprint(buf, sizeof(buf), "/%s/bin", cputype);
bind(buf, "/bin", MAFTER);
bind("/rc/bin", "/bin", MAFTER);
+ if(strcmp(bootcmd, "plan9rc")==0)
+ exec("/boot/plan9rc", argv);
exec("/bin/bootrc", argv);
}