ae.c: set errno when error is not a failing syscall.

In this way the caller is able to perform better error checking or to
use strerror() without the risk of meaningless error messages being
displayed.
Better error reporting when fd event creation fails.
Multiple fixes for EVAL (issue #872).

1) The event handler was no restored after a timeout condition if the
   command was eventually executed with success.
2) The command was not converted to EVAL in case of errors in the middle
   of the execution.
3) Terrible duplication of code without any apparent reason.
Test: added regression for issue #872.
Comment in the call() function clarified a bit.
Makefile.dep updated.
merger with upstream