Teck Resources Ltd. held on-and-off talks about a combination with Vale SA’s base metals unit before agreeing to merge with Anglo American Plc, according to people familiar with the matter.