Actually, you wouldn't need a 4th axis.
If you mounted the lathe under the X-Carve so that the ways were parallel to the X-Axis and directly under the gantry, then the spindle would only need to move in X and Z. The rotation of the headstock would replace all Y axis motion. Drive the chuck with a stepper, and you could connect that stepper to the Y-axis driver of your 3-axis system.
The X-axis would move the spindle along the workpiece, the Y-axis would rotate the workpiece, and the Z-axis would move the spindle in and out (or up/down if you prefer) . Look at this short YT video:
and imagine the spindle mounted above the lathe moving left/right (X) and up/down (Z) instead of behind it, moving left/right (X) and fore/aft (Y) as shown here. Either way, still only three axes of motion.
For an X-Carve modification, you'd simply have to reconnect (or devise a clever 4-pole switching system) the Y-axis to the lathe stepper. You'd also need a way to securely lock the gantry in place over the centerline of the lathe,
Edited to add: CAM would be an interesting challenge...