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 DBF01431FBD for ; Tue, 6 May 2014 20:50:33 -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 lR5o1P9rvdQm for ; Tue, 6 May 2014 20:50:26 -0700 (PDT) Received: from smtp3.cs.Stanford.EDU (smtp3.cs.Stanford.EDU [171.64.64.27]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by olra.theworths.org (Postfix) with ESMTPS id 8B2DC431FAE for ; Tue, 6 May 2014 20:50:26 -0700 (PDT) Received: from c-24-11-133-78.hsd1.sc.comcast.net ([24.11.133.78] helo=jane.lan) by smtp3.cs.Stanford.EDU with esmtpsa (TLSv1:DHE-RSA-SEED-SHA:128) (Exim 4.80.1) (envelope-from ) id 1Whss9-0000I5-K4; Tue, 06 May 2014 20:50:22 -0700 From: Charles Celerier To: Notmuch Mail Subject: [PATCH v2 4/5] T360-symbol-hiding: Added code to support testing on Mac OS X. Date: Tue, 6 May 2014 23:50:14 -0400 Message-Id: <1399434615-28425-1-git-send-email-cceleri@cs.stanford.edu> X-Mailer: git-send-email 1.8.5.2 (Apple Git-48) In-Reply-To: <1399395748-44920-1-git-send-email-cceleri@cs.stanford.edu> References: <1399395748-44920-1-git-send-email-cceleri@cs.stanford.edu> X-Scan-Signature: 6b0537b5faa14548adc1759647fcb4de 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: Wed, 07 May 2014 03:50:34 -0000 The Mac OS X platform uses *.dylib object files instead of *.so object files for linking. Adding the path to notmuch.dylib to the end of DYLD_FALLBACK_LIBRARY_PATH has a similar effect to adding the path to notmuch.so to LD_LIBRARY_PATH on most Linux-based platforms (see dyld(1)). Signed-off-by: Charles Celerier --- test/T360-symbol-hiding.sh | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/test/T360-symbol-hiding.sh b/test/T360-symbol-hiding.sh index 636ec91..9239fc1 100755 --- a/test/T360-symbol-hiding.sh +++ b/test/T360-symbol-hiding.sh @@ -12,7 +12,14 @@ test_description='exception symbol hiding' . ./test-lib.sh run_test(){ - result=$(LD_LIBRARY_PATH="$TEST_DIRECTORY/../lib${LD_LIBRARY_PATH:+:$LD_LIBRARY_PATH}" $TEST_DIRECTORY/symbol-test 2>&1) + case $(uname -s) in + Darwin) + result=$(DYLD_FALLBACK_LIBRARY_PATH="$TEST_DIRECTORY/../lib${DYLD_FALLBACK_LIBRARY_PATH:+:$DYLD_FALLBACK_LIBRARY_PATH}" $TEST_DIRECTORY/symbol-test 2>&1) + ;; + *) + result=$(LD_LIBRARY_PATH="$TEST_DIRECTORY/../lib${LD_LIBRARY_PATH:+:$LD_LIBRARY_PATH}" $TEST_DIRECTORY/symbol-test 2>&1) + ;; + esac } output="A Xapian exception occurred opening database: Couldn't stat 'fakedb/.notmuch/xapian' -- 1.8.5.2 (Apple Git-48)