--- /dev/null
+Return-Path: <polatel@gmail.com>\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 2A26A431FBC\r
+ for <notmuch@notmuchmail.org>; Sun, 24 Jun 2012 15:21:06 -0700 (PDT)\r
+X-Virus-Scanned: Debian amavisd-new at olra.theworths.org\r
+X-Spam-Flag: NO\r
+X-Spam-Score: -0.799\r
+X-Spam-Level: \r
+X-Spam-Status: No, score=-0.799 tagged_above=-999 required=5\r
+ tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1,\r
+ FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_LOW=-0.7] 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 U3pNJ6S3YG6y for <notmuch@notmuchmail.org>;\r
+ Sun, 24 Jun 2012 15:21:05 -0700 (PDT)\r
+Received: from mail-lb0-f181.google.com (mail-lb0-f181.google.com\r
+ [209.85.217.181]) (using TLSv1 with cipher RC4-SHA (128/128 bits))\r
+ (No client certificate requested)\r
+ by olra.theworths.org (Postfix) with ESMTPS id 2DEE2431FAE\r
+ for <notmuch@notmuchmail.org>; Sun, 24 Jun 2012 15:21:05 -0700 (PDT)\r
+Received: by lbbgk8 with SMTP id gk8so5814283lbb.26\r
+ for <notmuch@notmuchmail.org>; Sun, 24 Jun 2012 15:21:03 -0700 (PDT)\r
+DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113;\r
+ h=mime-version:in-reply-to:references:from:date:message-id:subject:to\r
+ :cc:content-type:content-transfer-encoding;\r
+ bh=vRR9ESNUHAnDWDLSsLz5ecgU0QHJsD57VSS5bariBLM=;\r
+ b=rJQnbdBhd+8DYog/28GigUi0ZGCw9nCoT4NSZkagx9E54lTbCAOcfI2p7lH3cCifkQ\r
+ lzLxIxAuExilL1WCp7VV10DBt/9yfXF6bmgejTAURurVGtP6xF7aCPUYhH3rUIYiokN6\r
+ 92RCiGVJ2ah8+mQ7buF9VTnDsMlRqmUHt2GhMHxqOfqJetFUCz62VmCz6R2prFPutsQp\r
+ CChtLeocN+f14YF1fvpKPPP8YIe1bdMey3assNK08obW7JGgstqfp7EcU8R6eppEnvuI\r
+ 5X67yM8xn8INojS47Lf67k7AZJHl9D3d08aR2Kv3wiA6Fm/KKlwtkWCEYykZAJMFG0m0\r
+ Z3TQ==\r
+Received: by 10.152.147.33 with SMTP id th1mr9995760lab.9.1340576463491; Sun,\r
+ 24 Jun 2012 15:21:03 -0700 (PDT)\r
+MIME-Version: 1.0\r
+Received: by 10.112.87.134 with HTTP; Sun, 24 Jun 2012 15:20:43 -0700 (PDT)\r
+In-Reply-To: <1340563714-3103-1-git-send-email-tomi.ollila@iki.fi>\r
+References: <1340563714-3103-1-git-send-email-tomi.ollila@iki.fi>\r
+From: Ali Polatel <polatel@gmail.com>\r
+Date: Mon, 25 Jun 2012 01:20:43 +0300\r
+Message-ID:\r
+ <CADv3eywhB6QGu+BXQ=azSrCUZF4u_3wyUU2RvJ42Y5MZBVWoEQ@mail.gmail.com>\r
+Subject: Re: [PATCH v2] ruby: extern linkage portability improvement\r
+To: Tomi Ollila <tomi.ollila@iki.fi>\r
+Content-Type: text/plain; charset=ISO-8859-1\r
+Content-Transfer-Encoding: quoted-printable\r
+Cc: notmuch@notmuchmail.org\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: Sun, 24 Jun 2012 22:21:06 -0000\r
+\r
+2012/6/24 Tomi Ollila <tomi.ollila@iki.fi>:\r
+> Some C compilers are stricter when it comes to (tentative) definition\r
+> of a variable -- in those compilers introducing variable without 'extern'\r
+> keyword always allocates new 'storage' to the variable and linking all\r
+> these modules fails due to duplicate symbols.\r
+>\r
+> This is reimplementation of Charlie Allom's patch:\r
+> id:"1336481467-66356-1-git-send-email-charlie@mediasp.com",\r
+> written originally by Ali Polatel. This version has\r
+> more accurate commit message.\r
+> ---\r
+> =A0bindings/ruby/defs.h | =A0 46 +++++++++++++++++++++++-----------------=\r
+------\r
+> =A0bindings/ruby/init.c | =A0 26 ++++++++++++++++++++++++++\r
+> =A02 files changed, 49 insertions(+), 23 deletions(-)\r
+>\r
+> diff --git a/bindings/ruby/defs.h b/bindings/ruby/defs.h\r
+> index 3f9512b..fe81b3f 100644\r
+> --- a/bindings/ruby/defs.h\r
+> +++ b/bindings/ruby/defs.h\r
+> @@ -24,31 +24,31 @@\r
+> =A0#include <notmuch.h>\r
+> =A0#include <ruby.h>\r
+>\r
+> -VALUE notmuch_rb_cDatabase;\r
+> -VALUE notmuch_rb_cDirectory;\r
+> -VALUE notmuch_rb_cFileNames;\r
+> -VALUE notmuch_rb_cQuery;\r
+> -VALUE notmuch_rb_cThreads;\r
+> -VALUE notmuch_rb_cThread;\r
+> -VALUE notmuch_rb_cMessages;\r
+> -VALUE notmuch_rb_cMessage;\r
+> -VALUE notmuch_rb_cTags;\r
+> -\r
+> -VALUE notmuch_rb_eBaseError;\r
+> -VALUE notmuch_rb_eDatabaseError;\r
+> -VALUE notmuch_rb_eMemoryError;\r
+> -VALUE notmuch_rb_eReadOnlyError;\r
+> -VALUE notmuch_rb_eXapianError;\r
+> -VALUE notmuch_rb_eFileError;\r
+> -VALUE notmuch_rb_eFileNotEmailError;\r
+> -VALUE notmuch_rb_eNullPointerError;\r
+> -VALUE notmuch_rb_eTagTooLongError;\r
+> -VALUE notmuch_rb_eUnbalancedFreezeThawError;\r
+> -VALUE notmuch_rb_eUnbalancedAtomicError;\r
+> -\r
+> -ID ID_call;\r
+> -ID ID_db_create;\r
+> -ID ID_db_mode;\r
+> +extern VALUE notmuch_rb_cDatabase;\r
+> +extern VALUE notmuch_rb_cDirectory;\r
+> +extern VALUE notmuch_rb_cFileNames;\r
+> +extern VALUE notmuch_rb_cQuery;\r
+> +extern VALUE notmuch_rb_cThreads;\r
+> +extern VALUE notmuch_rb_cThread;\r
+> +extern VALUE notmuch_rb_cMessages;\r
+> +extern VALUE notmuch_rb_cMessage;\r
+> +extern VALUE notmuch_rb_cTags;\r
+> +\r
+> +extern VALUE notmuch_rb_eBaseError;\r
+> +extern VALUE notmuch_rb_eDatabaseError;\r
+> +extern VALUE notmuch_rb_eMemoryError;\r
+> +extern VALUE notmuch_rb_eReadOnlyError;\r
+> +extern VALUE notmuch_rb_eXapianError;\r
+> +extern VALUE notmuch_rb_eFileError;\r
+> +extern VALUE notmuch_rb_eFileNotEmailError;\r
+> +extern VALUE notmuch_rb_eNullPointerError;\r
+> +extern VALUE notmuch_rb_eTagTooLongError;\r
+> +extern VALUE notmuch_rb_eUnbalancedFreezeThawError;\r
+> +extern VALUE notmuch_rb_eUnbalancedAtomicError;\r
+> +\r
+> +extern ID ID_call;\r
+> +extern ID ID_db_create;\r
+> +extern ID ID_db_mode;\r
+>\r
+> =A0/* RSTRING_PTR() is new in ruby-1.9 */\r
+> =A0#if !defined(RSTRING_PTR)\r
+> diff --git a/bindings/ruby/init.c b/bindings/ruby/init.c\r
+> index 3fe60fb..f4931d3 100644\r
+> --- a/bindings/ruby/init.c\r
+> +++ b/bindings/ruby/init.c\r
+> @@ -20,6 +20,32 @@\r
+>\r
+> =A0#include "defs.h"\r
+>\r
+> +VALUE notmuch_rb_cDatabase;\r
+> +VALUE notmuch_rb_cDirectory;\r
+> +VALUE notmuch_rb_cFileNames;\r
+> +VALUE notmuch_rb_cQuery;\r
+> +VALUE notmuch_rb_cThreads;\r
+> +VALUE notmuch_rb_cThread;\r
+> +VALUE notmuch_rb_cMessages;\r
+> +VALUE notmuch_rb_cMessage;\r
+> +VALUE notmuch_rb_cTags;\r
+> +\r
+> +VALUE notmuch_rb_eBaseError;\r
+> +VALUE notmuch_rb_eDatabaseError;\r
+> +VALUE notmuch_rb_eMemoryError;\r
+> +VALUE notmuch_rb_eReadOnlyError;\r
+> +VALUE notmuch_rb_eXapianError;\r
+> +VALUE notmuch_rb_eFileError;\r
+> +VALUE notmuch_rb_eFileNotEmailError;\r
+> +VALUE notmuch_rb_eNullPointerError;\r
+> +VALUE notmuch_rb_eTagTooLongError;\r
+> +VALUE notmuch_rb_eUnbalancedFreezeThawError;\r
+> +VALUE notmuch_rb_eUnbalancedAtomicError;\r
+> +\r
+> +ID ID_call;\r
+> +ID ID_db_create;\r
+> +ID ID_db_mode;\r
+> +\r
+> =A0/*\r
+> =A0* Document-module: Notmuch\r
+> =A0*\r
+> --\r
+> 1.7.1\r
+>\r
+> _______________________________________________\r
+> notmuch mailing list\r
+> notmuch@notmuchmail.org\r
+> http://notmuchmail.org/mailman/listinfo/notmuch\r
+\r
+Looks highly familiar yet strangely good to me.\r