-
Notifications
You must be signed in to change notification settings - Fork 1
BootStrap
sauber edited this page Jan 21, 2012
·
1 revision
There are two ways to start abfsd, 1) Just execute one command, or 2) spawn a daemon.
In abfsd script, get an abfs object, and call run_command() with the command to run.
my $abfs = new Filesys::Virtual::ABFS(); $abfs->run_command("lsmod");
run_command creates the loader, and asks to have Command module loaded. Request is a recursive dependency, so put in request to execute command, and then start kernel. When kernel is finished running, unload Command module again and exit.
sub run_command { my($self,$command) = @_; my $loader = new Filesys::Virtual::ABFS::Core::Loader; $loader->add('Command'); $loader->{modules}->getobj('Request')->(...); $loader->{modules}->getobj('Core::Kernel')->run(); $loader->del('Command'); }