I'm told the two motors are basically identical. All auxiliaries are different, though. Intake manifold, wiring harness, EWS system, knock sensors, belt drive, engine mount arms, etc. IIRC the later M42 also went to one coolant temp sender vs. two for the E30.
IMHO swap the stripped block into the E30 - use the E30 intake, wiring harness, belt pulleys, etc. You'll need a pilot bearing for the crank too (automatics don't have a flywheel) and you might as well do the clutch with a non-a/c (single mass) flywheel while you're in there.