Enhance signal handler responsiveness, support SIGTERM and SIGSTOP

This branch addresses several related issues about signal handling.

1/ Handling of SIGINT was not responsive when executing short commands.
2/ Hitting Ctrl-Z only suspended ninja but not its children.
3/ SIGTERM was not handled.