While I can't answer for the '97 Sport 3.5L, I can tell you there is a fair amount of difference between my '03 Montero Sport 3.5L 6G74 and my '02 Montero Limited 3.5L 6G74.
-Oil filter/pump on the other side of the engine
-Timing belt tensioner and setup is different, and sets in a different "direction"
-Accessory cradle is different on the front. (Montero for example doesn't require removal of power steering or A/C compressor to service timing belt, Sport does.
-Coolant crossover piping is different. (of course this is an accessory).
-Water pump different
That's all I can think of on short notice.
As far as computer controls go, if you use the Gen 3 electronics, harness, fuel injectors, intake, (everything), and just the long block, no electronics, from the donor engine, I imagine all should be well? (I've done this on different year/electronics in other vehicles successfully).
I bought a parts car twin to my wife's '03 Sport Limited, bragging about having a spare engine for either of our trucks, only to discover all is not equal. I've not researched enough to see if the oil pump setup can be moved to the other side, (Sport/vs Montero), but the prospect of having to fool with it was enough for me to scratch the idea, and be happy with a spare motor and transmission in "stock" for just my wife's Sport.
Here's a brief discussion:
Surprise surprise...
Alternatively, you could just jump on a plane, plan a road trip: funny, this one doesn't have a power moonroof?
'05 Montero Limited