Buy some threaded bar the same thread as the fixing bolts, cut it into lengths of about 6 inches and put these into the back of the block so you can slide the gearbox back in place, in a controlled manner. Once in place, replace each stud in turn, with the correct fixing and fully fix.