The Perl 5 module IPC::Signal provides functions to deal with signals.