seL4 Level-1 Tutorials - Environment Setup
The tutorials were tested and are guaranteed to work with Ubuntu 20.04 LTS. Accordingly, the environment can be set up with:
- Native Ubuntu 20.04 LTs: For this setup, skip to Scripts.
- Ubuntu 20.04 LTS Virtual Machine: This setup uses VirtualBox.
Installing the Virtual Machine
Install VirtualBox:
- Go to VirtualBox Download page and download VirtualBox and VirtualBox Extension Pack.
- Install VirtualBox (requires admin/sudo privilege).
- Run VirtualBox in privileged mode (admin/sudo) → File → Preferences → Extensions → Add → Select downloaded Extension Pack.
4. Close privileged VirtualBox window.
Install Ubuntu 20.04 LTS Virtual Machine:
- Download Ubuntu 20.04 LTS ISO.
- VirtualBox → Virtual Media Manager → Properties → Optical Disks → Add → Select downloaded ISO.
3. VirtualBox → Machine → New → Configure as shown below → Create.
4. Create the hard disk:
5. Right-click the created VM → Settings → Storage → Controller: IDE → Add Optical → Select Ubuntu 20.04 LTS ISO file → Ok
6. Run the VM and install Ubuntu by following the steps. Upon completion, the VM will restart.
7. When the machine is ready, boot it → Devices → Insert Guest Additions CD image... → Run (will ask for password).
8. Open a terminal in the VM and run:
$ sudo usermod -G vboxsf -a $USER
$ sudo shutdown now |
9. With the machine turned off, go to VM settings → Shared Folders → Add → Select folder on the host machine to share with the VM:
10. All done! Start the VM. The shared-folder should appear in the VM's file manager. For example:
Note: if the shared folder is inaccessible inside the VM, make sure to execute Step 8.
Preparing the Ubuntu 20.04 Machine For seL4 Development
Install dependencies on the VM:
- Download ubuntu-20.04-setup-scripts.zip into the VM and extract it in /home/$USER/:
$ unzip ubuntu-20.4-setup-scripts.zip -d /home/$USER/
$ cd /home/$USER |
Note: Do not extract the scripts archive on the host machine if you are using Windows.
2. Open a terminal and run ./setup-environment script. It will take a little while to complete and the machine will reboot.
3. Open a terminal and run ./setup-sel4-container script. It will also take a bit to download and install all dependencies.
4. During execution you will get the following output:
5. Run `exit` to let the script continue with the installation procedure. 6. When completed, close the terminal to let changes take effect. 7. Now, you should be able to run `container` command in a new terminal and get the same output shown step 4.