[issue3383] ctypes.util fails to find libc in some environments

Jean-Paul Calderone report at bugs.python.org
Wed Jul 16 20:31:53 CEST 2008


New submission from Jean-Paul Calderone <exarkun at divmod.com>:

ctypes.util assumes several things of its environment which sometimes
don't hold:

  * It depends on objdump being in $PATH.  If it isn't, it will fail to
read the SONAME from a library, even if it has determined the path to it.
  * If it uses ldconfig (which, unlike objdumb, it assumes it knows the
full path to and doesn't rely on $PATH to find), it fails to interpret
the results because the regular expression it applies doesn't define any
groups.

The attached patch is what I used to work around these issues in one
particular environment.  I don't claim the fixes to be general, and the
patch includes no unit tests.

----------
assignee: theller
components: ctypes
files: ctypes-util.patch
keywords: patch
messages: 69814
nosy: exarkun, theller
severity: normal
status: open
title: ctypes.util fails to find libc in some environments
versions: Python 2.5
Added file: http://bugs.python.org/file10910/ctypes-util.patch

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue3383>
_______________________________________


More information about the Python-bugs-list mailing list