Leaders from 175 countries have signed the Paris agreement on climate change at the United Nations in New York City.