It would seem that a microbiologist would be able to replicate the gut flora and put it into a pill or milkshake and leave the fecal matter out.
Scientists are definitely working on it. I just finished reading “Gulp: Adventures on the Alimentary Canal” by Mary Roach. She covers a whole chapter on the subject of poop transplants in a funny but informative way. The whole book is funny but informative, considering the subject matter.