Teck has announced it has agreed to sell its steelmaking coal business, Elk Valley Resources, to Glencore.