I'd say start off with the wrapper, once you have added an extra layer of abstraction it makes it easier to start changing things underneath. Assuming the wrapper is written well as a interface you should be able to change the implementation of it underneath without impacting any code that uses the wrapper.
So you can mix the use of old code and new code by migrating each sub as you go. So you will end up with a pure perl implementation of your wrapper, the orginal system call implementation and probably a mixed one along the way as well.
sometimes this is called programming by contract, your wrapper forms the contract that states what your implementation has to do. |