1 Return-Path: <jani@nikula.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 B1FB4431FAF
\r
6 for <notmuch@notmuchmail.org>; Sun, 4 Nov 2012 13:31:09 -0800 (PST)
\r
7 X-Virus-Scanned: Debian amavisd-new at olra.theworths.org
\r
11 X-Spam-Status: No, score=-0.7 tagged_above=-999 required=5
\r
12 tests=[RCVD_IN_DNSWL_LOW=-0.7] autolearn=disabled
\r
13 Received: from olra.theworths.org ([127.0.0.1])
\r
14 by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024)
\r
15 with ESMTP id i6-M9UeVubuo for <notmuch@notmuchmail.org>;
\r
16 Sun, 4 Nov 2012 13:31:08 -0800 (PST)
\r
17 Received: from mail-la0-f53.google.com (mail-la0-f53.google.com
\r
18 [209.85.215.53]) (using TLSv1 with cipher RC4-SHA (128/128 bits))
\r
19 (No client certificate requested)
\r
20 by olra.theworths.org (Postfix) with ESMTPS id 30E51431FAE
\r
21 for <notmuch@notmuchmail.org>; Sun, 4 Nov 2012 13:31:08 -0800 (PST)
\r
22 Received: by mail-la0-f53.google.com with SMTP id l5so4032774lah.26
\r
23 for <notmuch@notmuchmail.org>; Sun, 04 Nov 2012 13:31:06 -0800 (PST)
\r
24 X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
\r
25 d=google.com; s=20120113;
\r
26 h=from:to:cc:subject:in-reply-to:references:user-agent:date
\r
27 :message-id:mime-version:content-type:x-gm-message-state;
\r
28 bh=bbpMIAwdgMs9SVkAwcb7H64G9NBC6+fAu+LsrFEvk80=;
\r
29 b=bKs1V/duePndDdrOYG/o0umd5YaE2HKPM3d2qddaJrf8lXK2HsYnVT5yqvhAM5C20O
\r
30 tx/bdTCw1ZdIg1mt2AHOetgEnHTZkLSmLTP4FO86/9bDyqQlyPCqT3rN+DesSLWXexDE
\r
31 8TrCtPZcGlayUsxfp4OYnkM45o4+ulzzjMSHdlgRTx8WEveNm5DgIbcbjV11byH4dgLt
\r
32 f502PJQ2M5c+HB9q6Q9GbSDsl29ed307fvOaxQI5DxHTN/KjOFDBGzRgyLzDzEax8CAm
\r
33 eq8CRz4VLI7b2mQegfVRCU8k8UNS+tjnFDu1PcPdlt6TAXHXKkWNXpflGeXAeYS42hKE
\r
35 Received: by 10.112.102.132 with SMTP id fo4mr3142469lbb.111.1352064666604;
\r
36 Sun, 04 Nov 2012 13:31:06 -0800 (PST)
\r
37 Received: from localhost (dsl-hkibrasgw4-fe51df00-27.dhcp.inet.fi.
\r
39 by mx.google.com with ESMTPS id y10sm5099287lbg.4.2012.11.04.13.31.03
\r
40 (version=SSLv3 cipher=OTHER); Sun, 04 Nov 2012 13:31:04 -0800 (PST)
\r
41 From: Jani Nikula <jani@nikula.org>
\r
42 To: Blake Jones <blakej@foo.net>, notmuch@notmuchmail.org
\r
43 Subject: Re: [PATCH 05/10] install: check for non-SysV version (Solaris
\r
45 In-Reply-To: <1351998962-25135-6-git-send-email-blakej@foo.net>
\r
46 References: <1351998962-25135-1-git-send-email-blakej@foo.net>
\r
47 <1351998962-25135-6-git-send-email-blakej@foo.net>
\r
48 User-Agent: Notmuch/0.14+81~g1924356 (http://notmuchmail.org) Emacs/23.4.1
\r
50 Date: Sun, 04 Nov 2012 23:31:02 +0200
\r
51 Message-ID: <87d2ztf42x.fsf@nikula.org>
\r
53 Content-Type: text/plain; charset=us-ascii
\r
55 ALoCoQlZMSfsSygBXJD1WiS5WDvBs8B/a4euhl4DJCnWrCgih12F7fobliZH66EnaDDdQGWKryVL
\r
56 X-BeenThere: notmuch@notmuchmail.org
\r
57 X-Mailman-Version: 2.1.13
\r
59 List-Id: "Use and development of the notmuch mail system."
\r
60 <notmuch.notmuchmail.org>
\r
61 List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,
\r
62 <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>
\r
63 List-Archive: <http://notmuchmail.org/pipermail/notmuch>
\r
64 List-Post: <mailto:notmuch@notmuchmail.org>
\r
65 List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>
\r
66 List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,
\r
67 <mailto:notmuch-request@notmuchmail.org?subject=subscribe>
\r
68 X-List-Received-Date: Sun, 04 Nov 2012 21:31:09 -0000
\r
70 On Sun, 04 Nov 2012, Blake Jones <blakej@foo.net> wrote:
\r
71 > Solaris ships a program called "install" in /usr/sbin, which performs a
\r
72 > task that's fairly similar to the GNU and BSD "install" programs but
\r
73 > which uses very different command line arguments. In particular, if it
\r
74 > is invoked without "-c", "-f", or "-n", it will search the target
\r
75 > directory for a file with the same name as the one being installed, and
\r
76 > it will only install the file if it finds a matching name. More
\r
77 > excitingly, if it doesn't find a match, it will look in /bin, /usr/bin,
\r
78 > /etc, /lib, and /usr/lib and try to do the same there.
\r
80 > The standard workaround for this is to use GNU install.
\r
81 > It is available via the standard Solaris packaging system (in
\r
82 > "file/gnu-coreutils"), and installs itself as /usr/bin/ginstall.
\r
84 > This patch adds a check to "configure" to see if "install" behaves in a
\r
85 > way that's compatible with GNU and BSD install, and if not, it uses a
\r
86 > program called "ginstall" instead. It also modifies "configure" to set
\r
87 > the $(INSTALL) variable, and changes various Makefiles to use it.
\r
89 > Makefile.local | 2 +-
\r
90 > completion/Makefile.local | 4 ++--
\r
91 > configure | 19 +++++++++++++++++++
\r
92 > emacs/Makefile.local | 6 +++---
\r
93 > lib/Makefile.local | 4 ++--
\r
94 > man/Makefile.local | 6 +++---
\r
95 > vim/Makefile | 6 ++----
\r
96 > 7 files changed, 32 insertions(+), 15 deletions(-)
\r
98 > diff --git a/Makefile.local b/Makefile.local
\r
99 > index 2b91946..7ccb1cd 100644
\r
100 > --- a/Makefile.local
\r
101 > +++ b/Makefile.local
\r
102 > @@ -286,7 +286,7 @@ notmuch-shared: $(notmuch_client_modules) lib/$(LINKER_NAME)
\r
104 > install: all install-man
\r
105 > mkdir -p "$(DESTDIR)$(prefix)/bin/"
\r
106 > - install notmuch-shared "$(DESTDIR)$(prefix)/bin/notmuch"
\r
107 > + $(INSTALL) notmuch-shared "$(DESTDIR)$(prefix)/bin/notmuch"
\r
108 > ifeq ($(MAKECMDGOALS), install)
\r
110 > @echo "Notmuch is now installed to $(DESTDIR)$(prefix)"
\r
111 > diff --git a/completion/Makefile.local b/completion/Makefile.local
\r
112 > index dfc1271..a648a78 100644
\r
113 > --- a/completion/Makefile.local
\r
114 > +++ b/completion/Makefile.local
\r
115 > @@ -14,9 +14,9 @@ install-$(dir):
\r
117 > ifeq ($(WITH_BASH),1)
\r
118 > mkdir -p "$(DESTDIR)$(bash_completion_dir)"
\r
119 > - install -m0644 $(bash_script) "$(DESTDIR)$(bash_completion_dir)/notmuch"
\r
120 > + $(INSTALL) -m0644 $(bash_script) "$(DESTDIR)$(bash_completion_dir)/notmuch"
\r
122 > ifeq ($(WITH_ZSH),1)
\r
123 > mkdir -p "$(DESTDIR)$(zsh_completion_dir)"
\r
124 > - install -m0644 $(zsh_script) "$(DESTDIR)$(zsh_completion_dir)/_notmuch"
\r
125 > + $(INSTALL) -m0644 $(zsh_script) "$(DESTDIR)$(zsh_completion_dir)/_notmuch"
\r
127 > diff --git a/configure b/configure
\r
128 > index 5c5139f..dae837e 100755
\r
131 > @@ -591,6 +591,21 @@ for flag in -Wmissing-declarations; do
\r
133 > printf "\n\t${WARN_CFLAGS}\n"
\r
135 > +INSTALL="install"
\r
136 > +printf "Checking for working \"install\" program... "
\r
139 This doesn't feel like a hot idea. Don't tell me you'd need to create a
\r
140 compatibility script for using mktemp --tmpdir too...
\r
142 Or how about just always using ginstall on Solaris?
\r
150 > +if install 1 dest > /dev/null 2>&1 ; then
\r
151 > + printf "\"install\" works fine.\n"
\r
153 > + INSTALL="ginstall"
\r
154 > + printf "using \"ginstall\".\n"
\r
159 > rm -f minimal minimal.c
\r
162 > @@ -777,4 +792,8 @@ CONFIGURE_CXXFLAGS = -DHAVE_GETLINE=\$(HAVE_GETLINE) \$(GMIME_CFLAGS) \\
\r
163 > -DSTD_ASCTIME=\$(STD_ASCTIME)
\r
164 > CONFIGURE_LDFLAGS = \$(GMIME_LDFLAGS) \$(TALLOC_LDFLAGS) \$(XAPIAN_LDFLAGS) \\
\r
165 > \$(LIBNSL_LDFLAGS)
\r
167 > +# Which "install" program to use
\r
168 > +INSTALL = ${INSTALL}
\r
171 > diff --git a/emacs/Makefile.local b/emacs/Makefile.local
\r
172 > index fb82247..ee778cb 100644
\r
173 > --- a/emacs/Makefile.local
\r
174 > +++ b/emacs/Makefile.local
\r
175 > @@ -36,11 +36,11 @@ endif
\r
176 > .PHONY: install-emacs
\r
178 > mkdir -p "$(DESTDIR)$(emacslispdir)"
\r
179 > - install -m0644 $(emacs_sources) "$(DESTDIR)$(emacslispdir)"
\r
180 > + $(INSTALL) -m0644 $(emacs_sources) "$(DESTDIR)$(emacslispdir)"
\r
181 > ifeq ($(HAVE_EMACS),1)
\r
182 > - install -m0644 $(emacs_bytecode) "$(DESTDIR)$(emacslispdir)"
\r
183 > + $(INSTALL) -m0644 $(emacs_bytecode) "$(DESTDIR)$(emacslispdir)"
\r
185 > mkdir -p "$(DESTDIR)$(emacsetcdir)"
\r
186 > - install -m0644 $(emacs_images) "$(DESTDIR)$(emacsetcdir)"
\r
187 > + $(INSTALL) -m0644 $(emacs_images) "$(DESTDIR)$(emacsetcdir)"
\r
189 > CLEAN := $(CLEAN) $(emacs_bytecode)
\r
190 > diff --git a/lib/Makefile.local b/lib/Makefile.local
\r
191 > index 7785944..0c6b258 100644
\r
192 > --- a/lib/Makefile.local
\r
193 > +++ b/lib/Makefile.local
\r
194 > @@ -89,11 +89,11 @@ install: install-$(dir)
\r
196 > install-$(dir): $(dir)/$(LIBNAME)
\r
197 > mkdir -p "$(DESTDIR)$(libdir)/"
\r
198 > - install -m0644 "$(lib)/$(LIBNAME)" "$(DESTDIR)$(libdir)/"
\r
199 > + $(INSTALL) -m0644 "$(lib)/$(LIBNAME)" "$(DESTDIR)$(libdir)/"
\r
200 > ln -sf $(LIBNAME) "$(DESTDIR)$(libdir)/$(SONAME)"
\r
201 > ln -sf $(LIBNAME) "$(DESTDIR)$(libdir)/$(LINKER_NAME)"
\r
202 > mkdir -p "$(DESTDIR)$(includedir)"
\r
203 > - install -m0644 "$(srcdir)/$(lib)/notmuch.h" "$(DESTDIR)$(includedir)/"
\r
204 > + $(INSTALL) -m0644 "$(srcdir)/$(lib)/notmuch.h" "$(DESTDIR)$(includedir)/"
\r
205 > $(LIBRARY_INSTALL_POST_COMMAND)
\r
207 > SRCS := $(SRCS) $(libnotmuch_c_srcs) $(libnotmuch_cxx_srcs)
\r
208 > diff --git a/man/Makefile.local b/man/Makefile.local
\r
209 > index 72e2a18..07dcf4c 100644
\r
210 > --- a/man/Makefile.local
\r
211 > +++ b/man/Makefile.local
\r
212 > @@ -38,9 +38,9 @@ install-man: $(COMPRESSED_MAN)
\r
213 > mkdir -p "$(DESTDIR)$(mandir)/man1"
\r
214 > mkdir -p "$(DESTDIR)$(mandir)/man5"
\r
215 > mkdir -p "$(DESTDIR)$(mandir)/man7"
\r
216 > - install -m0644 $(MAN1_GZ) $(DESTDIR)/$(mandir)/man1
\r
217 > - install -m0644 $(MAN5_GZ) $(DESTDIR)/$(mandir)/man5
\r
218 > - install -m0644 $(MAN7_GZ) $(DESTDIR)/$(mandir)/man7
\r
219 > + $(INSTALL) -m0644 $(MAN1_GZ) $(DESTDIR)/$(mandir)/man1
\r
220 > + $(INSTALL) -m0644 $(MAN5_GZ) $(DESTDIR)/$(mandir)/man5
\r
221 > + $(INSTALL) -m0644 $(MAN7_GZ) $(DESTDIR)/$(mandir)/man7
\r
222 > cd $(DESTDIR)/$(mandir)/man1 && ln -sf notmuch.1.gz notmuch-setup.1.gz
\r
224 > update-man-versions: $(MAN_SOURCE)
\r
225 > diff --git a/vim/Makefile b/vim/Makefile
\r
226 > index f17bebf..7ceba7a 100644
\r
227 > --- a/vim/Makefile
\r
228 > +++ b/vim/Makefile
\r
229 > @@ -5,8 +5,6 @@ files = plugin/notmuch.vim \
\r
230 > prefix = $(HOME)/.vim
\r
231 > destdir = $(prefix)/plugin
\r
233 > -INSTALL = install -D -m644
\r
238 > @@ -17,7 +15,7 @@ help:
\r
239 > @echo " make symlink - create symlinks in ~/.vim (useful for development)"
\r
242 > - @for x in $(files); do $(INSTALL) $(CURDIR)/$$x $(prefix)/$$x; done
\r
243 > + @for x in $(files); do $(INSTALL) -D -m644 $(CURDIR)/$$x $(prefix)/$$x; done
\r
245 > -link symlink: INSTALL = ln -fs
\r
246 > link symlink: install
\r
247 > + @for x in $(files); do ln -fs $(CURDIR)/$$x $(prefix)/$$x; done
\r
251 > _______________________________________________
\r
252 > notmuch mailing list
\r
253 > notmuch@notmuchmail.org
\r
254 > http://notmuchmail.org/mailman/listinfo/notmuch
\r