Your Princess Is In Another Castle
Origin: Super Mario Bros.
Mario goes through a lot for the woman he loves. Jumping over a bunch of stuff, hitting other stuff with his head, and then finally beating the king of all the stuff in the kingdom.
Needless to say, it's more than a little frustrating to get to what you think is the end of a game, onlyto find out the princess you'd been intent on saving was actually a little mushroom lackie all along.
The phrase made it's way around the internet as an expression of disappointment after chasing a seemingly wonderful goal.