--- /dev/null
+Return-Path: <teythoon@jade-hamburg.de>\r
+X-Original-To: notmuch@notmuchmail.org\r
+Delivered-To: notmuch@notmuchmail.org\r
+Received: from localhost (localhost [127.0.0.1])\r
+ by olra.theworths.org (Postfix) with ESMTP id 4EFED431FB6\r
+ for <notmuch@notmuchmail.org>; Tue, 25 Jun 2013 08:22:18 -0700 (PDT)\r
+X-Virus-Scanned: Debian amavisd-new at olra.theworths.org\r
+X-Spam-Flag: NO\r
+X-Spam-Score: 0\r
+X-Spam-Level: \r
+X-Spam-Status: No, score=0 tagged_above=-999 required=5 tests=[none]\r
+ autolearn=disabled\r
+Received: from olra.theworths.org ([127.0.0.1])\r
+ by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024)\r
+ with ESMTP id XBLlpd3GoFJJ for <notmuch@notmuchmail.org>;\r
+ Tue, 25 Jun 2013 08:22:11 -0700 (PDT)\r
+Received: from mail.cryptobitch.de (cryptobitch.de [88.198.7.68])\r
+ (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits))\r
+ (No client certificate requested)\r
+ by olra.theworths.org (Postfix) with ESMTPS id 0EE07431FAF\r
+ for <notmuch@notmuchmail.org>; Tue, 25 Jun 2013 08:22:11 -0700 (PDT)\r
+Received: from mail.jade-hamburg.de (mail.jade-hamburg.de [85.183.11.228])\r
+ (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits))\r
+ (No client certificate requested)\r
+ by mail.cryptobitch.de (Postfix) with ESMTPSA id A64D0691115\r
+ for <notmuch@notmuchmail.org>; Tue, 25 Jun 2013 17:22:02 +0200 (CEST)\r
+Received: by mail.jade-hamburg.de (Postfix, from userid 401)\r
+ id 29C18DF2A4; Tue, 25 Jun 2013 17:22:01 +0200 (CEST)\r
+Received: from thinkbox.jade-hamburg.de (unknown\r
+ [IPv6:2002:55b7:be4:1:216:d3ff:fe3e:5058])\r
+ (using TLSv1 with cipher DHE-RSA-AES128-SHA (128/128 bits))\r
+ (No client certificate requested) (Authenticated sender: teythoon)\r
+ by mail.jade-hamburg.de (Postfix) with ESMTPSA id 99232DF29F;\r
+ Tue, 25 Jun 2013 17:22:00 +0200 (CEST)\r
+Received: from teythoon by thinkbox.jade-hamburg.de with local (Exim 4.80)\r
+ (envelope-from <teythoon@thinkbox.jade-hamburg.de>)\r
+ id 1UrV4B-00056a-C0; Tue, 25 Jun 2013 17:21:59 +0200\r
+Content-Type: text/plain; charset="utf-8"\r
+MIME-Version: 1.0\r
+Content-Transfer-Encoding: quoted-printable\r
+To: Tomi Ollila <tomi.ollila@iki.fi>, notmuch@notmuchmail.org\r
+From: Justus Winter <4winter@informatik.uni-hamburg.de>\r
+In-Reply-To: <1372171016-11935-1-git-send-email-tomi.ollila@iki.fi>\r
+References: <1372171016-11935-1-git-send-email-tomi.ollila@iki.fi>\r
+Message-ID: <20130625152159.17799.36764@thinkbox.jade-hamburg.de>\r
+User-Agent: alot/0.3.4\r
+Subject: Re: [RFC PATCH] Python bindings: CDLL("libnotmuch.3.dylib") on Darwin\r
+Date: Tue, 25 Jun 2013 17:21:59 +0200\r
+Cc: tomi.ollila@iki.fi\r
+X-BeenThere: notmuch@notmuchmail.org\r
+X-Mailman-Version: 2.1.13\r
+Precedence: list\r
+List-Id: "Use and development of the notmuch mail system."\r
+ <notmuch.notmuchmail.org>\r
+List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,\r
+ <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>\r
+List-Archive: <http://notmuchmail.org/pipermail/notmuch>\r
+List-Post: <mailto:notmuch@notmuchmail.org>\r
+List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>\r
+List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,\r
+ <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
+X-List-Received-Date: Tue, 25 Jun 2013 15:22:18 -0000\r
+\r
+Quoting Tomi Ollila (2013-06-25 16:36:56)\r
+> Use os.uname() to check for 'Darwin' and load "libnotmuch.3.dylib"\r
+> instead of "libnotmuch.so.3" if that is the case.\r
+> ---\r
+> =\r
+\r
+> This is followup to thread starting from\r
+> =\r
+\r
+> id:1369540418-94177-1-git-send-email-Julian@GrayVines.com\r
+> =\r
+\r
+> For anyone interested: this is basically no-overhead addition as ctypes\r
+> already loads os module (is "available" as ctypes._os) -- Comparison using\r
+> strace(1) showed that uname system call is used in addition to other proc=\r
+essing.\r
+> =\r
+\r
+> This patch is modeled after _lb_'s comments on IRC:\r
+> =\r
+\r
+> < _lb_> nmlib =3D CDLL("libnotmuch.so.3") needs to be replaced with\r
+> nmlib =3D CDLL("libnotmuch.3.dylib") in OSX\r
+> < _lb_> Works like a charm! Mmm... I'll have to subscribe to the list\r
+> to send the patch...\r
+> < _lb_> I guess the quid of the question is to have an os detection\r
+> if so it loads the right lib?\r
+> =\r
+\r
+> ... a few days ago, but the patch didn't arrive yet ;D\r
+> =\r
+\r
+> I tested that this still works on Linux, but did not test on Mac OS X;\r
+> also I did not think much how to handle the importing and the if test.\r
+> =\r
+\r
+> Anyone using Mac care to take over -- you are probably more interested\r
+> of getting this thing to work :D\r
+\r
+Looks good, though I'd prefer not to do the from..import\r
+thing. os.uname is just as short and more concise, you can see where\r
+the uname function comes from.\r
+\r
+If anyone on OSX confirms that this works I'll merge the patch.\r
+\r
+Justus\r