Re: [PATCH 1/2] Add Google Inc. to AUTHORS as a contributor.
[notmuch-archives.git] / fb / b4355d25603815038bdda3b0413e4bcda3b521
1 Return-Path: <cworth@cworth.org>\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 olra.theworths.org (Postfix) with ESMTP id D6068431FBC;\r
6         Sat, 21 Nov 2009 19:49:00 -0800 (PST)\r
7 X-Virus-Scanned: Debian amavisd-new at olra.theworths.org\r
8 Received: from olra.theworths.org ([127.0.0.1])\r
9         by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024)\r
10         with ESMTP id ei4+DNwYN0QX; Sat, 21 Nov 2009 19:49:00 -0800 (PST)\r
11 Received: from cworth.org (localhost [127.0.0.1])\r
12         by olra.theworths.org (Postfix) with ESMTP id DCC4F431FAE;\r
13         Sat, 21 Nov 2009 19:48:59 -0800 (PST)\r
14 From: Carl Worth <cworth@cworth.org>\r
15 To: Mikhail Gusarov <dottedmag@dottedmag.net>, Chris Wilson\r
16         <chris@chris-wilson.co.uk>\r
17 In-Reply-To: <874oonpk5a.fsf@vertex.dottedmag>\r
18 References: <87my2fpty1.fsf@vertex.dottedmag>\r
19         <1258835540-21094-1-git-send-email-chris@chris-wilson.co.uk>\r
20         <874oonpk5a.fsf@vertex.dottedmag>\r
21 Date: Sun, 22 Nov 2009 04:48:48 +0100\r
22 Message-ID: <87fx872p9b.fsf@yoom.home.cworth.org>\r
23 MIME-Version: 1.0\r
24 Content-Type: text/plain; charset=us-ascii\r
25 Cc: notmuch@notmuchmail.org\r
26 Subject: Re: [notmuch] [PATCH] Makefile: Magic silent rules.\r
27 X-BeenThere: notmuch@notmuchmail.org\r
28 X-Mailman-Version: 2.1.12\r
29 Precedence: list\r
30 List-Id: "Use and development of the notmuch mail system."\r
31         <notmuch.notmuchmail.org>\r
32 List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,\r
33         <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>\r
34 List-Archive: <http://notmuchmail.org/pipermail/notmuch>\r
35 List-Post: <mailto:notmuch@notmuchmail.org>\r
36 List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>\r
37 List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,\r
38         <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
39 X-List-Received-Date: Sun, 22 Nov 2009 03:49:01 -0000\r
40 \r
41 On Sun, 22 Nov 2009 04:50:41 +0600, Mikhail Gusarov <dottedmag@dottedmag.net> wrote:\r
42 > Uhm. Now it eats much less :)\r
43\r
44 > $ make\r
45 > ...\r
46 >   GZIP        notmuch.1.gz\r
47 > /bin/sh: --rsyncable: not found\r
48 > make: *** [notmuch.1.gz] Error 127\r
49 > $\r
50\r
51 > $ make V=1\r
52 > ...\r
53 > rsyncable --stdout notmuch.1 > notmuch.1.gz\r
54 > /bin/sh: rsyncable: not found\r
55 > make: [notmuch.1.gz] Error 127 (ignored)\r
56 \r
57 The bug here was in using the GZIP variable assuming it would be a\r
58 program name. But since gzip expects it to be additional arguments, we\r
59 need to use a different name such as a "gzip" variable.\r
60 \r
61 Thanks for the original implementation, Chris. And thanks for the\r
62 testing, Mikhail.\r
63 \r
64 I've pushed the original plus the below on top.\r
65 \r
66 -Carl\r
67 \r
68 commit 1266d8511e9adc7296ec4ddbf609dec824b4c94f\r
69 Author: Carl Worth <cworth@cworth.org>\r
70 Date:   Sun Nov 22 04:45:16 2009 +0100\r
71 \r
72     Makefile: Fix to work even with GZIP environment variable set.\r
73     \r
74     The rule here was written to assume that if the GZIP environment\r
75     variable was set that it would be the gzip binary to execute,\r
76     (similar to the CC and CXX variables). But GZIP is actually used\r
77     to pass arguments to gzip, so we have to use a different name.\r
78 \r
79 diff --git a/Makefile b/Makefile\r
80 index 5d8f321..ae8bff1 100644\r
81 --- a/Makefile\r
82 +++ b/Makefile\r
83 @@ -4,7 +4,9 @@ CFLAGS=-O2\r
84  \r
85  # Additional programs that are used during the compilation process.\r
86  EMACS ?= emacs\r
87 -GZIP ?= gzip\r
88 +# Lowercase to avoid clash with GZIP environment variable for passing\r
89 +# arguments to gzip.\r
90 +gzip = gzip\r
91  \r
92  # Additional flags that we will append to whatever the user set.\r
93  # These aren't intended for the user to manipulate.\r
94 diff --git a/Makefile.local b/Makefile.local\r
95 index 5fd5d4f..b6d3db3 100644\r
96 --- a/Makefile.local\r
97 +++ b/Makefile.local\r
98 @@ -23,7 +23,7 @@ notmuch: $(notmuch_client_modules) lib/notmuch.a\r
99         $(call quiet,CXX) $^ $(LDFLAGS) -o $@\r
100  \r
101  notmuch.1.gz: notmuch.1\r
102 -       $(call quiet,GZIP) --stdout $^ > $@\r
103 +       $(call quiet,gzip) --stdout $^ > $@\r
104  \r
105  install: all notmuch.1.gz\r
106         for d in $(DESTDIR)$(prefix)/bin/ $(DESTDIR)$(prefix)/share/man/man1 \\r