The idea is simple, plug all ground/mass conection together and stereo right and left signal to mono one.
To connect the stereo source to a computer with a homemade port, i.e.
ZX Spectrum +2A or
Commodore 64's tape unit, I make a cable with two male connectors, one stéreo and another mono, like this:
But If I want to make an adapter to an
Amstrad CPC6128 or
MSX tape cable the connections will be the same but mono connector will be female.
If I want to record in tape I need to this cable two times.
Also I can make a specific adapter for new smartphones (CTIA connection) or for my raspberry. At this cases we change the male stereo connector for an 4 contacts jack where most external connection will not be connecter (MIC or Video signal), ground will be the next connection.
If you use a very old mobile (OMTP connection), ground and MIC are swapped.