Dynamic libraries (*.dylib) files are added to the app bundle with in the Frameworks folder.
When these are linked from other binary code this works fine, but when using ctypes.find_library() it doesn't work, since the library can't be found.
According to the ctypes code (python 2.7) the following environment variables are checked (for non-frameworks) DYLD_LIBRARY_PATH, DYLD_FALLBACK_LIBRARY_PATH
So the solution would probably be to append the app bundle's Framework path to one of these.
Of course, the workaround is to patch the python code using ctypes to also look in
../Frameworks. It would be much better if that wouldn't be necessary though.
The issue came up here: https://github.com/JonnyJD/python-discid/pull/42 (and has a workaround implemented)