Skip to content

v0.7.10a1 breaks library loading on linux #11

@kiwec

Description

@kiwec

I'm using void linux, but this probably happens on other distros.

https://github.com/Zuzu-Typ/PyOpenAL/blob/master/openal/library_loader.py#L54

Basically, os.path.realname prepends the current directory to libopenal.so, which stops it from loading since that file doesn't exist.

>>> ctypes.CDLL(ctypes.util.find_library('openal'))
<CDLL 'libopenal.so', handle 55bd434836a0 at 0x7f317de76ba8>

>> ctypes.CDLL(os.path.realpath(ctypes.util.find_library('openal')))
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/usr/lib/python3.6/ctypes/__init__.py", line 348, in __init__
    self._handle = _dlopen(self._name, mode)
OSError: /whatever/is/the/current/directory/libopenal.so: cannot open shared object file: No such file or directory

Metadata

Metadata

Assignees

Labels

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions