configure.ac: Don't let pthread check depend on OS

Don't check the operating system environment to detect the correct
linker flags for using the POSIX thread library.