From: David Bremner Date: Thu, 26 Jun 2014 12:02:33 +0000 (+2100) Subject: Re: notmuch-0.16: realpath() compatibility issue; clang visibility problem X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=d6a74148567bb62f83878be4b704d0c9aaaa5284;p=notmuch-archives.git Re: notmuch-0.16: realpath() compatibility issue; clang visibility problem --- diff --git a/1a/93b1f92955451c4d885507fd5d25d987ba092f b/1a/93b1f92955451c4d885507fd5d25d987ba092f new file mode 100644 index 000000000..a883801b1 --- /dev/null +++ b/1a/93b1f92955451c4d885507fd5d25d987ba092f @@ -0,0 +1,94 @@ +Return-Path: +X-Original-To: notmuch@notmuchmail.org +Delivered-To: notmuch@notmuchmail.org +Received: from localhost (localhost [127.0.0.1]) + by olra.theworths.org (Postfix) with ESMTP id 0B835431FAF + for ; Thu, 26 Jun 2014 05:02:45 -0700 (PDT) +X-Virus-Scanned: Debian amavisd-new at olra.theworths.org +X-Spam-Flag: NO +X-Spam-Score: 0 +X-Spam-Level: +X-Spam-Status: No, score=0 tagged_above=-999 required=5 tests=[none] + autolearn=disabled +Received: from olra.theworths.org ([127.0.0.1]) + by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024) + with ESMTP id zkTW1Sn+jhz9 for ; + Thu, 26 Jun 2014 05:02:39 -0700 (PDT) +Received: from yantan.tethera.net (yantan.tethera.net [199.188.72.155]) + (using TLSv1 with cipher DHE-RSA-AES128-SHA (128/128 bits)) + (No client certificate requested) + by olra.theworths.org (Postfix) with ESMTPS id 6EF0E431FAE + for ; Thu, 26 Jun 2014 05:02:39 -0700 (PDT) +Received: from remotemail by yantan.tethera.net with local (Exim 4.80) + (envelope-from ) + id 1X08Nw-00047o-Ms; Thu, 26 Jun 2014 09:02:36 -0300 +Received: (nullmailer pid 29245 invoked by uid 1000); Thu, 26 Jun 2014 + 12:02:33 -0000 +From: David Bremner +To: Thomas Klausner +Subject: Re: notmuch-0.16: realpath() compatibility issue; clang visibility + problem +In-Reply-To: <20140408123312.GZ5053@danbala.tuwien.ac.at> +References: <20140103214735.GG27614@danbala.tuwien.ac.at> + + <87ob0c6p0e.fsf@zancas.localnet> + <20140408123312.GZ5053@danbala.tuwien.ac.at> +User-Agent: Notmuch/0.18.1 (http://notmuchmail.org) Emacs/24.3.1 + (x86_64-pc-linux-gnu) +Date: Thu, 26 Jun 2014 09:02:33 -0300 +Message-ID: <87a98zho9y.fsf@zancas.localnet> +MIME-Version: 1.0 +Content-Type: text/plain +Cc: Notmuch list +X-BeenThere: notmuch@notmuchmail.org +X-Mailman-Version: 2.1.13 +Precedence: list +List-Id: "Use and development of the notmuch mail system." + +List-Unsubscribe: , + +List-Archive: +List-Post: +List-Help: +List-Subscribe: , + +X-List-Received-Date: Thu, 26 Jun 2014 12:02:45 -0000 + +Thomas Klausner writes: + +> Hi David! +> +> On Tue, Apr 08, 2014 at 08:26:25AM -0300, David Bremner wrote: +>> > Debugging it I found that notmuch uses a glibc extension to realpath, +>> > allowing NULL as second argument. +>> > +>> +>> This should be fixed in commit af5c3af ; I'd appreciate if you can test +>> it. +> +> Thanks. Not completely yet. +> +> clang++ command-line-arguments.o debugger.o gmime-filter-reply.o hooks.o notmuch.o notmuch-compact.o notmuch-config.o notmuch-count.o notmuch-dump.o notmuch-insert.o notmuch-new.o notmuch-reply.o notmuch-restore.o notmuch-search.o notmuch-setup.o notmuch-show.o notmuch-tag.o notmuch-time.o sprinter-json.o sprinter-sexp.o sprinter-text.o query-string.o mime-node.o crypto.o tag-util.o -Lutil -lutil -Llib -lnotmuch -Wl,--as-needed -L/usr/pkg/lib -Wl,-R/usr/pkg/lib -lgmime-2.4 -Wl,-R/usr/pkg/lib -lgobject-2.0 -Wl,-R/usr/pkg/lib -lglib-2.0 -lintl -L/usr/pkg/lib -Wl,-rpath,/usr/pkg/lib -Wl,-R/usr/pkg/lib -ltalloc -L/usr/pkg/lib -Wl,-R/usr/pkg/lib -lgmime-2.4 -Wl,-R/usr/pkg/lib -lgobject-2.0 -Wl,-R/usr/pkg/lib -lglib-2.0 -lintl -L/usr/pkg/lib -Wl,-rpath,/usr/pkg/lib -Wl,-R/usr/pkg/lib -ltalloc -Wl,-R/usr/pkg/lib -L/usr/pkg/lib -lxapian -L/usr/pkg/lib -lz -luuid -Wl,--enable-new-dtags -Wl,-rpath,/usr/local/lib -o notmuch-shared +> notmuch-config.o: In function `notmuch_config_save': +> notmuch-config.c:(.text+0xd03): undefined reference to `canonicalize_file_name' +> clang: error: linker command failed with exit code 1 (use -v to see invocation) +> Makefile.local:287: recipe for target 'notmuch-shared' failed +> gmake: *** [notmuch-shared] Error 1 + +Sorry this got dropped. That's what happens to mail sent to me +personally :(. I'm assuming it's ok forward this output to the list. + +Is it correct that the statically linked version (notmuch) worked OK but +the dynamically linked version (notmuch-shared) failed? That's +consistent with what I observe on Debian, it's just that here the +dynamically linked version falls back on the canonicalize_file_name in +glibc, hiding the error. + +For people on glibc platforms who want to play with this, + +set HAVE_CANONICALIZE_FILE_NAME=0 in Makefile.config, make clean, make + +% nm notmuch-shared | grep canonicalize + +d +