Why stop there?
Grab a copy of Vice and run C64 games on Linux (on Windows (on Mac OS)).
Parallels has released a new version of its macOS desktop hypervisor and added a few handy things that developers and virtualization wonks will likely appreciate. The company offers Parallels desktop as a better way to run Windows on Apple hardware, mostly because it lets users do so without having to reboot when they fancy …
Virtualbox should be able to do nested virtualization now...
(I should try this for Android stuff)
I have a Mac laptop. It did have VMware fusion on it. Thanks to work, I had a fully licensed copy of all the VMware software, so I downloaded vsphere. Installed it on a VM within fusion, then spun up a VM within vsphere , and installed Windows 10 on it. As the laptop only had an i5 with 8 gig of ram, I couldn’t go too far into my virtual machine version of inception, as I ran out of ram, and even without the ram problem, the laptop was struggling a bit.
Still, it achieved the aim. I got knowledge of administering virtual machines on a vsphere system, without me having to ask for access to one of the vsphere clusters we have at work, which would have probably been refused.
HyperV doesn't really allow you to run esoteric stuff. VMWare, VirtualBox, or QEMU are better for that It supports Windows (XP & Higher I think), Linux, and FreeBSD; and I think that's about it. The OS needs Hyper-V drivers in order to work, and I believe MS have only contributed drivers for Linux & FreeBSD.
But the Arm version of Windows only supports 32-bit x86 apps via emulation, there's currently no support within Windows for Arm to run 64-bit x64 apps via emulation. So you're reliant on either finding apps that have also been compiled in ARM64, or being stuck with the 32-bit versions of the apps with the limitations that brings, while hoping MS add emulation support for x64 soon.
VMware Fusion has been doing this for ages. I've run Hyper-V inside VMWare. If you connect by RDP to the nested virtual machine, performance is about 3% slower than if you have one level of virtualisation. Graphics performance from running the Hyper-V client inside the VMWare client is not good though,
Instead of putting Cupertino's commercial clusterfuck on top, just run a vanilla BSD.
And why would I run the Linux on Redmond kludge when Slackware exists?
As alternatives to the commercial kitchensinkware, both are cleaner, easier, cheaper, more secure, more reliable, and never phone home. Works for me, my clients, my Wife, Daughter and Granddaughter ... and MeDearOldMum (85ish) & Great Aunt (105ish).
Ha! I remember the time a student got kicked off the University computer systems (and, if memory serves, out of an honors program) after he ran a copy of VM/CMS inside a trio of nested virtual machines. The 4341 was barely up to the task. (I know //I// didn't get any work done that day.)
Back in the day (late '70s) one of the kids learning about virtualization on the Mainframe asked if self-virtualization was possible (i.e. running a VM in a VM). The answer was yes ... So naturally, someone (unnamed, to protect the guilty) decided to see how deep they could get the virtualization to go.
Turned out you could bring a very high-end IBM mainframe to its knees almost instantly ... much hilarity ensued.
The thing that's really missing is an officially sanctioned way of running Apple OS/X (or whatever they're calling it these days) in a VM on Linux. That would let me run automated software tests on Apple's OS using the same infrastructure and test system I use to test everything else.
As it stands now I have automated tests that run half a dozen different versions of Linux, BSD, and MS Windows on x86 and several versions of Linux on ARM, compiled using three different compilers. If it runs on OS/X that's fine, but I can't really support it as I have no practical means of testing it.
I know there are unsanctioned ways of running OS/X in a VM on Linux, but I'm running an open source project so I can't really touch that.
As far as your subject line goes, that’s easy enough. You can run MacOS in a VM, but on a Mac, which is what I do to run older versions of MacOS for some software.
It’s annoying that Apple don’t provide this solution themselves, having allowed it to 3rd parties, particularly since I do it for Apple owned FileMaker that runs on Windows just fine but is always broken by MacOS upgrades.
Yes, I know you meant “on Linux” :).
When I did FileMaker stuff, Apple seemed OK, but Windows was borked.
Haven't used it since Version 12 though (multiuser was starting to look too expensive for my customers). I don't use it at all now - The last job with it (in 2015) was to export some historical data to SQL Server from FileMaker 6!
Good luck to them ever getting it to work for ARM, even if real non-Apple ARM PCs ever become a thing. They would have to emulate Apple's proprietary GPU, which would require a lot of reverse engineering since it won't be fully documented to the level required to virtualize it on someone else's GPU.
Technically if you owned an Apple (that you don't use) capable of running the version OSX you're running in a Linux VM, you could argue that whilst it was a breach of contract to run that VM, Apple couldn't argue that there was any monetary harm in that breach of contract.
This legal advice is almost certainly worth less than you paid for it.
Virtualization isn't always about dodging the license. Apple dropped support for my 2008 MacBook after 10.7. As in, the OS installer reports that my hardware isn't supported and will not proceed.
It dual-booted into Windows. Now, I single-boot into Windows and then load newer OSX inside VMWare.
It's stupid, but legal. And it's the only way I can run a supported MacOS on this Mac.
Works for me, and does seem faster. Time to a "working" Windows 10 2004 desktop ~10 seconds from a cold start (2019 iMac Retina 4K, 16GB RAM, SSD).
Not that I use it much, but it's handy when I want to run old shrink-wrap that I have written on DOS, Windows 2000, XP etc. Devuan is OK (install it as Debian) although these days when I'm doing UNIXy stuff I tend to use the Mac Terminal. I learnt *NIX in the 70s, and as the mind is going a bit, I can remember it - Linux and Windows 10 "not so much".