A little pumpkin (pure pack, not spiced-and-sugared pie filling) should help short-term. He's small so I'd start him out with maybe half a teaspoon. Pumpkin has lots of fiber in it to get him 'going' again and most dogs seem to like the taste.
Long-term, you might want to find a food that suits his tummy better. What are you feeding him now?
ETA: He's not vomiting as well, is he? Does he seem lethargic? And is he drinking water?
"We are--each of us--dying; it's how we live in the meantime that makes the difference."
"It's not what you gather, but what you scatter that tells what kind of life you have lived!"
"Be kinder than necessary, for everyone you meet is fighting some kind of battle."