1 Return-Path: <bijan.chokoufe@gmail.com>
\r
2 X-Original-To: notmuch@notmuchmail.org
\r
3 Delivered-To: notmuch@notmuchmail.org
\r
4 Received: from localhost (localhost [127.0.0.1])
\r
5 by arlo.cworth.org (Postfix) with ESMTP id 9BB2B6DE00DF
\r
6 for <notmuch@notmuchmail.org>; Thu, 26 May 2016 09:03:20 -0700 (PDT)
\r
7 X-Virus-Scanned: Debian amavisd-new at cworth.org
\r
11 X-Spam-Status: No, score=-0.82 tagged_above=-999 required=5
\r
12 tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1,
\r
13 FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H3=-0.01,
\r
14 RCVD_IN_MSPIKE_WL=-0.01, SPF_PASS=-0.001] autolearn=disabled
\r
15 Received: from arlo.cworth.org ([127.0.0.1])
\r
16 by localhost (arlo.cworth.org [127.0.0.1]) (amavisd-new, port 10024)
\r
17 with ESMTP id 3DE4ZoJOJurJ for <notmuch@notmuchmail.org>;
\r
18 Thu, 26 May 2016 09:03:11 -0700 (PDT)
\r
19 Received: from mail-wm0-f50.google.com (mail-wm0-f50.google.com
\r
20 [74.125.82.50]) by arlo.cworth.org (Postfix) with ESMTPS id 85AA46DE009B for
\r
21 <notmuch@notmuchmail.org>; Thu, 26 May 2016 09:03:11 -0700 (PDT)
\r
22 Received: by mail-wm0-f50.google.com with SMTP id n129so105672685wmn.1
\r
23 for <notmuch@notmuchmail.org>; Thu, 26 May 2016 09:03:11 -0700 (PDT)
\r
24 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113;
\r
25 h=date:from:to:cc:subject:message-id:references:mime-version
\r
26 :content-disposition:in-reply-to:user-agent;
\r
27 bh=2K+j5kF6Ex6SjNbtJcUdvDt+6HSzIJ6lW/M5wUbufK8=;
\r
28 b=gS0SIbbrPSZ2+l8A1onIlJV/zZJG9guM1CkVWU5CqzTmrsksCT6GVOiXt0B4MQr8KJ
\r
29 rzRhZoEetbL3YRPhgvSV7eboCRg2U/wEIWAGPe3OK9THcDaq2+ahziarJbIbPZ+Vsu7u
\r
30 U2/LvrILelsSpYtUecZoMpN/1vrPrXje2dDno3yGA7muF/bjIwV4jPILNovEL9CHr7DC
\r
31 fQnKwwQnZ0PDjiXzr4nazjn+yqJ0TMYyRpREhLjYmCfJsklmh1FNAx0X2iqloPdiBB2e
\r
32 twX5i+sR2OI2OFIfbEke21CLMA1mbPn+CdPNUN6g77aH70THdu0TUzRWMOBoIEd6c7X7
\r
34 X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
\r
35 d=1e100.net; s=20130820;
\r
36 h=x-gm-message-state:date:from:to:cc:subject:message-id:references
\r
37 :mime-version:content-disposition:in-reply-to:user-agent;
\r
38 bh=2K+j5kF6Ex6SjNbtJcUdvDt+6HSzIJ6lW/M5wUbufK8=;
\r
39 b=KRrh/QcMsGlNULpXhlX6UIxkquulLKdRy3SgUU23I9SEdHA1tIvrqAANFY1NG627m2
\r
40 eS3E5HAhosZJT2kH6e+v39FqZuTrm7kTWVmQm58aUW7HdzroEqx+qxAzH0lRTnlRoxD5
\r
41 DN0JKmM6H6lsSBmbvH3ZgGtzSbMGSVQkHmtgRxY71yfMDy805dOREdaH9XaIyU/oOzOX
\r
42 W5l4H67M26nFrdLmIN55GoRS8PvQxm4xIL44wGqYwD3I8bRjHQJahknMnu9ecpphNw5/
\r
43 MDB006u8AJBhMgr1Z6iOQyYXI8p+o+Wa3QxH1pd73KOOc8SnmLTAPC36CwKL082+NwDL
\r
46 ALyK8tLKhHYZzGIEK+UbGFjWu9RPAUidGzWhNW3tXbKPbNvbxld5QAuMGT1MHZYiQrc2vQ==
\r
47 X-Received: by 10.194.201.97 with SMTP id jz1mr10015543wjc.44.1464278589000;
\r
48 Thu, 26 May 2016 09:03:09 -0700 (PDT)
\r
49 Received: from localhost (chokoufe.desy.de. [131.169.210.242])
\r
50 by smtp.gmail.com with ESMTPSA id o203sm4175415wmg.22.2016.05.26.09.03.07
\r
51 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);
\r
52 Thu, 26 May 2016 09:03:08 -0700 (PDT)
\r
53 Date: Thu, 26 May 2016 18:03:07 +0200
\r
54 From: Bijan Chokoufe Nejad <bijan.chokoufe@gmail.com>
\r
55 To: Tomi Ollila <tomi.ollila@iki.fi>
\r
56 Cc: notmuch@notmuchmail.org
\r
57 Subject: Re: [PATCH 1/2] test: set LD_LIBRARY_PATH early and keep its old
\r
59 Message-ID: <20160526160307.GC30031@bijan-TPX1Yoga>
\r
60 References: <1464212261-26892-1-git-send-email-tomi.ollila@iki.fi>
\r
62 Content-Type: text/plain; charset=us-ascii
\r
63 Content-Disposition: inline
\r
64 In-Reply-To: <1464212261-26892-1-git-send-email-tomi.ollila@iki.fi>
\r
65 User-Agent: Mutt/1.5.24 (2015-08-30)
\r
66 X-BeenThere: notmuch@notmuchmail.org
\r
67 X-Mailman-Version: 2.1.20
\r
69 List-Id: "Use and development of the notmuch mail system."
\r
70 <notmuch.notmuchmail.org>
\r
71 List-Unsubscribe: <https://notmuchmail.org/mailman/options/notmuch>,
\r
72 <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>
\r
73 List-Archive: <http://notmuchmail.org/pipermail/notmuch/>
\r
74 List-Post: <mailto:notmuch@notmuchmail.org>
\r
75 List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>
\r
76 List-Subscribe: <https://notmuchmail.org/mailman/listinfo/notmuch>,
\r
77 <mailto:notmuch-request@notmuchmail.org?subject=subscribe>
\r
78 X-List-Received-Date: Thu, 26 May 2016 16:03:20 -0000
\r
80 This could explain some of the problems I had to get the test suite running.
\r
81 I would have never guessed that LD_LIBRARY_PATH gets overwritten by the test
\r
84 On 16-05-26, Tomi Ollila wrote:
\r
85 > Previously LD_LIBRARY_PATH was exported (and environment changed)
\r
86 > in the middle of test case execution, when a function setting it
\r
89 > Previously the old contents of LD_LIBRARY_PATH was lost (if any)
\r
90 > when it was re-set and exported. In some systems the old contents of
\r
91 > LD_LIBRARY_PATH was needed to e.g. locate suitable gmime library.
\r
94 > This series (of 2 patches) has exactly same payload as the previous
\r
96 > id:1460738800-9021-1-git-send-email-tomi.ollila@iki.fi
\r
98 > commit messages are updated to be accurate (? :) this time.
\r
100 > test/T360-symbol-hiding.sh | 5 ++---
\r
101 > test/test-lib-common.sh | 5 +++++
\r
102 > test/test-lib.sh | 3 ---
\r
103 > 3 files changed, 7 insertions(+), 6 deletions(-)
\r
105 > diff --git a/test/T360-symbol-hiding.sh b/test/T360-symbol-hiding.sh
\r
106 > index 3f18ec1a34fc..9c10e8eda07f 100755
\r
107 > --- a/test/T360-symbol-hiding.sh
\r
108 > +++ b/test/T360-symbol-hiding.sh
\r
109 > @@ -13,9 +13,8 @@ test_description='exception symbol hiding'
\r
111 > test_begin_subtest 'running test' run_test
\r
112 > mkdir -p ${PWD}/fakedb/.notmuch
\r
113 > -( LD_LIBRARY_PATH="$TEST_DIRECTORY/../lib${LD_LIBRARY_PATH:+:$LD_LIBRARY_PATH}" \
\r
114 > - $TEST_DIRECTORY/symbol-test ${PWD}/fakedb ${PWD}/nonexistent \
\r
115 > - 2>&1 | notmuch_dir_sanitize | sed -e "s,\`,\',g" -e "s,${NOTMUCH_DEFAULT_XAPIAN_BACKEND},backend,g") > OUTPUT
\r
116 > +$TEST_DIRECTORY/symbol-test ${PWD}/fakedb ${PWD}/nonexistent 2>&1 \
\r
117 > + | notmuch_dir_sanitize | sed -e "s,\`,\',g" -e "s,${NOTMUCH_DEFAULT_XAPIAN_BACKEND},backend,g" > OUTPUT
\r
119 > cat <<EOF > EXPECTED
\r
120 > A Xapian exception occurred opening database: Couldn't stat 'CWD/fakedb/.notmuch/xapian'
\r
121 > diff --git a/test/test-lib-common.sh b/test/test-lib-common.sh
\r
122 > index ba4a8e112084..026440ccc057 100644
\r
123 > --- a/test/test-lib-common.sh
\r
124 > +++ b/test/test-lib-common.sh
\r
125 > @@ -52,6 +52,11 @@ restore_database () {
\r
126 > TEST_DIRECTORY=$(pwd -P)
\r
127 > notmuch_path=`find_notmuch_path "$TEST_DIRECTORY"`
\r
129 > +# Prepend $TEST_DIRECTORY/../lib to LD_LIBRARY_PATH, to make tests work
\r
130 > +# on systems where ../notmuch depends on LD_LIBRARY_PATH.
\r
131 > +LD_LIBRARY_PATH=${TEST_DIRECTORY%/*}/lib${LD_LIBRARY_PATH:+:$LD_LIBRARY_PATH}
\r
132 > +export LD_LIBRARY_PATH
\r
134 > # configure output
\r
135 > . $notmuch_path/sh.config || exit 1
\r
137 > diff --git a/test/test-lib.sh b/test/test-lib.sh
\r
138 > index 62e123d65aba..a7e6397c324e 100644
\r
139 > --- a/test/test-lib.sh
\r
140 > +++ b/test/test-lib.sh
\r
141 > @@ -1171,7 +1171,6 @@ test_emacs () {
\r
145 > - export LD_LIBRARY_PATH=$TEST_DIRECTORY/../lib
\r
146 > export PYTHONPATH=$TEST_DIRECTORY/../bindings/python
\r
148 > (echo "import sys; _orig_stdout=sys.stdout; sys.stdout=open('OUTPUT', 'w')"; cat) \
\r
149 > @@ -1179,7 +1178,6 @@ test_python() {
\r
153 > - export LD_LIBRARY_PATH=$TEST_DIRECTORY/../lib
\r
154 > MAIL_DIR=$MAIL_DIR ruby -I $TEST_DIRECTORY/../bindings/ruby> OUTPUT
\r
157 > @@ -1187,7 +1185,6 @@ test_C () {
\r
158 > exec_file="test${test_count}"
\r
159 > test_file="${exec_file}.c"
\r
160 > cat > ${test_file}
\r
161 > - export LD_LIBRARY_PATH=${TEST_DIRECTORY}/../lib
\r
162 > ${TEST_CC} ${TEST_CFLAGS} -I${TEST_DIRECTORY}/../lib -o ${exec_file} ${test_file} -L${TEST_DIRECTORY}/../lib/ -lnotmuch -ltalloc
\r
163 > echo "== stdout ==" > OUTPUT.stdout
\r
164 > echo "== stderr ==" > OUTPUT.stderr
\r
168 > _______________________________________________
\r
169 > notmuch mailing list
\r
170 > notmuch@notmuchmail.org
\r
171 > https://notmuchmail.org/mailman/listinfo/notmuch
\r