If you can only have one firearm is has to be a .22 rifle. If you can have 2, add a .223. 4 bricks of .22lr easily fit into my bugout bag and could harvest 2000 meals for you, provide protection, and be used for barter. Small game is much easier to bring to table than deer, but my friends grandfather who lived in northern Wisconsin in the '30s fed his family with deer he poached using only a .22 rifle and a couple of handfuls of .22s.
Unless you are defending/living in a fixed location IMHO a shotgun and its ammo is far to heavy to consider. One 12ga high brass shell weights almost at much as one BOX of .22lr! Survival mandates that any game you take is shot on the ground, or on the water, to save ammo and to bring a sure meal to the table.