Re: [PATCH v4 02/16] Move crypto.c into libutil
[notmuch-archives.git] / 2e / 267698a2a5b3554bddd7b8d8affdce45674086
1 Return-Path: <tomi.ollila@iki.fi>\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 1AEE3431FAF\r
6         for <notmuch@notmuchmail.org>; Mon, 13 Jan 2014 13:06:12 -0800 (PST)\r
7 X-Virus-Scanned: Debian amavisd-new at olra.theworths.org\r
8 X-Spam-Flag: NO\r
9 X-Spam-Score: 0\r
10 X-Spam-Level: \r
11 X-Spam-Status: No, score=0 tagged_above=-999 required=5 tests=[none]\r
12         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 UJkEe6XRCP1h for <notmuch@notmuchmail.org>;\r
16         Mon, 13 Jan 2014 13:06:08 -0800 (PST)\r
17 Received: from guru.guru-group.fi (guru.guru-group.fi [46.183.73.34])\r
18         by olra.theworths.org (Postfix) with ESMTP id E43D2431FAE\r
19         for <notmuch@notmuchmail.org>; Mon, 13 Jan 2014 13:06:07 -0800 (PST)\r
20 Received: from guru.guru-group.fi (localhost [IPv6:::1])\r
21         by guru.guru-group.fi (Postfix) with ESMTP id 94AF4100086;\r
22         Mon, 13 Jan 2014 23:06:03 +0200 (EET)\r
23 From: Tomi Ollila <tomi.ollila@iki.fi>\r
24 To: David Bremner <david@tethera.net>, notmuch@notmuchmail.org\r
25 Subject: Re: [PATCH 2/3] man: partial conversion to pod.\r
26 In-Reply-To: <1388921950-5017-3-git-send-email-david@tethera.net>\r
27 References: <1366852752-3584-1-git-send-email-david@tethera.net>\r
28         <1388921950-5017-1-git-send-email-david@tethera.net>\r
29         <1388921950-5017-3-git-send-email-david@tethera.net>\r
30 User-Agent: Notmuch/0.17+34~g98b959f (http://notmuchmail.org) Emacs/24.3.1\r
31         (x86_64-unknown-linux-gnu)\r
32 Date: Mon, 13 Jan 2014 23:06:03 +0200\r
33 Message-ID: <m2mwizoamc.fsf@guru.guru-group.fi>\r
34 MIME-Version: 1.0\r
35 Content-Type: text/plain\r
36 Cc: David Bremner <bremner@debian.org>\r
37 X-BeenThere: notmuch@notmuchmail.org\r
38 X-Mailman-Version: 2.1.13\r
39 Precedence: list\r
40 List-Id: "Use and development of the notmuch mail system."\r
41         <notmuch.notmuchmail.org>\r
42 List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,\r
43         <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>\r
44 List-Archive: <http://notmuchmail.org/pipermail/notmuch>\r
45 List-Post: <mailto:notmuch@notmuchmail.org>\r
46 List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>\r
47 List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,\r
48         <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
49 X-List-Received-Date: Mon, 13 Jan 2014 21:06:12 -0000\r
50 \r
51 David Bremner <david@tethera.net> writes:\r
52 \r
53 > From: David Bremner <bremner@debian.org>\r
54 >\r
55 > This allows generation of man page and info document from the same source.\r
56 > It is also a bit more friendly to edit for most people.\r
57 \r
58 IMHO it is good idea to have common format where to produce man, info &\r
59 html files. If we're going to need pandoc then the question of source\r
60 format explodes with choices...\r
61 \r
62 \r
63 > The conversion was done as follows:\r
64 >\r
65 >  % groff -e -mandoc -Tascii -rHY=0 $* | rman -f POD | sed  -e '/./,/^$/!d' -e 's/\r
66 >\r
67 > Some small hand-editing of the .pod may be needed afterwards.\r
68 > ---\r
69 >  INSTALL                         |   6 +\r
70 >  configure                       |  12 ++\r
71 >  info/Makefile.local             |  25 +++-\r
72 >  man/Makefile.local              |  19 ++-\r
73 >  man/man1/notmuch.1              | 190 ----------------------------\r
74 >  man/man7/notmuch-search-terms.7 | 269 ----------------------------------------\r
75 >  pod/notmuch-search-terms.pod    | 235 +++++++++++++++++++++++++++++++++++\r
76 >  pod/notmuch.pod                 | 155 +++++++++++++++++++++++\r
77 >  8 files changed, 448 insertions(+), 463 deletions(-)\r
78 >  delete mode 100644 man/man1/notmuch.1\r
79 >  delete mode 100644 man/man7/notmuch-search-terms.7\r
80 >  create mode 100644 pod/notmuch-search-terms.pod\r
81 >  create mode 100644 pod/notmuch.pod\r
82 >\r
83 > diff --git a/INSTALL b/INSTALL\r
84 > index 451bf05..697b7b2 100644\r
85 > --- a/INSTALL\r
86 > +++ b/INSTALL\r
87 > @@ -60,6 +60,12 @@ Talloc which are each described below:\r
88 >  \r
89 >       Talloc is available from http://talloc.samba.org/\r
90 >  \r
91 > +     pod2man\r
92 > +     -------\r
93 > +\r
94 > +     Some of the documentation is built with pod2man. This is part\r
95 > +     of the standard Perl distribution since Perl 5.6.0\r
96 > +\r
97 >       texinfo\r
98 >       -------\r
99 >  \r
100 > diff --git a/configure b/configure\r
101 > index e75c1d4..6dadbaa 100755\r
102 > --- a/configure\r
103 > +++ b/configure\r
104 > @@ -389,6 +389,15 @@ else\r
105 >      have_emacs=0\r
106 >  fi\r
107 >  \r
108 > +printf "Checking for pod2man... "\r
109 > +if pod2man --help > /dev/null 2>&1; then\r
110 > +    printf "Yes.\n"\r
111 > +    have_pod2man=1\r
112 > +else\r
113 > +    printf "No (man page install may fail)\n"\r
114 > +    have_pod2man=0\r
115 > +fi\r
116 > +\r
117 >  printf "Checking for makeinfo... "\r
118 >  if makeinfo --version > /dev/null 2>&1; then\r
119 >      printf "Yes.\n"\r
120 > @@ -768,6 +777,9 @@ HAVE_MAKEINFO = ${have_makeinfo}\r
121 >  # Whether there's an install-info binary available\r
122 >  HAVE_INSTALLINFO = ${have_installinfo}\r
123 >  \r
124 > +# Is pod2man in the path?\r
125 > +HAVE_POD2MAN = ${have_pod2man}\r
126 > +\r
127 >  # where to install info files\r
128 >  \r
129 >  INFODIR = ${INFODIR}\r
130 > diff --git a/info/Makefile.local b/info/Makefile.local\r
131 > index 55e9740..cca891a 100644\r
132 > --- a/info/Makefile.local\r
133 > +++ b/info/Makefile.local\r
134 > @@ -2,10 +2,14 @@\r
135 >  \r
136 >  dir := info\r
137 >  \r
138 > +man_texi :=  $(dir)/notmuch.texi $(dir)/notmuch-search-terms.texi\r
139 > +man_info := $(man_texi:.texi=.info)\r
140 > +man_entry := $(man_texi:.texi=.entry)\r
141 > +\r
142 >  texi_sources :=  $(dir)/notmuch-emacs.texi\r
143 >  emacs_info := $(texi_sources:.texi=.info)\r
144 >  \r
145 > -info := $(emacs_info)\r
146 > +info := $(emacs_info) $(man_info)\r
147 >  \r
148 >  ifeq ($(HAVE_MAKEINFO),1)\r
149 >  all: $(info)\r
150 > @@ -15,11 +19,23 @@ ifeq ($(HAVE_INSTALLINFO),1)\r
151 >  install: install-info\r
152 >  endif\r
153 >  \r
154 > -%.info: %.texi\r
155 > +%.entry: ../pod/%.pod\r
156 > +     printf "@dircategory Notmuch\n@direntry\n" > $@\r
157 > +     printf "* %s: (%s). " $(*F) $(*F) >> $@\r
158 > +     podselect -section Name $< | \\r
159 > +       perl -n -e  's/notmuch.* - (.*)/\u\L$$1/ && print' >> $@\r
160 > +     printf "@end direntry\n" >> $@\r
161 > +\r
162 > +%.info: %.texi %.entry\r
163 >       makeinfo --no-split -o $@ $<\r
164 >  \r
165 >  $(dir)/notmuch-emacs.info: $(dir)/notmuch-emacs.texi $(dir)/version.texi\r
166 \r
167 > +%.texi: ../pod/%.pod\r
168 > +     # a nasty hack, but the nicer ways seem to have bugs.\r
169 > +     pod2texi  $< | \\r
170 > +        sed 's/@node Top/@include $(*F).entry\n@node Top/' > $@\r
171 \r
172 This usage of pipeline above is problematic as if pod2texi returns nonzero\r
173 it is shadowed by return value of sed. Therefore a temporary file is\r
174 needed for this kind of operation.\r
175 \r
176 \r
177 Tomi\r