In MTB land I run 7,8 and 9 speed cassette+shifters combos with the same 8 speed Shimano Derailleur. 10-speed is another realm, though.
In roadie land, I swap out Sachs, Sram and Shimano 7-speed cassettes/freewheels on a bike with the same 7-speed shifters and derailleurs.
If running 6,7,8,9 speed MTB stuff, only a few tricky combos you have to worry about, really. You just gotta know that Sram MTB rear derailleurs require numbered Sram shifters and that solves well over half your problems right there.
You can also actuate 7/8/9 speed Shimano road rear derailleurs across shimano or Sram 7/8/9 speed cassettes with Shimano brifters that match the cassette gear count no problemo. They won't do so well with MTB front derailleur/crankset, though.
I think there are far more feasible matches than there are of auto engine/transmission combos from the 90s and aughts.