Here's a better patch. I check if there is any declaration at all,
which ancient HPUX should fail based on:
command.c:5062:4: warning: implicit declaration of function 'sigwait'
Then I also check that there isn't an incompatible declaration with
the technique from thread_test.c, which Solaris should fail, based on:
command.c:5062:8: error: too many arguments to function 'sigwait'
A well placed -D_POSIX_PTHREAD_SEMANTICS might allow it work on
Solaris, but I'm not sure if it's OK to do that without other
threading options and I don't have access to test.