Hardware wise
Xbox > PS2 > Gamecube > Dreamcast
Dreamcast is only last because it was so early (1998). Gamecube is actually not that great when you learn about its bottlenecks and the fact third party ports were actually pretty bad on it. The PS2 had weaknesses as well but its advantages like the insane fill rate for effects gave it an advantage, and third parties often made the system their priority.
Library
PS2 > Xbox > Dreamcast > Gamecube
PS2 wins hands down for variety alone. The "le shovelware machine" is a cope often spouted by tendies who can't understand economics, i.e. the most popular system will have third rate devs cashing in on it for a quick buck. If you were past the first grade and could read game sites and magazines, you knew what games to buy and what third party shovelware to avoid.