EU::MM custom Makefile actions

Randy J. Ray rjray at
Mon Oct 1 20:17:30 BST 2007

David Cantrell wrote:
> I need to customise my Makefile.PL so that 'make clean' will, as well as
> doing its usual thang, also delete some extra files that get created
> when you run 'perl Makefile.PL'.  How do I do that?

When you call WriteMakefile(), add a new key/value pair:

               clean => { files => $extra },

The value of "$extra" should be space-separated names. This is appended to the 
"rm" command directly, so you can use shell wildcards, etc.

Randy J. Ray        Sunnyvale, CA   rjray at

Silicon Valley Scale Modelers:

More information about the mailing list