runtimejs / runtime

[not maintained] Lightweight JavaScript library operating system for the cloud
http://runtimejs.org
Apache License 2.0
1.93k stars 128 forks source link

mkinitrd not found? #47

Closed facekapow closed 9 years ago

facekapow commented 9 years ago

OK, so, i'm on OSX 10.10.3 and this project seems interesting. I cloned it and brewed up qemu (easy) and installed FASM (reeeeeeeaaaalllyyy hard, long story short, got it installed) and installed scons (easy-ish), but now i'm stumped. It built just fine, except for one little problem. When I run ./qemu.sh with the cloned repo folder as the CWD, this is what I get: screenshot of terminal I tried ./makeinitrd-browserify.sh but I get: screen shot of terminal 2 Tried npm install runtimejs and got illegal instruction: 4 with question marks for the stack trace.

Any ideas? I have a Ubuntu Server at home that I SSH into and mount, so could I copy everything onto there and (since Ubuntu is a Linux distro with initrd) generate the initrd from there?

EDIT: The helloworld example runs just fine, so...

iefserge commented 9 years ago

@ArielAbreu Hi! mkinitrd and related shell scripts are part of the old JavaScript bundle system that has been replaced by runtimeify. Use runtimeify like:

npm install runtimeify -g
runtimeify ./index.js -o initrd

There is also runtime-tools package that includes runtime-qemu helper script that makes it easy to run initrd images in QEMU. It can also download prebuilt kernel binary when no --kernel option specified.

npm install runtime-tools -g
runtime-qemu ./initrd

Or you can use your binary built from source like

runtime-qemu --kernel ./runtime/disk/boot/runtime ./initrd
facekapow commented 9 years ago

OK, thanks! Sorry for any trouble. Also, does this come with any built-in commands? And, if it doesn't, how can I get input from the user?

iefserge commented 9 years ago

@ArielAbreu it's totally fine, I'm going to remove those old scripts because they're confusing. There is no API documentation, because it [API] is very unstable and probably going to change. All I can offer right now is source code https://github.com/runtimejs/runtime/tree/master/js. For example, this is the example how to listen to specific command in terminal https://github.com/runtimejs/runtime/blob/master/js/index.js#L37.

facekapow commented 9 years ago

Thanks. Closing this issue, as I now have a couple of working commands. Gonna see if I can edit the source a bit to work with the filesystem. Thx @iefserge!