Skip to content
Prev 6101 / 12125 Next

[R-pkg-devel] is R CMD build --compact-vignettes working as expected?

Dear all,

First, thank you to everyone who responded.

Let me be more specific about what I did, focusing on macOS (since I did 
most of this on Windows too):

(1) I observed the problem with the Rcmdr package, including version 
2.7-1, which is newly on CRAN. Presumably, it wouldn't be hard to 
duplicate what I did.

(2) I previously tried both --compact-vignettes="both", 
--compact-vignettes=both, and also just --compact-vignettes. R CMD build 
says that it's "* compacting vignettes and other PDF files", and R CMD 
check --as-cran doesn't complain, reporting "* checking sizes of PDF 
files under ?inst/doc? ... OK."

(3) Nothing changes when, following Duncan's advice, I set GS_QUALITY=screen

In the tarball built by R CMD build, the vignette in 
inst/doc/Getting-Started-with-the-Rcmdr.pdf is 1.6 MB. When I compacted 
the vignette with Adobe Acrobat, it was reduced to 395 KB.

Putting all of this together, I suspect that Acrobat may just do a 
better job than gs and qpdf.

Best,
  John
On 2020-10-08 12:06 p.m., Duncan Murdoch wrote: