I would put the three versions as different branches into git (or some other version control system) and use 'git diff' to check for the differences. Merging them would be the final objective. It might even be that merging and resolving the conflicts is all that is needed to integrate the 3 versions, without the need for any preliminary diffs
The merge step would be a bit unusual in that it involves programming, but the merge would practically provide a recipe or path one could follow.