Imam-ul Haq was 25 not out and Mohammad Hafeez was eight not out were at the crease.
Root’s 124 in England’s second innings also played a key role in the 57-run victory and earned him the man-of-the-match award.
India play four Tests and three one-day internationals from early December, with three Twenty20s before that, starting in Brisbane on Wednesday.
England needed just 30 minutes on the fifth day to take the final three wickets with Leach fittingly getting last man Malinda Pushpakmura caught and bowled to set off celebrations.
India, last year's World Cup runners-up, topped Group B after four straight wins and will face either England or reigning champions and hosts West Indies in the semifinals.
Boult's 4-54 derailed the Pakistani batsmen who were bowled out for 227 in response New Zealand's first innings total of 153.
Moeen Ali trapped Mathews lbw in the first over after tea to end the senior batsman's solid resistance that had kept alive Sri Lanka's hopes of chasing down a target of 301.
The South Africans easily protected their 108 for six total off 10 overs to restrict Australia to 87 for seven with Morris the star of the Proteas bowling attack.
Pakistan, resuming at 59-2, were dismissed for 227 in their first innings.
The hosts were 93 for three at lunch, still needing 208 runs to win the game after having bowled out England for 346 in their second innings.
Pakistan need 94 more to take a lead and enforce a 1-0 lead in the three-match series.
England reached 324 for nine - a second innings lead of 278 - when bad light stopped play for the day at Kandy.
Last year's World Cup runners-up went into the game knowing victory would secure a last-four spot after previous wins over New Zealand and Pakistan.
Both Smith and Warner were barred from participating in the lucrative league this season after their involvement in a ball tampering scandal.
Abbas, who made his debut last year, has 59 wickets from his first 10 Tests and will be backed by the spin duo of Yasir and Bilal Asif in the first Test starting Friday.