Move makerd to TOML-based manifest

Added the cpptoml library (and license), and moved to using that for
the initrd manifest. It's now possible to specify the `executable`
flag for files, and the kernel correctly only launches new processes
for the initrd files marked `executable`.
This commit is contained in:
Justin C. Miller
2018-09-08 12:54:35 -07:00
parent 3a39d9440a
commit e7a509176d
9 changed files with 3780 additions and 64 deletions

View File

@@ -83,7 +83,7 @@ kernel_main(popcorn_data *header)
initrd::disk ird(header->initrd);
log::info(logs::boot, "initrd loaded with %d files.", ird.files().count());
for (auto &f : ird.files())
log::info(logs::boot, " %s (%d bytes).", f.name(), f.size());
log::info(logs::boot, " %s%s (%d bytes).", f.executable() ? "*" : "", f.name(), f.size());
/*
pager->dump_pml4(nullptr, 0);
@@ -144,7 +144,7 @@ kernel_main(popcorn_data *header)
scheduler *sched = new (&scheduler::get()) scheduler(devices->get_lapic());
for (auto &f : ird.files()) {
//if (f.executable())
if (f.executable())
sched->create_process(f.name(), f.data(), f.size());
}