labstreaminglayer / pylsl

Python bindings (pylsl) for liblsl
MIT License
136 stars 57 forks source link

lib-finding code should search package/lib first before searching system PATH #37

Closed cboulay closed 3 years ago

cboulay commented 3 years ago

The lib finding code iterates through all possible combinations of library naming schemes. For each prefix-suffix combination, it first attempts the local dir then it attempts the system paths before moving on to the next combination.

I think this is the reason why more errors were reporting DLL errors with pylsl recently: it was finding old liblsl(32|64).dll on the PATH before it reached the correct naming scheme for the dll that's in the package/lib dir.

This should be changed so that it first searches through all combinations in the package/lib dir, then if that fails it searches at the system level. This requires a small refactor to so as to not duplicate the search code.

If someone else is in the mood to do that then you are more than welcome. Otherwise I'll add it to my lossy queue.

cboulay commented 3 years ago

Fixed in ba94136aa905e7cab8efdd3e12d7758083adcb83