Re: [pypy-dev] r55005 - in pypy/branch/win32port/pypy: lib lib/_ctypes module/_rawffi module/_rawffi/test rlib rlib/test
afa@codespeak.net schrieb:
Author: afa Date: Tue May 20 16:17:22 2008 New Revision: 55005
Modified: pypy/branch/win32port/pypy/lib/_ctypes/builtin.py pypy/branch/win32port/pypy/lib/msvcrt.py pypy/branch/win32port/pypy/module/_rawffi/__init__.py pypy/branch/win32port/pypy/module/_rawffi/interp_rawffi.py pypy/branch/win32port/pypy/module/_rawffi/test/test__rawffi.py pypy/branch/win32port/pypy/rlib/libffi.py pypy/branch/win32port/pypy/rlib/rwin32.py pypy/branch/win32port/pypy/rlib/test/test_libffi.py Log: Maciej was right: it's better to dynamically get the name of the msvcrt library: the same generated sources may be recompiled, e.g. in debug mode.
I hope I got it right: in pypy-c.exe, we compile a function that retrieves the dll containing the "fopen" pointer address.
Hardcoded "libc.so.6" on posix platforms. There must be a better way.
May be that dl_iterate_phdr(3) can help? Thomas
Thomas Heller wrote:
Hardcoded "libc.so.6" on posix platforms. There must be a better way.
May be that dl_iterate_phdr(3) can help?
But, from the man page: "The dl_iterate_phdr() function is Linux-specific and should be avoided in portable applications." -Scott -- Scott Dial scott@scottdial.com scodial@cs.indiana.edu
participants (2)
-
Scott Dial
-
Thomas Heller