Re: [bug] Python bindings fail to load shared libraries in MacOS El Capitan

Subject: Re: [bug] Python bindings fail to load shared libraries in MacOS El Capitan

Date: Thu, 22 Oct 2015 09:38:29 +0200

To: David Bremner

Cc: notmuch@notmuchmail.org

From: Robert Künnemann


Hi!

On 21/10, David Bremner wrote:
>Robert Künnemann <robert@kunnemann.de> writes:
>>
>> nmlib = CDLL("libnotmuch.so.{0:s}".format(SOVERSION))
>>
>> in globals.py
>>
>> nmlib = CDLL("/usr/local/lib/libnotmuch.{0:s}.dylib".format(SOVERSION))
>
>In recent versions of notmuch there's already code there to detect MacOS
>and do something different. Are you saying that detection is not
>working?
It is working and adds the suffix ".dylyb" to the library name.

>Also, it seems like you are coding the absolute path name of
>the library. Is that really necessary?
It seems so. Two responses in the thread I mentioned
http://stackoverflow.com/questions/32905322/oserror-dlopenlibsystem-dylib-6-image-not-found
suggest the same, and it solved the issue for me.

I am happy to try out other, better solutions.

Cheers, Robert

Thread: