From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp0 ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms11 with LMTPS id ka91MIizTGBwWQAA0tVLHw (envelope-from ) for ; Sat, 13 Mar 2021 12:43:52 +0000 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp0 with LMTPS id qOvbK4izTGBjDwAA1q6Kng (envelope-from ) for ; Sat, 13 Mar 2021 12:43:52 +0000 Received: from mail.notmuchmail.org (nmbug.tethera.net [144.217.243.247]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 5186C21417 for ; Sat, 13 Mar 2021 13:43:52 +0100 (CET) Received: from nmbug.tethera.net (localhost [127.0.0.1]) by mail.notmuchmail.org (Postfix) with ESMTP id 166C126BB1; Sat, 13 Mar 2021 07:43:45 -0500 (EST) Received: from fethera.tethera.net (fethera.tethera.net [IPv6:2607:5300:60:c5::1]) by mail.notmuchmail.org (Postfix) with ESMTP id 6D19626A27 for ; Sat, 13 Mar 2021 07:43:42 -0500 (EST) Received: by fethera.tethera.net (Postfix, from userid 1001) id CF07E5FA96; Sat, 13 Mar 2021 07:43:40 -0500 (EST) Received: (nullmailer pid 3121189 invoked by uid 1000); Sat, 13 Mar 2021 12:43:39 -0000 From: David Bremner To: notmuch@notmuchmail.org Cc: David Bremner Subject: [PATCH] test: put shim at end of LD_PRELOAD path Date: Sat, 13 Mar 2021 08:43:37 -0400 Message-Id: <20210313124337.3121123-1-david@tethera.net> X-Mailer: git-send-email 2.30.1 MIME-Version: 1.0 Message-ID-Hash: JUKUZZ6DJT6EUXYKOXXQKRGUKS5LNHJ4 X-Message-ID-Hash: JUKUZZ6DJT6EUXYKOXXQKRGUKS5LNHJ4 X-MailFrom: bremner@tethera.net X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; header-match-notmuch.notmuchmail.org-0; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; suspicious-header X-Mailman-Version: 3.2.1 Precedence: list List-Id: "Use and development of the notmuch mail system." List-Help: List-Post: List-Subscribe: List-Unsubscribe: Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Migadu-Flow: FLOW_IN ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1615639432; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=opTtYge6PFiJDxnKLlizUv8CsRmOwwjReVOFwA4udq4=; b=H3GC6Gu5e0EjDvf/D8jgHYHizo/jTNsqE/1kLEnWoix7WxHs1Dr5LyFNGyqqlBKx/YVxtL UGU6dAh376XJvpsdWVAphyddBCl8KAkTS0Yvz7MopGA5QzhmiOCa8Ma9EP1hanoizpDg+B SwWaMA28hnaN8AQb0iRaMjLeOXmvXAawY/a3L9G0q3N7n3uqFKNnC4CKDaoEx3at3CmKnV sQGXtmVyRUS47IGixYBdij56Kg5uUbf33uOB4V2ZBe63VAAkKuHo9rJB+xKpVp+7A9TjaC 5QoyiStTb/18YFj8T7sMYgd9+Lt+t1AtyPkGy4XbefMeNqxeajhxPi3jgHGQsA== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1615639432; a=rsa-sha256; cv=none; b=bZq6oSfPK4ROHOUoxT2vHG2F6kR7DHtRF9fc7WRIpI18IDo7iU8vsZm2LETWkU5UYlrZrx lykcyMEcF/5YIoEZQH1OiygzqCB8CIh5+UlnGxSaAU+6XrDAld/VFrhrK73gnWxUzsA6av L+tbAQkoPik/MlmKz84Cf5ibJJbviD4I1Du8TCBWKx7OI0/ptWze7TlZIBFfN0nI9HHJh3 DtZ9vjMLB9T/2y2xGAM+S6DvgPCDfpHVo2mEw5NnIcBYqwCJyxawE58/AjbjhEB4L0qscH 7v6QOGgIh3vLSsrSIABamCzZx0yEJxOJgJFr3XCICyRq1i7dME90f8UzyeyHFA== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=none; dmarc=none; spf=pass (aspmx1.migadu.com: domain of notmuch-bounces@notmuchmail.org designates 144.217.243.247 as permitted sender) smtp.mailfrom=notmuch-bounces@notmuchmail.org X-Migadu-Spam-Score: -0.90 Authentication-Results: aspmx1.migadu.com; dkim=none; dmarc=none; spf=pass (aspmx1.migadu.com: domain of notmuch-bounces@notmuchmail.org designates 144.217.243.247 as permitted sender) smtp.mailfrom=notmuch-bounces@notmuchmail.org X-Migadu-Queue-Id: 5186C21417 X-Spam-Score: -0.90 X-Migadu-Scanner: scn0.migadu.com X-TUID: TupQ9N+aCZdX Certain tools like the address-sanitizer fail if they are not the first LD_PRELOADed library. It does not seem to matter for our shims, as long as they are loaded before libnotmuch. --- Using the address sanitizer with notmuch is still a manual process, but this allows one to manually LD_PRELOAD libasan to make some more tests pass. test/test-lib.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/test-lib.sh b/test/test-lib.sh index 29baa0c1..89e218df 100644 --- a/test/test-lib.sh +++ b/test/test-lib.sh @@ -1117,7 +1117,7 @@ notmuch_with_shim () { base_name="$1" shift shim_file="${base_name}.so" - LD_PRELOAD=./${shim_file}${LD_PRELOAD:+:$LD_PRELOAD} notmuch-shared "$@" + LD_PRELOAD=${LD_PRELOAD:+:$LD_PRELOAD}:./${shim_file} notmuch-shared "$@" } # Creates a script that counts how much time it is executed and calls -- 2.30.1