|
1 | | -# lib-openarena |
2 | | -OpenArena Engine |
| 1 | +# OpenArena for Unikraft |
| 2 | +This is the port of OpenArena for Unikraft as external library. |
| 3 | + |
| 4 | +## Build |
| 5 | +OpenArena depends on the following extern libraries, that need to |
| 6 | +be added to `Makefile`: |
| 7 | + |
| 8 | +* `libc`, e.g. `musl` |
| 9 | +* compression library, e.g. `libzlib` |
| 10 | +* network stack, e.g. `lwip` |
| 11 | + |
| 12 | +Before you proceed to writing your own application, you can use the `main()` |
| 13 | +function provided in the Nginx glue code by enabling it in its configuration |
| 14 | +menu. |
| 15 | + |
| 16 | +## Root filesystem |
| 17 | +### Creating the filesystem |
| 18 | +OpenArena needs a filesystem which should contain its configuration files for the server, along with textures files. Therefore, the filesystem needs to be created before |
| 19 | +running the VM. You can find an example in the `catalog-core` entry dedicated to OpenArena. |
| 20 | + |
| 21 | +### Using the filesystem |
| 22 | +Mounting the filesystem is a transparent operation. All you have to do |
| 23 | +is to provide the right Qemu parameters in order for Unikraft to mount |
| 24 | +the filesystem. We will use the cpio support for filesystems and for |
| 25 | +this you will need to use the following parameters: |
| 26 | + |
| 27 | +```bash |
| 28 | +-initrd initrd.cpio \ |
| 29 | +-append "vfs.fstab=[\"initrd0:/:extract::ramfs=1:\"]" |
| 30 | +``` |
| 31 | + |
| 32 | +To enable cpio, you'll need to select the following `Config.uk` entries: |
| 33 | + |
| 34 | +```bash |
| 35 | +select LIBUKCPIO |
| 36 | +select LIBDEVFS |
| 37 | +select LIBDEVFS_AUTOMOUNT |
| 38 | +select LIBDEVFS_DEVSTDOUT |
| 39 | +select LIBVFSCORE |
| 40 | +select LIBVFSCORE_AUTOMOUNT_UP |
| 41 | +``` |
| 42 | +
|
| 43 | +## Further information |
| 44 | +Please refer to the `README.md` as well as the documentation in the `docs/` |
| 45 | +subdirectory of the main unikraft repository. |
0 commit comments