Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(159090)

#26439: ctypes.util.find_library fails when ldconfig/glibc not available (e.g., AIX)

Can't Edit
Can't Publish+Mail
Start Review
Created:
3 years, 9 months ago by aixtools
Modified:
3 years, 2 months ago
Reviewers:
vadmium+py
CC:
haypo, ned.deily, michael.haubenwallner_ssi-schaefer.com, devnull_psf.upfronthosting.co.za, Martin Panter, dje.gcc_gmail.com, Michael.Felt, aixtools_gmail.com, Mariatta
Visibility:
Public.

Patch Set 1 #

Total comments: 28

Patch Set 2 #

Total comments: 28

Patch Set 3 #

Total comments: 29

Patch Set 4 #

Total comments: 17

Patch Set 5 #

Total comments: 2
Unified diffs Side-by-side diffs Delta from patch set Stats Patch
Lib/ctypes/_aix.py View 1 2 3 4 1 chunk +277 lines, -0 lines 2 comments Download
Lib/ctypes/__init__.py View 1 2 3 4 1 chunk +10 lines, -0 lines 0 comments Download
Lib/ctypes/test/test_loading.py View 1 2 3 4 1 chunk +5 lines, -0 lines 0 comments Download
Lib/ctypes/util.py View 1 2 3 4 6 chunks +35 lines, -17 lines 0 comments Download

Messages

Total messages: 20
Martin Panter
https://bugs.python.org/review/26439/diff/17096/Lib/ctypes/util.py File Lib/ctypes/util.py (right): https://bugs.python.org/review/26439/diff/17096/Lib/ctypes/util.py#newcode87 Lib/ctypes/util.py:87: if sys.platform.startswith('aix'): Should this use “elif”? Otherwise I think ...
3 years, 7 months ago #1
Martin Panter
https://bugs.python.org/review/26439/diff/17096/Lib/ctypes/util.py File Lib/ctypes/util.py (right): https://bugs.python.org/review/26439/diff/17096/Lib/ctypes/util.py#newcode440 Lib/ctypes/util.py:440: print 'aix:find_library("c")' Perhaps you can merge some of this ...
3 years, 7 months ago #2
Martin Panter
https://bugs.python.org/review/26439/diff/17096/Lib/ctypes/__init__.py File Lib/ctypes/__init__.py (right): https://bugs.python.org/review/26439/diff/17096/Lib/ctypes/__init__.py#newcode365 Lib/ctypes/__init__.py:365: mode |= RTLD_MEMBER Indentation is a bit excessive here ...
3 years, 7 months ago #3
aixtools_gmail.com
I expected I would make beginner errors, and I thank you for your patience. Do ...
3 years, 7 months ago #4
Martin Panter
It is probably best to make a new patch that replaces the original, like you ...
3 years, 7 months ago #5
Martin Panter
https://bugs.python.org/review/26439/diff/17194/Lib/ctypes/__init__.py File Lib/ctypes/__init__.py (right): https://bugs.python.org/review/26439/diff/17194/Lib/ctypes/__init__.py#newcode17 Lib/ctypes/__init__.py:17: # RTLD_MEMBER is not in _ctypes (yet), or whereever ...
3 years, 7 months ago #6
aixtools_gmail.com
Will test the changes and update patch. https://bugs.python.org/review/26439/diff/17194/Lib/ctypes/__init__.py File Lib/ctypes/__init__.py (right): https://bugs.python.org/review/26439/diff/17194/Lib/ctypes/__init__.py#newcode17 Lib/ctypes/__init__.py:17: # RTLD_MEMBER ...
3 years, 7 months ago #7
aixtools_gmail.com
https://bugs.python.org/review/26439/diff/17194/Lib/ctypes/aixutil.py File Lib/ctypes/aixutil.py (right): https://bugs.python.org/review/26439/diff/17194/Lib/ctypes/aixutil.py#newcode39 Lib/ctypes/aixutil.py:39: # stderr=_os.devnull, On 2016/05/08 08:08:44, vadmium wrote: > Unfortunately ...
3 years, 7 months ago #8
Martin Panter
https://bugs.python.org/review/26439/diff/17194/Lib/ctypes/__init__.py File Lib/ctypes/__init__.py (right): https://bugs.python.org/review/26439/diff/17194/Lib/ctypes/__init__.py#newcode17 Lib/ctypes/__init__.py:17: # RTLD_MEMBER is not in _ctypes (yet), or whereever ...
3 years, 7 months ago #9
aixtools_gmail.com
still testing, but getting surprising comment from subprocess (better Popen()) via aixutil.py - more comments ...
3 years, 7 months ago #10
aixtools_gmail.com
https://bugs.python.org/review/26439/diff/17194/Lib/ctypes/aixutil.py File Lib/ctypes/aixutil.py (right): https://bugs.python.org/review/26439/diff/17194/Lib/ctypes/aixutil.py#newcode45 Lib/ctypes/aixutil.py:45: p.wait() On 2016/05/08 08:08:44, vadmium wrote: > This is ...
3 years, 7 months ago #11
Martin Panter
https://bugs.python.org/review/26439/diff/17194/Lib/ctypes/__init__.py File Lib/ctypes/__init__.py (right): https://bugs.python.org/review/26439/diff/17194/Lib/ctypes/__init__.py#newcode364 Lib/ctypes/__init__.py:364: if name is None: On 2016/05/09 08:51:12, Michael.Felt wrote: ...
3 years, 7 months ago #12
aixtools_gmail.com
Thought this was already published... One click too few. https://bugs.python.org/review/26439/diff/17194/Lib/ctypes/__init__.py File Lib/ctypes/__init__.py (right): https://bugs.python.org/review/26439/diff/17194/Lib/ctypes/__init__.py#newcode17 Lib/ctypes/__init__.py:17: ...
3 years, 7 months ago #13
Martin Panter
https://bugs.python.org/review/26439/diff/17689/Lib/ctypes/__init__.py File Lib/ctypes/__init__.py (right): https://bugs.python.org/review/26439/diff/17689/Lib/ctypes/__init__.py#newcode359 Lib/ctypes/__init__.py:359: # adding RTLD_NOW is already 'forced' in Modules/_ctypes/callproc.c I ...
3 years, 5 months ago #14
aixtools_gmail.com
Sigh, again had some old comments that stayed as Draft - and a new comment ...
3 years, 3 months ago #15
Martin Panter
https://bugs.python.org/review/26439/diff/18236/Lib/ctypes/__init__.py File Lib/ctypes/__init__.py (right): https://bugs.python.org/review/26439/diff/18236/Lib/ctypes/__init__.py#newcode342 Lib/ctypes/__init__.py:342: When the name contains ".a(" and ends with ")", ...
3 years, 3 months ago #16
aixtools_gmail.com
Will update patch asap. Thank you for your careful (proof) reading! https://bugs.python.org/review/26439/diff/18236/Lib/ctypes/_aix.py File Lib/ctypes/_aix.py (right): ...
3 years, 3 months ago #17
aixtools_gmail.com
re: RTLD_NOW definition. If you feel it is unneeded, remove it. My simple thought is ...
3 years, 3 months ago #18
aixtools_gmail.com
Mostly working, one import too many had me chasing ghosts! http://bugs.python.org/review/26439/diff/18714/Lib/ctypes/_aix.py File Lib/ctypes/_aix.py (right): http://bugs.python.org/review/26439/diff/18714/Lib/ctypes/_aix.py#newcode15 ...
3 years, 2 months ago #19
Martin Panter
3 years, 2 months ago #20
https://bugs.python.org/review/26439/diff/18714/Lib/ctypes/_aix.py
File Lib/ctypes/_aix.py (right):

https://bugs.python.org/review/26439/diff/18714/Lib/ctypes/_aix.py#newcode15
Lib/ctypes/_aix.py:15: from . import util
On 2016/10/04 22:02:10, Michael.Felt wrote:
> This line causes the module to lose it's way, needs to be deleted.
> 
> ../../python util.py ends with:
> Traceback (most recent call last):
>   File "util.py", line 102, in <module>
>     import ctypes._aix as aix
>   File "/data/prj/python/python-3.6.0.177/Lib/ctypes/_aix.py", line 15, in
> <module>
>     from . import util
>   File "/data/prj/python/python-3.6.0.177/Lib/ctypes/util.py", line 102, in
> <module>
>     import ctypes._aix as aix
> AttributeError: module 'ctypes' has no attribute '_aix'

Sorry about that. Your fix of moving _last_version() into a separate common file
is probably as good as any.
Sign in to reply to this message.

RSS Feeds Recent Issues | This issue
This is Rietveld 894c83f36cb7+