Add perl REPL support

This works as long as the client has "re.pl" installed (which is the default for me in Linux; I'm not entirely sure whether this works the same for Macs).

I'm not certain that the use of the "magic word" package_base is entirely appropriate; I'm far from a python ninja.  Feedback welcome!