Your question is question is a bit more tricky than just saying what is the memory needed to run games on those OS versions. Basically, you should be looking at what hardware you want to run those OS on. For example, I had a Toshiba laptop at one time, that ran Windows 98. And while some computers could use 64 MB on Win98 for games just fine, this laptop maxed on the pentium class system at 40 MB. You also have caching issues to deal with.
If you are asking, "what is the most you could ever need to run any game of that era?", that is also tricky. Win95 was still being used to run new DOS game releases, but also highly overlaps with Win98, in that compatibility of games between both is almost identical. Again, it really depends on the hardware you want to run more than OS. And Win95/Win98 kind of cuts into WinXP era too, as games were made could run pretty much ran on all of it. (I ran Win95 until around WinXP was released, it was pretty evident HW is key)
I'm unsure if you mean baseline as, "all you need to get by?", I think minimum is obvious on the OS box and game box. But as for a maximum memory for games that you'd likely never go past (again truly based on hardware if this makes any sense), I'd say this:
DOS - 8MB (you could build bigger DOS systems, but compatibility issues with later hardware and DOS games can be an issue for you)
Win95/98 - 256MB (the high end amount...exact amount possible varies more -- might need to install patches -- running win95 is not much point if you can run win98 )
WinXP - 2GB (pretty much up to the limits of 32-bit systems, but higher options are around, if not really needed)
Then again, you can try building a system that covers alot of games, but depending on the game, playing it on too new of hardware might not satisfy you.