Releasing software for OSX is annoying.
I kind of want to go down the “here is a totally unsupported and untested package” route, just because I can and it would probably be fine. I don’t want to have to boot into OSX and actually test it as part of my release process because it’s already annoying having to do both Windows and Linux and I can do both at the same time with my desktop/laptop.
But even that is a nightmare, because OSX is extremely hard to get working in a VM and I can’t do it. Also it’s illegal.
So you can cross compile. Clang supports cross compilation out of the box so it’s less annoying than you might expect, but you still have to get all the headers/libs from an OSX machine, and then you have to install the LLVM linker which for some reason is packaged separately, and then that might be illegal too but I haven’t read the EULA.
Building an installer package is more difficult. .pkgs uses a stupid format called XAR (I don’t know if it’s actually bad but WTF even if it was good you have to use zip or tar because everything supports those and does not support xar) so you have to download some Github project (maybe 7z can do it but it gives a scary warning trying to list the .pkg I built on OSX).
Inside the .pkg there are three files. There’s a file called PackageInfo, which is some XML and looks easy enough to generate. There’s a file called Bom which is some binary manifest, and you need to download another Github project to generate that. The last file is called Payload, which is another stupid archive format (cpio, which 7z seems ok with) + gzip, and contains the folder you pointed pkgbuild at.
I feel like I could probably get cross compilation and the .pkg stuff working but it would take ages and be boring so I’m not going to.
ADDENDUM: apparently you can jailbreak Apple TVs. Would be pretty funny to run OSX builds (it’s cross-arch but not cross-OS so it’s probably simpler) on the Apple equivalent of a Raspberry Pi. Of course I haven’t tried it and I’m not going to but it amuses me that it might be possible.
The other major annoyance is that OSX doesn’t support GL past 4.1, which means you miss out on:
glTexStorage2D, which lets you allocate immutable textures with space for mipmaps in a single call
I’m actually only really upset about losing clip control, because you need that to do massive draw distances. The rest I can either live without (compute, BPTC, explicit uniforms) or are pretty simple to conditionally support, so it’s not the end of the world but it is annoying. I also don’t really understand why Apple wants to push Metal like this, if I ever write a second render backend it’s obviously going to be D3D and not Metal.