- Is compatible with most x86 virtual machines
- Can be written to a device (USB stick, cloned to a real HDD, etc.)
- Is mountable in Windows, so I can include it in my build process
Turns out the best fit is the "Virtual Hard Disk" format. In Windows, it's possible to mount VHD files using the management console. But I don't want to go through all the hassle to mount it with a few mouse clicks, build the kernel, unmount it with more mouse clicks, before I can actually test it.
So I made vhdutil, which is available here: https://github.com/dnifan/vhdutil
After building, you can simply use these commands:
vhdutil.exe attach <file> to mount a VHD file.
vhdutil.exe detach <file> to unmount a VHD file.
It's licensed under the MIT license, so go right ahead and do whatever you want.