TempleOS on Apple Silicon

TempleOS is a unique OS, it was created by one single person with no support from other developers, it has its own compiler, games and all the usual things you can find in an OS with the difference that everything is packed into a few lines of code which for things like games is just brilliant.

The code can be viewed on Github and like I already mention, TemplesOS is using its own compiler called HolyC.

So TempleOS can only work on x86_64 architecture, but luckily it can also work on ARM, the only thing that I couldn’t make it work was the audio, everything else is working fine.

Installation

So the installation is super simple, you just need to download UTM and a template for UTM. Just download the ISO from the official website and add it to the Drives as a CD/DVD (ISO) Image and you should be able to boot inside the VM.

Follow the instructions on screen and if you can’t use the mouse, there is an icon on the window to capture input devices which will enable the mouse. After the installation is done instead of rebooting from the VM when asked to, just shut down the VM, remove the disk image and after rebooting the VM you should see a list of options to choose the drive, select 1 which is the C drive.

QEMU

I managed to get TempleOS working with QEMU alone, but it was having some issues when resizing the screen or using a bigger resolution. I thought that it was a problem due to the fact that TempleOS has been created to work on a 640x480 resolution, but then I tried ZealOS which is a fork of TempleOS but with some extra features one of them include support for bigger resolutions. But this wasn’t working either and it turned out that in order to change the resolution depending on the Bootloader you are using, you can either update it in the boot menu (this by using Limine) or if you want to choose the painful way, you can update the resolution by recompiling the whole kernel.

For anyone interested, for TempleOS I used this commands:

qemu-system-x86_64 -m 512M -device virtio-vga -drive file=data.qcow2 -cdrom TempleOS.ISO -boot order=c,menu=on

And for ZealOS I used:

qemu-system-x86_64 -accel tcg -display cocoa -machine q35,kernel_irqchip=off -cdrom ZealOS.iso -hda ZealOS.qcow2 -m 2G -smp 32 -rtc base=localtime -nic user,model=pcnet -vga std

TLDR

I will keep exploring more this OS since I am relearning C/C++, so this only way at the moment to use these kind of OSs is by creating a VM with UTM, since QEMU alone doesn’t really work or it requires more tinkering and since the OS was built just to work on the x86_64 architecture, it is expected to find some problems like the missing audio.