[Rpcemu] RPCEmu macOS mouse behaviour

Andrew Hodgkinson ahodgkin at riscosopen.org
Wed Mar 18 02:00:18 PDT 2020

Hi, I've a curious issue with RPCEmu on macOS X (10.14.6) and wonder if anyone has any ideas.

I have two builds, which are *binary identical* except for the main executable's Mach-O UUID and a small part of a plain text string where it looks like some kind of "about" message is having today's date dynamically inserted during building.

One application was built a while ago, the other recently. When I run the old one, mouse pointer movement is fine. When I run the new, mouse pointer movement only works in "follow host" mode. In capture mode (and thus in full screen too), the mouse is unusable - the pointer jumps around all over the place.

The binaries in question are dynamically linking to the same libraries - they're bit-identical but for the UUID and small amount of text as noted. I tried patching the faulty library to see what would happen. All I did first was copy over the 16 UUID bytes from the working copy, to the errant newer copy. That was enough; the newer copy's mouse starts to work. Undo the change; broken mouse. Redo the change; working mouse.

This sounds kinda like crazy talk, yet that's what is happening. FWIW, the working UUID is 5B4AC336-1C1F-3897-88E1-0836AF1DE484 and the broken UUID is - well - anything else.

The UUID shouldn't be used for anything functional at all surely, so how come these otherwise identical binaries behave so differently based on just this thing alone? Some hidden preference/setting somewhere that Mac OS has keyed into the UUID? All configuration data etc. is (obviously) the same (since the application bundles *appear to be* bit-for-bit identical except as noted). Mach-O linker cache of some kind maybe?

Even stranger, a colleague is having issues with Linux behaving the same way. Only the "follow host" mouse mode works. No Mach-O binary UUIDs there :-) so it might be a totally different issue, or perhaps it's actually the same root cause; something in the config or build, which I just can't fathom. Another build for Windows runs fine. Qt library versions don't seem to matter much. The working Windows 7 and 10 builds are on 5.9.5, the non-working Linux build uses 5.9.8 and the Mac builds I have are both dynamically linking against Homebrew-installed 5.14.1, which means it both works and doesn't work on that version. Again, the only thing that seems to fix it is the UUID burned into the binary.


TIA! :-)

Andrew Hodgkinson
RISC OS Open Limited

More information about the RPCEmu mailing list