A few reasons:
- It's look, particularly the controller, gave people the vibe of a Fisher price toy, giving it a reputation as "PS2 for kids", and no kid wants something "for kids", they want the "cool" system that the grownups have, hence they ask their parents for a PS2 instead.
- Games like Sunshine and Wind Waker also came across as catering too hard to small children, and failed to live up to what a lot of Nintendo fans wanted coming after the likes of the epic Mario 64 and Ocarina of Time.
- PS2 had a head start and as a result by the time Gamecube came out its rival had gathered too much momentum and become the default system of choice, hence sucking the wind out of GC's sales. (heh)
- It lacked DVD playback at a time when this was a hot feature.
- Games like Viewtiful Joe and Baiten Katos were niche, while GC lacked a lot of mainstream heavy hitters like GTA.
All very good, perfectly valid reasons. I remember that, during that specific era, the "Nintendo is for kids" mantra was on full display. Even Kaz Hirai was saying it in interviews! Once Wii arrived, it changed from "Nintendo is for kids" to "Nintendo is for casuals." I, personally, never saw it but you are totally right: it did have gaping holes in the library, especially after taking into account how deep the PS2 library was.
I always thought that the lack of any sort of multi-media functionality was a mistake, on their part, as well. I also remember thinking that Sony making PS2 backwards compatible was a brilliant idea, and that they would likely be the only hardware manufacturer to do so.
Out of the four consoles-Dreamcast, PS2, Gamecube, and Xbox-I found the Gamecube controller to be the most comfortable, for some reason.