Gentoo Archives: gentoo-commits

From: "André Erdmann" <dywi@×××××××.de>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] proj/R_overlay:master commit in: man/
Date: Tue, 10 Jul 2012 17:01:37
Message-Id: 1341939704.ef6225dc3fec998e73ec0db342bbf4b8481d84da.dywi@gentoo
1 commit: ef6225dc3fec998e73ec0db342bbf4b8481d84da
2 Author: André Erdmann <dywi <AT> mailerd <DOT> de>
3 AuthorDate: Tue Jul 10 17:01:44 2012 +0000
4 Commit: André Erdmann <dywi <AT> mailerd <DOT> de>
5 CommitDate: Tue Jul 10 17:01:44 2012 +0000
6 URL: http://git.overlays.gentoo.org/gitweb/?p=proj/R_overlay.git;a=commit;h=ef6225dc
7
8 man pages
9
10 ---
11 man/roverlay-deprules.5 | 173 +++++++++++++++++++++++++++++++++++++++++++++++
12 man/roverlay-repo.5 | 139 +++++++++++++++++++++++++++++++++++++
13 man/roverlay.1 | 7 +-
14 3 files changed, 315 insertions(+), 4 deletions(-)
15
16 diff --git a/man/roverlay-deprules.5 b/man/roverlay-deprules.5
17 new file mode 100644
18 index 0000000..2e1ce98
19 --- /dev/null
20 +++ b/man/roverlay-deprules.5
21 @@ -0,0 +1,173 @@
22 +.\" groff -Tascii -man
23 +.TH "ROVERLAY-DEPRULES" "5" "July 10 2012" "Linux/Gentoo?" "R Overlay"
24 +.SH "NAME"
25 +deprules \- R overlay dependency rule configuration
26 +.SH "SYNOPSIS"
27 +\fBsimple-deprules.conf\fR
28 +.SH "DESCRIPTION"
29 +A simple dependency rule file defines one or more rules
30 +that are used for dependency resolution in \fBroverlay(1)\fR.
31 +.PP
32 +A rule defines which \fIdep_string\fR read from an R package resolves
33 +to a specific \fIdependency\fR.
34 +\fIdependency\fR can be a \fBDEPEND atom\fR or \fBDynamic DEPEND\fR,
35 +see \fBebuild(5)\fR.
36 +\'The R programming language\',
37 +for example, should resolve to \'dev\-lang/R\'.
38 +Other dependencies such as packages from @system,
39 +should be ignored since they\'re always provided.
40 +This is also possible.
41 +
42 +.IP "\(bu simple rules"
43 +These rules are very simple and match a \fIdep_string\fR exactly.
44 +.IP "\(bu fuzzy rules"
45 +These rules try to find a match for \fIdep_string\fR using string interpolation, metrics and/or regex matches.
46 +.SS "RULE VARIANTS"
47 +.IP "\(bu normal"
48 +\fIdep_string\fR will be resolved as \fIdependency\fR.
49 +.IP "\(bu ignore"
50 +\fIdep_string\fR will be ignored if it matches an ignore rule.
51 +
52 +.SS "RULE STUBS"
53 +There\'s a special (shorter) syntax for dependencies
54 +that are resolved within the created overlay.
55 +For example, if your \fIOVERLAY_CATEGORY\fR is \'sci\-R\',
56 +\'zoo\' should be resolved as \'sci\-R/zoo\'.
57 +This rule can be written as a single word, \'zoo\'.
58 +The advantage is that you don\'t have to write the
59 +overlay category into the rule file.
60 +These stubs are called \fBselfdeps\fR.
61 +
62 +
63 +.SS "BASIC SYNTAX"
64 +.IP "\(bu rule that matches one \fIdep_string\fR"
65 +[\fIkeyword\fR and/or \fIdependency\fR] :: \fIdep_string\fR
66 +.br
67 +.IP "\(bu rule that matches multiple \fIdep_string\fRs"
68 +This replaces " :: \fIdep_string\fR" by a multiline variant
69 +.br
70 +[\fIkeyword\fR and/or \fIdependency\fR] \&{
71 +.br
72 +\& \fIdep_string\fR
73 +.br
74 +\& [\fIdep_string\fR]
75 +.br
76 +\& [\fIdep_string\fR]
77 +.br
78 +\& \&.\&.\&.
79 +.br
80 +\&}
81 +.br
82 +.IP "\fBselfdep\fR rule"
83 +[\fIkeyword\fR]\fIshort_dependency\fR
84 +.br
85 +where \fIshort_dependency\fR is a package name (\fBDEPEND atom\fR without version, category).
86 +This is the only way to specify selfdeps.
87 +
88 +.SS "ADDITIONAL SYNTAX"
89 +Comments start with \'#\'.
90 +.PP
91 +There are two special keywords that both cause reading a rule file to stop, \'#! BREAKPARSE\' and \'#! NOPARSE\'.
92 +The line must exactly be one of these keywords (no additional content at the end of the line).
93 +
94 +
95 +
96 +.SH "SIMPLE RULES"
97 +A simple rule resolves exact string matches (case-insensitive).
98 +.SS "SYNTAX"
99 +.IP "\(bu normal"
100 +\fIdependency\fR :: \fIdep_string\fR
101 +.IP "\(bu ignore"
102 +! :: \fIdep_string\fR
103 +.IP "\(bu selfdep, normal"
104 +\fIshort_dependency\fR
105 +.IP "\(bu selfdep, ignored"
106 +!\fIshort_dependency\fR
107 +
108 +.SH "FUZZY RULES"
109 +A fuzzy rule tries to resolve, i.e. "resolve \fIdep_string\fR as \fIdependency\fR if it \fIsomehow\fR matches a \fIfuzzy_string\fR".
110 +The \fIsomehow\fR is up to the implementation, it currently includes:
111 +.SS "EXACT MATCH"
112 +This is equal to the \fBSIMPLE RULES\fR
113 +.SS "VERSION\-RELATIVE MATCH"
114 +Uses regexes to identify \fIdep_string\fRs
115 +that only differ in the requested version (and/or version syntax).
116 +"R (\&>\&= 2.15)" and "R[2.10]", for instance, should be resolved as "dev\-lang/R".
117 +A single fuzzy\-rule "~dev\-lang/R :: R" does this and resolves them as
118 +"\&>=dev\-lang/R\-2.15" and "\&>=dev\-lang/R\-2.10", respectively.
119 +Note that this is just an example, \fBroverlay(1)\fR will filter out dependencies on
120 +dev\-lang/R when the version is \&<= the lowest version available in portage.
121 +.br
122 +In detail, this method matches if
123 +.br
124 +\& \fIdep_string\fR ~= \fIfuzzy_string\fR \&<\fIversion_statement\fR\&>,
125 +.br
126 +where \fIversion_statment\fR is something like \&>=2.10, \&!=0.9, 1.0, \&<5,
127 +optionally enclosed with braces ((), [], {}).
128 +Whitespace is ignored unless \fIversion_statment\fR is not enclosed,
129 +in which case some whitespace (more than zero chars) must exist between
130 +\fIfuzzy_string\fR and \fIversion_statment\fR.
131 +
132 +.SS SYNTAX
133 +Fuzzy rules use ~ and % as keyword.
134 +.IP "\(bu normal"
135 +\&~\fIdependency\fR :: \fIfuzzy_string\fR
136 +.IP "\(bu ignore"
137 +\&%\fIdependency\fR :: \fIfuzzy_string\fR
138 +.IP "\(bu selfdep"
139 +\&~\fIshort_dependency\fR
140 +.IP "\(bu selfdep, ignored"
141 +\&%\fIshort_dependency\fR
142 +
143 +.SH "EXAMPLES"
144 +Example 1:
145 +.RS 1
146 +A rule that matches many dependencies on dev\-lang/R,
147 +for example "r 2.12", "R(\&>= 2.14)", "R [\&<2.10]", "r{ !2.12 }", and "R".
148 +.RS 2
149 +
150 +\&~dev\-lang/R :: R
151 +.RE
152 +.RE
153 +.PP
154 +Example 2:
155 +.RS 1
156 +A rule that fuzzy-matches a zoo package selfdep.
157 +.RS 2
158 +
159 +\&~zoo
160 +.RE
161 +.RE
162 +.PP
163 +Example 3:
164 +.RS 1
165 +A standard self dep, resolves "tuneR", "tuner", ... as "sci\-R/tuneR"
166 +(\fIOVERLAY_CATEGORY\fR/tuneR).
167 +.RS 2
168 +
169 +\&tuneR
170 +.RE
171 +.RE
172 +.PP
173 +Example 4:
174 +.RS 1
175 +A simple multiline rule that ignores some text.
176 +This is a good way to deal with free-style text found in
177 +some R package DESCRIPTION files.
178 +.RS 2
179 +
180 +! :: {
181 +.RS 2
182 +see README
183 +.br
184 +read INSTALL
185 +.br
186 +[which can be downloaded from http://...]
187 +.br
188 +.RE
189 +}
190 +.RE
191 +.RE
192 +
193 +.SH "SEE ALSO"
194 +.BR "roverlay(1)"
195
196 diff --git a/man/roverlay-repo.5 b/man/roverlay-repo.5
197 new file mode 100644
198 index 0000000..c8e1270
199 --- /dev/null
200 +++ b/man/roverlay-repo.5
201 @@ -0,0 +1,139 @@
202 +.\" groff -Tascii -man
203 +.TH "ROVERLAY-REPO" "5" "July 10 2012" "Linux/Gentoo?" "R Overlay"
204 +.SH "NAME"
205 +roverlay-repo \- R overlay repo config file
206 +.SH "SYNOPSIS"
207 +.BR "repo.list"
208 +.SH "DESCRIPTION"
209 +A repo config file is used to define repositories, both local and remote, and
210 +uses ConfigParser syntax (known from .ini files).
211 +.SS "REPO ENTRIES"
212 +A repo entry describes where to find R packages that will be used for overlay creation,
213 +and optionally where and how to get the R packages (using \fBREPO TYPES\fR).
214 +It also defines how ebuilds can download the R packages (used as \fISRC_URI\fR variable in ebuilds).
215 +.SS "REPO TYPES"
216 +There are two types of repos, "rsync" and "local" ones:
217 +.IP "\(bu local repositories"
218 +A \fBlocal repo\fR represents a directory with R packages in it.
219 +It will never be modified (i.e. synced) and has no special options.
220 +.IP "\(bu rsync repositories"
221 +An \fBrsync repo\fR uses a local directory to sync with a remote.
222 +Its directory will be modified whenever syncing (using the rsync program).
223 +It behaves like a local repo if syncing is disabled.
224 +.br
225 +These rsync options are always passed to rsync:
226 +.br
227 +\fB
228 +\-\-links, \-\-safe-links, \-\-times, \-\-compress,
229 +\-\-dirs, \-\-prune-empty-dirs, \-\-force, \-\-delete,
230 +\-\-human-readable, \-\-stats, \-\-chmod=ugo=r,u+w,Dugo+
231 +\fR
232 +.PP
233 +.SH "VARIABLES"
234 +Each repository is introduced with [\fIsection_name\fR] and has to declare some options.
235 +.SS "common options"
236 +.TP
237 +.BR "src_uri" " = \fIuri\fR"
238 +This is used to determine the \fISRC_URI\fR variable used in ebuilds.
239 +\fIuri\fR usually starts with 'http://' which can be left out,
240 +"localhost/R-packages" is the same uri as "http://localhost/R-packages".
241 +Always required.
242 +.TP
243 +.BR "name" " = \fIrepo_name\fR"
244 +Specify a name for the repository.
245 +Optional, defaults to \fIsection_name\fR
246 +which should be fine in most cases. The repo name should not contain whitespace.
247 +.TP
248 +.BR "type" " = \fItype\fR"
249 +Set the repo type. Optional, defaults to rsync (see \fBREPO_TYPES\fR).
250 +.TP
251 +.BR "directory" " = \fIdirectory\fR"
252 +Set the local package directory.
253 +Optional, defaults to \fIDISTFILES_ROOT\fR/\fIname\fR
254 +(see \fIDISTFILES_ROOT\fR in \fBR\-overlay.conf\fR).
255 +
256 +.SS "special options for local repos"
257 +None.
258 +
259 +.SS "special options for rsync repos"
260 +.TP
261 +.BR "rsync_uri" " = \fIrsync_uri\fR"
262 +Set the uri used for downloading the R packages into \fIdirectory\fR.
263 +Always required.
264 +.TP
265 +.BR "recursive" " = yes"
266 +If set to 'yes': pass '\-\-recursive' to rsync.
267 +This is optional and not enabled by default 'cause downloading sub directories is not always desirable.
268 +In case of CRAN, this would download the whole R package archive and all R releases.
269 +.TP
270 +.BR "extra_rsync_opts" " = \fIopts\fR"
271 +A whitespace-separated list of extra options that will be passed to rsync.
272 +Useful to in-/exclude files/dirs, show progress while running rsync etc.
273 +Options must not contain whitespace/quote chars.
274 +Note that the options won't be verified - this is \fBtotally unsafe!\fR
275 +.SH "EXAMPLES"
276 +Example 1:
277 +.RS 1
278 +A local directory with packages in /var/www/R-packages
279 +that are available on your network via "http://package_host/R-packages".
280 +.RS 2
281 +
282 +[local_packages]
283 +.br
284 +type = local
285 +.br
286 +src_uri = http://package_host/R-packages
287 +.br
288 +directory = /var/www/R-packages
289 +.RE
290 +.RE
291 +.PP
292 +Example 2:
293 +.RS 1
294 +A local directory with packages manually downloaded from CRAN.
295 +The directory will be automatically set to \fIDISTFILES_ROOT\fR/CRAN/selected.
296 +.RS 2
297 +
298 +[CRAN/selected]
299 +.br
300 +type = local
301 +.br
302 +src_uri = http://cran.r-project.org/src/contrib
303 +.RE
304 +.RE
305 +.PP
306 +Example 3:
307 +.RS 1
308 +An rsync repo for CRAN's current packages (CRAN without archive).
309 +The local DISTFILES_ROOT dir will be set to \fIDISTFILES_ROOT\fR/CRAN/all.
310 +This needs about 2.5G disk space (as of July 2012).
311 +.RS 2
312 +
313 +[CRAN/all]
314 +.br
315 +src_uri = http://cran.r-project.org/src/contrib
316 +.br
317 +rsync_uri = cran.r-project.org::CRAN/src/contrib
318 +.RE
319 +.RE
320 +.PP
321 +Example 4:
322 +.RS 1
323 +A repo that selectively syncs packages from CRAN that start with 'r' or 'R'
324 +to \fIDISTFILES_ROOT\fR/CRAN/only_letter_R. This can be realized using \fIextra_rsync_opts\fR.
325 +Also showing progress during transfer.
326 +This needs about 300M disk space.
327 +.RS 2
328 +
329 +[CRAN/only_letter_R]
330 +.br
331 +src_uri = http://cran.r-project.org/src/contrib
332 +.br
333 +rsync_uri = cran.r-project.org::CRAN/src/contrib
334 +.br
335 +extra_rsync_opts = \-\-include=r* \-\-include=R* \-\-exclude=* \-\-progress
336 +.RE
337 +.RE
338 +
339 +.SH "SEE ALSO"
340 +.BR "roverlay(1)"
341
342 diff --git a/man/roverlay.1 b/man/roverlay.1
343 index ba8e24a..02c78ed 100644
344 --- a/man/roverlay.1
345 +++ b/man/roverlay.1
346 @@ -104,9 +104,8 @@ Run overlay creation with sync, all options (overlay name/dir,...) are read from
347 roverlay \-\-from \fIpkgdir\fR \-O \fIoverlay\fR \-N R_Overlay \-\-field-definition \fIfield_definition\fR \-D \fIdeprules\fR
348 Run overlay creation for packages from \fIpkgdir\fR and write the overlay named R_Overlay to \fIoverlay\fR.
349 Use the given \fIfield_definition\fR and \fIdeprules\fR files.
350 +.br
351 !!! This should do without a config file (FIXME)
352 .SH "SEE ALSO"
353 -.BR "R-overlay.conf(5)",
354 -.BR "roverlay-field_definition(5)",
355 -.BR "roverlay-repo(5)"
356 -
357 +.BR "roverlay\-repo(5)",
358 +.BR "roverlay\-deprules(5)"