On Wed, 22 Apr 2009 20:50:51 +0200, Christian Heimes <li...@cheimes.de> wrote:
Jean-Paul Calderone wrote:
I'm not sure what the easiest way to determine whether Python has found
gethostbyname_r or not on your system is.  The configure script used to
build Python will probably tell, but I doubt you have that lying around.
You could just assume this is the case, since you're observing behavior
consistent with it. ;)

This works on every Unix-like system:

import distutils.sysconfig
distutils.sysconfig.get_config_var("HAVE_GETHOSTBYNAME_R")
1


Cool, I thought there was some sysconfig-related approach.  Thanks for
pointing out what it is.

Jean-Paul
--
http://mail.python.org/mailman/listinfo/python-list

Reply via email to