Check for sys/signal.h and/or signal.h

mingw-w64 does not actually have sys/signal.h, while OSX currently has a
broken signal.h
Better check the presence of both and use sys/signal.h if present, else
signal.h
Merge branch 'mingw-signal' of https://github.com/nmaier/aria2 into nmaier-mingw-signal
Do changes in 8aa1db6 in other places which include signal.h