Emulation these days is well supported for loads of systems, and I understand that original Game Boy and Game Boy Colour are comparatively simple to emulate. Retro gaming is also pretty popular at the moment, and so it seems reasonable there is demand for people who want to emulate link cable sessions over wifi. (Surely me and my friend are not the only people currently playing Pokemon Red and Blue?)
Given how seamless it is to download an emulator and boot up a ROM, I inferred that it would be similarly simple to trade pokemon by Wifi. I was surprised to find out that this seems not to be the case. Retroarch natively supports netplay for local multiplayer, for example on the SNES, but my reading tells me that it doesn't support netplay for Game Boy link cable sessions. Searching "gameboy emulate link cable wifi" in google and youtube gives me a bunch of links for how to set up a link cable by loading two different sessions emulating gameboys at the same time on one machine, for example using TGB dual, but doesn't give me any hits for wifi support. So I'm wondering if there's some obstruction that makes it difficult.
Firstly then, did I make a wrong assumption? (maybe my searching wasn't extensive enough and this is supported somehow, or maybe people are just not interested in this, although I find that hard to believe)
And if I didn't, then my question is: What's the obstruction that makes it difficult to emulate GB/GBC/GBA link cable support by wifi?
I could imagine a setup where, user A has rom RA, with save file SA and user B has rom RB with save file SB. A sets themself up as the server, and B as the client. The emulation session sends RB and SB to A. A emulates two gameboys under the hood, running RA with SA on one and RB with SB on the other. Only the the RA session is displayed to A, and then A sends the sound and audio of the RB session back to B, and polls B for controller inputs. Any time the game is saved A sends SB back over to B, and A deletes their copy of RB and SB at the end of the session.
I'm pretty certain that this setup would require roughly the same coding as the session which runs two gameboys on the same machine to emulate link cable, combined with whatever retroarch does for its SNES netplay. Maybe there is a better solution than this, but implementing what I described seems straightforward and indicates that there probably isn't a technical problem with emulating link cable play, unless it would be too slow in practise? Or maybe there's some kind of legal issue?
[I'm currently disabled and unable to work, and my experience is mostly in scientific programming. I'm not asking anyone to do this, just trying to scope out the problem. Please don't tell me to code it myself]