KANDAHAR - Afghanistan Tuesday welcomed President Donald Trump’s speech clearing the way for thousands more US troops to be deployed in the country, backtracking on his election promise rapidly to quit America’s longest war.

In a speech to troops in southern Kandahar, birthplace of the Taliban, President Ashraf Ghani said Trump’s first formal address as commander-in-chief late Monday showed that America was “with us, without any time limit”.

“You cannot win this war,” Ghani told the Taliban, calling on them to join talks and saying that Afghanistan wants peace with neighbouring Pakistan, long accused of fuelling the insurgency.

“We want peace from Pakistan, they cannot provide safe havens to anyone anymore,” Ghani said in Kandahar. But ahead of the speech Pakistan’s military insisted the country has done all it can to tackle militancy.

Trump for the first time also left the door open to an eventual political deal with the Taliban. “Someday, after an effective military effort, perhaps it will be possible to have a political settlement that includes elements of the Taliban in Afghanistan,” he said.

“But nobody knows if or when that will ever happen,” he added, before vowing that “America will continue its support for the Afghan government and military as they confront the Taliban in the field”. His Secretary of State Rex Tillerson went further, saying the United States would “stand ready to support peace talks between the Afghan government and the Taliban without preconditions”.

The Trump administration had originally promised a new Afghan plan by mid-July, but Trump was said to be dissatisfied by initial proposals to deploy a few thousand more troops.