A small homemade bomb has been detonated near a church in the Egyptian capital Cairo with no casualties reported, an Egyptian security official said.