QuickStartGuideFirst you need to obtain NestedVM. The best way is to use Darcs but a tarball is available at http://nestedvm.ibex.org (although this may not be up to date). $ darcs get --repo-name=nestedvm http://nestedvm.ibex.org Next you need to build it. The NestedVM build process not only builds itself, but also a complete mips toolchain based on binutils, gcc, and newlib. This part will probably take a while. There is also lots of ways it can go wrong so please let us know at mailto:nestedvm@googlegroups.com if you run into any trouble. $ cd nestedvm $ make Now you should have a working copy of NestedVM and and MIPS toolchain. You can run Compiling your own code to run under NestedVM is a two step process. First you need to build a MIPS binary (using the supplied toolchain). Then you need to convert that binary to a Java class. First you need to setup the build environment (this just adds the some stuff to the PATH and CLASSPATH environment variables). $ make env.sh $ source env.sh Next you need to build the MIPS binary
$ cat > test.c
int main() { printf("Hello, Word\n"); }
^D
$ mips-unknown-elf-gcc -o test.mips test.c
You'd replace test.c with your C source code. If you've got multiple files just compile and link them the same as you would with a native binary, except use Now you convert this mips binary to a java .class file. This will take test.mips and generate Test.class $ java org.ibex.nestedvm.Compiler -outfile Test.class Test test.mips Finally, test the generated class. $ java Test Hello, Word If you want to redistribute your binary you'll need to include the contents of |