Michael Felt added the comment:
Actually, what may be needed are more "@skip" blocks - as ctypes has always
been platform dependent.
OR - have a counter or boolean that starts as zero or false and increase each
time find_library() returns a value - and the test fails if the counter is
still zero, or boolean is still false.
Further, perhaps a separate test_load() that is platform specific - with the
correct - read expected - result from find_library(). I say expected because
python has always been testing for libc.so.6 while I see in cloud-init that
that are calls hard-coded to CDLL("libc.so.7") - but maybe that is something
specific for Canonical aka ubuntu.
However, it seems that expecting libc.so.6 to ALWAYS be present is not safe.
FYI:
michael@x071:[/data/prj/python/cloud-init]grep CDLL cloud-init-0*/cloudinit/*.py
cloud-init-0.7.5/cloudinit/util.py: libc =
ctypes.CDLL('/lib/libc.so.7')
cloud-init-0.7.8/cloudinit/util.py: libc =
ctypes.CDLL('/lib/libc.so.7')
----------
_______________________________________
Python tracker <[email protected]>
<http://bugs.python.org/issue28276>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe:
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com