A 94 YJ with a 4.0 would have a AX-15 not a AX-5(AX-5 was used in 4 bangers).  Now the bad news, I had the same problem with my YJ.  5th Gear is known for splitting and sticking it self on the shifter rail.  Mine stuck in 3rd gear, but same idea.  I pulled mine out myself and took it to a shop.  It cost me $350 to have it fixed, but that was back in 2002 and in South Carolina.  Another option would be to look for a working AX-15, try car-parts.com  .  Anything from 92-99 should work, but don't quote me on that.  If he decides to fix it, have him call around for quotes.  I was quoted $1500 for AAMCO, and the smalled the shop, the lower the price.  Granted I didn't get a nationwide guarntee, but at the time my Jeep was 10 years old, and I could replace 5th gear many times for $350.  Since the repair, no problems.  One other thing to consider is that the fluid for the AX-15 is $$$.  I forget what it is called off the top of my head, but it is rare.  The Jeep dealer sells it for like $8 a quart, but a Chevy dealer sells it for $6.  I found Redline Full Synthethic for $6 a quart.  It takes 5 quarts so its not a cheap item.