fix checking for aspell; add checking for qsort_r; switch to GNU checking for gethostbyname_r