The left-arm pacer left the field in discomfort on the first day of the Test on Friday but returned on Saturday and completed 19.3 overs in the first innings of the match.
The Pakistan Cricket Board (PCB) said the 25-year-old went for an MRI scan and was advised to rest for two to three weeks, which means he will also take no further part in the second Test that Pakistan need to win to level the two-match series.
A PCB statement said: “Amir has been ruled out of the ODI series against Sri Lanka due to a stress-related injury in the right shin.
“The fast bowler has been advised two to three weeks rest after he underwent an MRI scan.
“The fast bowler will not bowl in the ongoing Test match at the Dubai Cricket Stadium but would be available to bat.”
Pakistan’s ODI series against Sri Lanka gets underway in Dubai on Friday.