Since Emacs version 19 patchlevel 22 or so, there have been both a perl-mode.el and support for the Perl debugger built in. These should come with the standard Emacs 19 distribution.
Note that the perl-mode of emacs will have fits with "main'foo"
(single quote), and mess up the indentation and highlighting. You are probably using **"main::foo"**
in new Perl code anyway, so this shouldn't be an issue.
For CPerlMode, see http://www.emacswiki.org/cgi-bin/wiki/CPerlMode