Recoil-induced dissociation in hard-x-ray photoionization