[R-pkg-devel] Macros in Rd files --- supplementary question.

Rolf Turner r.turner at auckland.ac.nz
Sat Nov 11 21:26:51 CET 2017


On 12/11/17 08:08, Georgi Boshnakov wrote:
> It is more subtle than that.
> \Sexpr triggers the creation of "partial Rd database" which becomes part of the built package (the tar.gz file), although what exactly happens may also depend on 'stage' options of the \Sexpr's.
> 
>> ... However when I do the "R CMD  build" thing, when it comes to the
>> "* building the PDF package manual"
>> step it says "Hmm ... looks like a package" (no shit, Sherlock!) and
>> emits a huge amount of verbose LaTeX diagnostics.
> 
> I have never seen  "* building the PDF package manual" from 'R CMD build', see below for a sample console output on Windows from a package which contains Rd macros and vignettes.

But did/do the macros have \Sexpr's in them?

> The messages you show seem to come from 'Rd2pdf'. Is it possible that you have some custom script that builds the manual, as well?

No.  I haven't.

Also some environment variable may be the culprit.

Don't think so.

Anyhow, the message from R CMD build --help very clearly says:

>>> Usage: R CMD build [options] pkgdirs
>>>
>>> Build R packages from package sources in the directories specified by
>>> ‘pkgdirs’
>>>
>>> Options:
>>>    -h, --help        print short help message and exit
>>>    -v, --version        print version info and exit
>>>
>>>    --force               force removal of INDEX file
>>>    --keep-empty-dirs     do not remove empty dirs
>>>    --no-build-vignettes  do not (re)build package vignettes
>>>    --no-manual           do not build the PDF manual even if \Sexprs are present
>>> ...
>>> ...
>>> ...

I think that's pretty definitive.

cheers,

Rolf

-- 
Technical Editor ANZJS
Department of Statistics
University of Auckland
Phone: +64-9-373-7599 ext. 88276



More information about the R-package-devel mailing list