--- openslide/lowlevel.py.orig 2016-06-12 00:26:33.183561713 -0500
+++ openslide/lowlevel.py 2016-06-12 00:26:36.116565929 -0500
if platform.system() == 'Windows':
_lib = cdll.LoadLibrary('libopenslide-0.dll')
elif platform.system() == 'Darwin':
- _lib = cdll.LoadLibrary('libopenslide.0.dylib')
- # MacPorts doesn't add itself to the dyld search path, but
- # does add itself to the find_library() search path
- # (DEFAULT_LIBRARY_FALLBACK in ctypes.macholib.dyld) on
- # Python 2.6 and 2.7. Python 3 users on MacPorts should add
- # the MacPorts lib directory to DYLD_LIBRARY_PATH.
- _lib = ctypes.util.find_library('openslide')
- raise ImportError("Couldn't locate OpenSlide dylib. " +
- "Is OpenSlide installed?")
- _lib = cdll.LoadLibrary(_lib)
+ _lib = cdll.LoadLibrary('@@PREFIX@@/lib/libopenslide.0.dylib')
_lib = cdll.LoadLibrary('libopenslide.so.0')