Certain foods have higher vitamin d concentrations. However those foods are uncommon in the modern diet. For example the marine diet of the Inuit with seal blubber and such.
Ok, but there were also a lot of people without sea access (e.g. caribou herders). How did they live without vitamin D supplements?
There are other foods. But yes rickets was quite common in this area. We learned about it in school.