Only because the government has provided poor alternatives. Is Uber a better allocation of capital than infrastructure projects?
The Government doesn't build the economy, it constrains it (ideally in helpful ways and not harmful ways). You can't lego yourself an economy - or at least nobody has successfully done so yet.
Is that why farms need subsidies to survive? Because the farm owners are really good at allocating capital?
People need food to survive, especially during war. That’s the reason for the subsidies. Without the subsidies, they wouldn’t allocate the capital, and you’d starve when your neighbor state attacked you instead of exporting their food to you.