Date: Sun, 16 Feb 2003 14:13:15 -0800 From: "Ronald F. Guilmette" <rfg@monkeys.com> To: freebsd-questions@freebsd.org Subject: gethostbyaddr_r ? Message-ID: <93311.1045433595@monkeys.com>
next in thread | raw e-mail | index | archive | help
Assume that I want to write a program that uses ``real'' threads, i.e. independently schedulable ones. First question: Are there any good tutorials around for how to do this under FreeBSD? (I've never actually done this before.) I gather that the Right Thing To Do is to compile and install the linuxthreads package, yes? What, if anything, do I need to set in my kernel config file in order to make sure that the kernel support (for rfork?) is present? Anything? OK, well, anyway, assuming that I can get past all of THAT stuff, can somebody please tell me (a) which library I should obtain a proper `gethostbyaddr_p' function from and (b) where I might find the relevant man page for that? It seems that there are at least three diferent libraries that I might be able to get a `gethostbyaddr_r' function from, i.e.: From the system C library (libc). From libbind.a (as supplied with the bind 8.3.4 distribution). Perhaps also from the linuxthreads package (?) Ok, so which one is the Right One To Use, and where man I find its man page? NOTE: I looked already at the source code for the gethostbyaddr_r function supplied as part of the bind 8.3.4 distribution, and it looks to me like that one is just _pretending_ to be reentrant... I appears that it just calls the normal (non-reentrant) gethostbyaddr function. THAT'S obviously not useful to me if I want to write a real multi-threaded program, right? And anyway, I can't find any man page in the bind distribution that even describes the ISC version of gethostbyaddr_r. (Humph!) Now there _does_ seem to be a gethostbyaddr_r function in the FreeBSD 4.7 libc.a library, however... % man gethostbyaddr_r No manual entry for gethostbyaddr_r Bummer! I hit the same (documentation) wall again. Can anybody tell me where the FreeBSD/libc version of this function is documented? Any help would be appreciated. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?93311.1045433595>