Why did the USA fight for freedom against the British, Hitler, North Korea, and Saddam if America just ended up as a police state?

All those American soldiers died in vain.