[PATCH] build-system: use a shell variable for TMPFILE in debian-snapshot
authorDavid Bremner <david@tethera.net>
Sun, 18 Dec 2011 03:16:51 +0000 (23:16 +2000)
committerW. Trevor King <wking@tremily.us>
Fri, 7 Nov 2014 17:41:00 +0000 (09:41 -0800)
7b/3003034d01077f1e71836ac0d4dc4e2cc60584 [new file with mode: 0644]

diff --git a/7b/3003034d01077f1e71836ac0d4dc4e2cc60584 b/7b/3003034d01077f1e71836ac0d4dc4e2cc60584
new file mode 100644 (file)
index 0000000..63ae807
--- /dev/null
@@ -0,0 +1,103 @@
+Return-Path: <bremner@tethera.net>\r
+X-Original-To: notmuch@notmuchmail.org\r
+Delivered-To: notmuch@notmuchmail.org\r
+Received: from localhost (localhost [127.0.0.1])\r
+       by olra.theworths.org (Postfix) with ESMTP id BEDAF431FD0\r
+       for <notmuch@notmuchmail.org>; Sat, 17 Dec 2011 19:17:07 -0800 (PST)\r
+X-Virus-Scanned: Debian amavisd-new at olra.theworths.org\r
+X-Spam-Flag: NO\r
+X-Spam-Score: -2.3\r
+X-Spam-Level: \r
+X-Spam-Status: No, score=-2.3 tagged_above=-999 required=5\r
+       tests=[RCVD_IN_DNSWL_MED=-2.3] autolearn=disabled\r
+Received: from olra.theworths.org ([127.0.0.1])\r
+       by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024)\r
+       with ESMTP id 59jHbzbZz8ci for <notmuch@notmuchmail.org>;\r
+       Sat, 17 Dec 2011 19:17:07 -0800 (PST)\r
+Received: from tempo.its.unb.ca (tempo.its.unb.ca [131.202.1.21])\r
+       (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits))\r
+       (No client certificate requested)\r
+       by olra.theworths.org (Postfix) with ESMTPS id 2F6F9431FB6\r
+       for <notmuch@notmuchmail.org>; Sat, 17 Dec 2011 19:17:07 -0800 (PST)\r
+Received: from zancas.localnet\r
+       (fctnnbsc36w-156034079193.pppoe-dynamic.High-Speed.nb.bellaliant.net\r
+       [156.34.79.193]) (authenticated bits=0)\r
+       by tempo.its.unb.ca (8.13.8/8.13.8) with ESMTP id pBI3GuC0027762\r
+       (version=TLSv1/SSLv3 cipher=AES256-SHA bits=256 verify=NO);\r
+       Sat, 17 Dec 2011 23:17:02 -0400\r
+Received: from bremner by zancas.localnet with local (Exim 4.77)\r
+       (envelope-from <bremner@tethera.net>)\r
+       id 1Rc7FA-00080L-7i; Sat, 17 Dec 2011 23:16:56 -0400\r
+From: David Bremner <david@tethera.net>\r
+To: notmuch@notmuchmail.org\r
+Subject: [PATCH] build-system: use a shell variable for TMPFILE in\r
+       debian-snapshot\r
+Date: Sat, 17 Dec 2011 23:16:51 -0400\r
+Message-Id: <1324178211-30739-1-git-send-email-david@tethera.net>\r
+X-Mailer: git-send-email 1.7.7.3\r
+In-Reply-To: <1324136185-4509-1-git-send-email-aaronecay@gmail.com>\r
+References: <1324136185-4509-1-git-send-email-aaronecay@gmail.com>\r
+Cc: David Bremner <bremner@debian.org>\r
+X-BeenThere: notmuch@notmuchmail.org\r
+X-Mailman-Version: 2.1.13\r
+Precedence: list\r
+List-Id: "Use and development of the notmuch mail system."\r
+       <notmuch.notmuchmail.org>\r
+List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,\r
+       <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>\r
+List-Archive: <http://notmuchmail.org/pipermail/notmuch>\r
+List-Post: <mailto:notmuch@notmuchmail.org>\r
+List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>\r
+List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,\r
+       <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
+X-List-Received-Date: Sun, 18 Dec 2011 03:17:08 -0000\r
+\r
+From: David Bremner <bremner@debian.org>\r
+\r
+Aaron Ecay points out in\r
+id:"1324136185-4509-1-git-send-email-aaronecay@gmail.com" that the\r
+mktemp in\r
+\r
+     debian-snapshot: TMPFILE := $(shell mktemp)\r
+\r
+Is being evaluated for every target. As best I can tell, this is\r
+because make is evaluating the right hand side, even though it is not\r
+doing the assignment.\r
+\r
+Of course, it isn't quite as nice to edit with the line continuations,\r
+but it is ideomatic make.\r
+---\r
+ Makefile.local |   15 ++++++++-------\r
+ 1 files changed, 8 insertions(+), 7 deletions(-)\r
+\r
+diff --git a/Makefile.local b/Makefile.local\r
+index 5108a0c..97f397f 100644\r
+--- a/Makefile.local\r
++++ b/Makefile.local\r
+@@ -139,15 +139,16 @@ pre-release:\r
+       mv $(TAR_FILE) $(DEB_TAR_FILE) releases\r
\r
+ .PHONY: debian-snapshot\r
+-debian-snapshot: TMPFILE := $(shell mktemp)\r
+ debian-snapshot:\r
+       make VERSION=$(VERSION) clean\r
+-      cp debian/changelog $(TMPFILE)\r
+-      EDITOR=/bin/true dch -b -v $(VERSION)+1 -D UNRELEASED 'test build, not for upload'\r
+-      echo '3.0 (native)' > debian/source/format\r
+-      debuild -us -uc\r
+-      mv -f $(TMPFILE) debian/changelog\r
+-      echo '3.0 (quilt)' > debian/source/format\r
++      TMPFILE=$$(mktemp /tmp/notmuch.XXXXXX);         \\r
++        cp debian/changelog $${TMPFILE};              \\r
++        EDITOR=/bin/true dch -b -v $(VERSION)+1       \\r
++          -D UNRELEASED 'test build, not for upload'; \\r
++        echo '3.0 (native)' > debian/source/format;   \\r
++        debuild -us -uc;                              \\r
++        mv -f $${TMPFILE} debian/changelog;           \\r
++        echo '3.0 (quilt)' > debian/source/format\r
\r
+ .PHONY: release-message\r
+ release-message:\r
+-- \r
+1.7.7.3\r
+\r