They can boil old nasty "gray water", or they can make a desalinator and remove the salt which works kinda like a moonshine still by boiling the water and then cooling the steam down and out the other end comes fresh water, or they can catch rain water.