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 B0DE5429E25 for ; Sun, 27 Nov 2011 10:25:35 -0800 (PST) X-Virus-Scanned: Debian amavisd-new at olra.theworths.org X-Spam-Flag: NO X-Spam-Score: -0.799 X-Spam-Level: X-Spam-Status: No, score=-0.799 tagged_above=-999 required=5 tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_LOW=-0.7] 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 UU6APwLUROAn for ; Sun, 27 Nov 2011 10:25:34 -0800 (PST) Received: from mail-bw0-f53.google.com (mail-bw0-f53.google.com [209.85.214.53]) (using TLSv1 with cipher RC4-SHA (128/128 bits)) (No client certificate requested) by olra.theworths.org (Postfix) with ESMTPS id E0944431FB6 for ; Sun, 27 Nov 2011 10:25:33 -0800 (PST) Received: by bkaq10 with SMTP id q10so7992639bka.26 for ; Sun, 27 Nov 2011 10:25:32 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=from:to:subject:in-reply-to:references:user-agent:date:message-id :mime-version:content-type:content-transfer-encoding; bh=KCFIRINXOLBAUiNfbtW2TXiKsrvIHu8B8rwlM4fA5jI=; b=bgizljATISGxGl77OHTMgDHCWfVGwd+kTZmtBn4JHqBKPTcFK5eaM5mW2KyVf/TE7c Xqbv5ro8TULUpzdmEbVOV0t8rWu2bjSw4Llcap1iGaNMkA3cp9dNwgLcN9lHQByxgo5N w4QWHCj4zW2HleLHt4OtEciZrCA+07Lua2iGQ= Received: by 10.204.154.201 with SMTP id p9mr42846448bkw.33.1322418332318; Sun, 27 Nov 2011 10:25:32 -0800 (PST) Received: from localhost ([91.144.186.21]) by mx.google.com with ESMTPS id e18sm25063704bkr.15.2011.11.27.10.25.30 (version=TLSv1/SSLv3 cipher=OTHER); Sun, 27 Nov 2011 10:25:30 -0800 (PST) From: Dmitry Kurochkin To: Amadeusz =?utf-8?B?xbtvxYJub3dza2k=?= , notmuch@notmuchmail.org Subject: Re: [PATCH] Build symbol-test with make instead of hardcoding in symbol-hiding. In-Reply-To: <1322342060-967-1-git-send-email-aidecoe@aidecoe.name> References: <1322341843-sup-9963@raeviah> <1322342060-967-1-git-send-email-aidecoe@aidecoe.name> User-Agent: Notmuch/0.10+25~g1a9cfbd (http://notmuchmail.org) Emacs/23.3.1 (x86_64-pc-linux-gnu) Date: Sun, 27 Nov 2011 22:25:09 +0400 Message-ID: <87vcq5e83e.fsf@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable 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: Sun, 27 Nov 2011 18:25:35 -0000 On Sat, 26 Nov 2011 22:14:20 +0100, Amadeusz =C5=BBo=C5=82nowski wrote: > If symbol-test is built in symbol-hiding with hardcoded g++ invokation, > it's not so easy to pass $(srcdir) which is required to find notmuch.h > when srcdir and builddir are separate directories. > --- > test/.gitignore | 1 + > test/Makefile.local | 7 +++++-- > test/basic | 2 +- > test/symbol-hiding | 3 +-- > 4 files changed, 8 insertions(+), 5 deletions(-) >=20 > diff --git a/test/.gitignore b/test/.gitignore > index 9e97052..7e30e8d 100644 > --- a/test/.gitignore > +++ b/test/.gitignore > @@ -1,4 +1,5 @@ > test-results > corpus.mail > smtp-dummy > +symbol-test > tmp.* > diff --git a/test/Makefile.local b/test/Makefile.local > index 9b3308a..646779e 100644 > --- a/test/Makefile.local > +++ b/test/Makefile.local > @@ -11,10 +11,13 @@ smtp_dummy_modules =3D $(smtp_dummy_srcs:.c=3D.o) > $(dir)/smtp-dummy: $(smtp_dummy_modules) > $(call quiet,CC) $^ -o $@ >=20=20 > +$(dir)/symbol-test: $(dir)/symbol-test.o > + $(call quiet,CC) $^ -o $@ -Llib -lnotmuch -lxapian > + > .PHONY: test check > -test: all $(dir)/smtp-dummy > +test: all $(dir)/smtp-dummy $(dir)/symbol-test > @${dir}/notmuch-test $(OPTIONS) >=20=20 > check: test >=20=20 > -CLEAN :=3D $(CLEAN) $(dir)/smtp-dummy $(dir)/smtp-dummy.o > +CLEAN :=3D $(CLEAN) $(dir)/smtp-dummy $(dir)/smtp-dummy.o $(dir)/symbol-= test $(dir)/symbol-test.o > diff --git a/test/basic b/test/basic > index f258d1f..4edf831 100755 > --- a/test/basic > +++ b/test/basic > @@ -54,7 +54,7 @@ test_begin_subtest 'Ensure that all available tests wil= l be run by notmuch-test' > eval $(sed -n -e '/^TESTS=3D"$/,/^"$/p' $TEST_DIRECTORY/notmuch-test) > tests_in_suite=3D$(for i in $TESTS; do echo $i; done | sort) > available=3D$(find "$TEST_DIRECTORY" -maxdepth 1 -type f -executable -pr= intf '%f\n' | \ > - sed -r -e "/^(aggregate-results.sh|notmuch-test|smtp-dummy|test-verb= ose)$/d" | \ > + sed -r -e "/^(aggregate-results.sh|notmuch-test|smtp-dummy|test-verb= ose|symbol-test)$/d" | \ Can you please keep this list alphabetically sorted? Regards, Dmitry > sort) > test_expect_equal "$tests_in_suite" "$available" >=20=20 > diff --git a/test/symbol-hiding b/test/symbol-hiding > index d0b31ae..f67b653 100755 > --- a/test/symbol-hiding > +++ b/test/symbol-hiding > @@ -12,13 +12,12 @@ test_description=3D'exception symbol hiding' > . ./test-lib.sh >=20=20 > run_test(){ > - result=3D$(LD_LIBRARY_PATH=3D$TEST_DIRECTORY/../lib ./symbol-test 2>= &1) > + result=3D$(LD_LIBRARY_PATH=3D$TEST_DIRECTORY/../lib $TEST_DIRECTORY/= symbol-test 2>&1) > } >=20=20 > output=3D"A Xapian exception occurred opening database: Couldn't stat 'f= akedb/.notmuch/xapian' > caught No chert database found at path \`./nonexistant'" >=20=20 > -g++ -o symbol-test -I$TEST_DIRECTORY/../lib $TEST_DIRECTORY/symbol-test.= cc -L$TEST_DIRECTORY/../lib -lnotmuch -lxapian > mkdir -p fakedb/.notmuch > test_expect_success 'running test' run_test > test_begin_subtest 'checking output' > --=20 > 1.7.8.rc3 >=20 > _______________________________________________ > notmuch mailing list > notmuch@notmuchmail.org > http://notmuchmail.org/mailman/listinfo/notmuch