configure: Improve test for posix_spawn