From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from localhost (localhost [127.0.0.1]) by olra.theworths.org (Postfix) with ESMTP id B3110431FD0 for ; Thu, 23 Jun 2011 03:24:11 -0700 (PDT) X-Virus-Scanned: Debian amavisd-new at olra.theworths.org X-Spam-Flag: NO X-Spam-Score: -2.3 X-Spam-Level: X-Spam-Status: No, score=-2.3 tagged_above=-999 required=5 tests=[RCVD_IN_DNSWL_MED=-2.3] 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 fK1QBklVwZRU for ; Thu, 23 Jun 2011 03:24:11 -0700 (PDT) Received: from tempo.its.unb.ca (tempo.its.unb.ca [131.202.1.21]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by olra.theworths.org (Postfix) with ESMTPS id D5786431FB6 for ; Thu, 23 Jun 2011 03:24:10 -0700 (PDT) Received: from zancas.localnet (fctnnbsc30w-142167176081.pppoe-dynamic.High-Speed.nb.bellaliant.net [142.167.176.81]) (authenticated bits=0) by tempo.its.unb.ca (8.13.8/8.13.8) with ESMTP id p5NAO8Zr031586 (version=TLSv1/SSLv3 cipher=AES256-SHA bits=256 verify=NO); Thu, 23 Jun 2011 07:24:09 -0300 Received: from bremner by zancas.localnet with local (Exim 4.76) (envelope-from ) id 1QZh4y-0000lT-96; Thu, 23 Jun 2011 07:24:08 -0300 From: David Bremner To: notmuch@notmuchmail.org Subject: Re: [PATCH] tests: add a test for symbol hiding side effects In-Reply-To: <1308744156-18123-1-git-send-email-david@tethera.net> References: <87tybir2s9.fsf@zancas.localnet> <1308744156-18123-1-git-send-email-david@tethera.net> User-Agent: Notmuch/0.6~238 (http://notmuchmail.org) Emacs/23.3.1 (x86_64-pc-linux-gnu) Date: Thu, 23 Jun 2011 07:24:08 -0300 Message-ID: <878vssrgl3.fsf@zancas.localnet> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii 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, 23 Jun 2011 10:24:11 -0000 On Wed, 22 Jun 2011 09:02:36 -0300, david@tethera.net wrote: > From: David Bremner > > The worry here is that a binary linking with libnotmuch might lose > access to Xapian::Error symbols because libnotmuch hides them. After some helpful feedback from jrollins and amdragon on IRC, I have pushed an updated version of this. The guts of the updated test are as follows: run_test(){ result=$(LD_LIBRARY_PATH=../../lib ./symbol-test 2>&1) } output="A Xapian exception occurred opening database: Couldn't stat 'fakedb/.notmuch/xapian' caught No chert database found at path \`./nonexistant'" g++ -o symbol-test -I../../lib ../symbol-test.cc -L../../lib -lnotmuch -lxapian mkdir -p fakedb/.notmuch test_expect_success 'running test' run_test test_begin_subtest 'checking output' test_expect_equal "$result" "$output" test_done