unofficial mirror of notmuch@notmuchmail.org
 help / color / mirror / code / Atom feed
* [PATCH] Fix shared library loading in Python bindings.
@ 2013-05-26  3:53 Julian Berman
  2013-05-30 12:26 ` Justus Winter
  0 siblings, 1 reply; 3+ messages in thread
From: Julian Berman @ 2013-05-26  3:53 UTC (permalink / raw)
  To: notmuch; +Cc: Julian Berman

Specifically, fixes loading on OS X, where libnotmuch will be
a dylib.:
---
 bindings/python/notmuch/globals.py | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/bindings/python/notmuch/globals.py b/bindings/python/notmuch/globals.py
index c7632c3..5e08e73 100644
--- a/bindings/python/notmuch/globals.py
+++ b/bindings/python/notmuch/globals.py
@@ -18,11 +18,12 @@ Copyright 2010 Sebastian Spaeth <Sebastian@SSpaeth.de>
 """
 
 from ctypes import CDLL, Structure, POINTER
+from ctypes.util import find_library
 
 #-----------------------------------------------------------------------------
 #package-global instance of the notmuch library
 try:
-    nmlib = CDLL("libnotmuch.so.3")
+    nmlib = CDLL(find_library("libnotmuch"))
 except:
     raise ImportError("Could not find shared 'notmuch' library.")
 
-- 
1.8.3

^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2013-05-30 16:06 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-05-26  3:53 [PATCH] Fix shared library loading in Python bindings Julian Berman
2013-05-30 12:26 ` Justus Winter
2013-05-30 16:06   ` Tomi Ollila

Code repositories for project(s) associated with this public inbox

	https://yhetil.org/notmuch.git/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).