Support GC_init (and get_stack_base) from non-main thread on FreeBSD
Issue #180 (bdwgc).
Now GC_get_[main_]stack_base uses pthread_attr_get_np() and
pthread_attr_getstack() to determine the stack base address.
* os_dep.c [FREEBSD && !NO_PTHREAD_ATTR_GET_NP && (THREADS
|| USE_GET_STACKBASE_FOR_MAIN)]: Include pthread.h and pthread_np.h.
* os_dep.c [FREEBSD && !NO_PTHREAD_ATTR_GET_NP
&& (USE_GET_STACKBASE_FOR_MAIN || THREADS && !REDIRECT_MALLOC)]
(GC_get_main_stack_base): Call pthread_attr_init, pthread_attr_get_np
and pthread_attr_getstack to determine the stack base address of the
current thread (fall back to GC_freebsd_main_stack_base in case of
failure).
* os_dep.c [(GC_FREEBSD_THREADS && !NO_PTHREAD_ATTR_GET_NP]
(GC_get_stack_base): Call pthread_attr_init, pthread_attr_get_np and
pthread_attr_getstack to determine the stack base address of the
current thread.