in reply to Cleansing and stacking arguments before calling system()
I guess you can do this job by playing some tricks with Getopt::Long. It will even give you some error checking. But I'm not sure if it is the right tool.