so you want to put a sohc 4.0 in front of your 5 speed?
It can be done as the 4.0 ohv and sohc are the same block and bellhousing (for the most part)
However i would NEVER install a 1998 sohc engine into anything.
the SOHC was built 1997-2014 the 97 and 98 versions are weak sauce compared to later years. If you do this conversion you would want to get a late4r model sohc engine, by 2004 or so they were very tough
this is a very involved swap, going from ohv to sohc can be done several different ways including keeping your ohv computer and modding the engine wiring, or youc an swap over to a complete sohc computer and wiring harness, you would want to find a 5 speed sohc. To do this using an auto computer you would then need a tune
the sohc engine can be made to bolt up you can even use your ohv flywheel and clutch setup
Most of us here would prefer to keep the pushrod 4.0 as they are basically half million mile engines in the right hands