''Shoaib has been ruled out of action for at least two weeks with a grade one hamstring tear and has also developed fluid in his knee,'' Saleem Altaf, Pakistan's director of cricket operations told Reuters.
Shoaib played his first test in 11 months at Port Elizabeth last week and took four wickets in South Africa's first innings but the injury prevented him from bowling in the second innings.
Altaf said Gul had sustained an ankle injury which had not healed completely.
''Both the players would be examined by a medical commission when they return home,'' he said.
He said it was unlikely they would be available for the One-day series in South Africa next month.
Altaf also said team manager Talat Ali had held a disciplinary hearing after television cameras captured Shoaib in an altercation with coach Bob Woolmer in the dressing room before the start of play on the second day on Saturday.
''The manager has taken appropriate action and Akhtar has been fined,'' he added.
He said the selectors would decide if any replacements would be sent to South Africa.
Shoaib was cleared of a doping offence last month.