X-Git-Url: https://git.notmuchmail.org/git?p=notmuch;a=blobdiff_plain;f=bindings%2Fpython%2Fnotmuch%2Fglobals.py;h=24b25d3641efef72ead08be70245821cdbffa557;hp=c7632c3266d428cc42ee43c652701df13c7364dd;hb=f310e349df60f18deea91f3e61971652bf8cdf58;hpb=d99f15d7ee38d606a2b3b5bd34f1e6c787b3b8a2 diff --git a/bindings/python/notmuch/globals.py b/bindings/python/notmuch/globals.py index c7632c32..24b25d36 100644 --- a/bindings/python/notmuch/globals.py +++ b/bindings/python/notmuch/globals.py @@ -22,7 +22,11 @@ from ctypes import CDLL, Structure, POINTER #----------------------------------------------------------------------------- #package-global instance of the notmuch library try: - nmlib = CDLL("libnotmuch.so.3") + from os import uname + if uname()[0] == 'Darwin': + nmlib = CDLL("libnotmuch.4.dylib") + else: + nmlib = CDLL("libnotmuch.so.4") except: raise ImportError("Could not find shared 'notmuch' library.")