[Rd] R CMD build now removes empty dirs
Hervé Pagès
hpages at fhcrc.org
Mon Apr 11 02:05:25 CEST 2011
Hi Henrik,
Just to clarify, you still have the ability of installing directory
structures that are partly empty. Actually 'R CMD INSTALL pkgpath/'
does this. And if srctarball.tar.gz contains empty dirs,
'R CMD INSTALL srctarball.tar.gz' will also keep them.
The problem is that *by default* 'R CMD build' removes those empty
dirs, unless you specify --keep-empty-dirs
The fact that 'R CMD build' and 'R CMD INSTALL' now have different
default behaviors is really a bad thing since when I'm working on
a package I typically do not use 'R CMD build' before I install it.
I use 'R CMD INSTALL' directly on the package source tree.
So everything looks ok to me because then empty dirs are installed.
It's only later when I build the source tarball that it will be
broken.
It's not just --keep-empty-dirs, it's also --resave-data. These
new options don't do the right thing by default and they are not
even consistent between 'R CMD build' and 'R CMD INSTALL'.
Cheers,
H.
On 11-03-30 08:04 PM, Henrik Bengtsson wrote:
> I am also in favor for keeping the ability of installing directory
> structures that are partly empty. I've used it before to setup
> templates that can conveniently be copied recursively to a local path.
> I did noticed that R CMD INSTALL gave a warning about empty
> directories before (or was it a NOTE by R CMD check?).
>
> /Henrik
>
> On Tue, Mar 29, 2011 at 11:56 PM, Pages, Herve<hpages at fhcrc.org> wrote:
>> Hi,
>>
>> It's unfortunate that with recent revisions of R 2.13 (this
>> appeared in revision 54640, March 2), 'R CMD build' now removes
>> empty dirs in the package. People might have good reasons for
>> having empty dirs in their packages. For example, in Bioconductor,
>> we have some tools to automatically generate annotation packages
>> and those tools are implemented in software packages that use
>> templates for the annotation packages to be generated. Those
>> package templates are stored under the inst/ folder of the
>> software package. One of those software packages is the
>> AnnotationDbi package: it contains 41 package templates under
>> inst/:
>>
>> [hpages at latitude Rpacks]$ ls AnnotationDbi/inst/AnnDbPkg-templates/
>> AFFYHUEX.DB CHIMP.DB MALARIA.DB WORM.DB
>> ANOPHELES.DB COELICOLOR.DB MOUSECHIP.DB XENOPUSCHIP.DB
>> ARABIDOPSISCHIP.DB ECOLICHIP.DB MOUSE.DB XENOPUS.DB
>> ARABIDOPSIS.DB ECOLI.DB ORGANISM.DB YEASTCHIP.DB
>> BASEPKG.DB FLYCHIP.DB PFAM.DB YEAST.DB
>> BOVINECHIP.DB FLY.DB PIGCHIP.DB YEASTNCBI.DB
>> BOVINE.DB GO.DB PIG.DB ZEBRAFISHCHIP.DB
>> CANINECHIP.DB HUMANCHIP.DB RATCHIP.DB ZEBRAFISH.DB
>> CANINE.DB HUMAN.DB RAT.DB
>> CHICKENCHIP.DB INPARANOID.DB RHESUS.DB
>> CHICKEN.DB KEGG.DB WORMCHIP.DB
>>
>> Those package templates are just the skeletons of the hundreds of
>> annotation packages that we generate. Of course, each of them contains
>> empty subfolders.
>>
>> Having 'R CMD build' remove those empty subfolders breaks all the
>> tools that make use of those package templates.
>>
>> Maybe I've missed it but I didn't see any mention of this "feature"
>> on this list and the fact that it was added only 6 weeks before the
>> next R and Bioconductor releases is only making this worse.
>>
>> I hope this "feature" can be reverted. Why would people or our build
>> system need to start using R CMD build --keep-empty-dirs just to get
>> a source tarball right?
>>
>> Thanks,
>> H.
>>
>> PS: This page
>>
>> http://stat.ethz.ch/R-manual/R-devel/doc/html/NEWS.html
>>
>> (referenced from http://developer.r-project.org/) has not been
>> updated for months.
>>
>> ______________________________________________
>> R-devel at r-project.org mailing list
>> https://stat.ethz.ch/mailman/listinfo/r-devel
>>
--
Hervé Pagès
Program in Computational Biology
Division of Public Health Sciences
Fred Hutchinson Cancer Research Center
1100 Fairview Ave. N, M2-B876
P.O. Box 19024
Seattle, WA 98109-1024
E-mail: hpages at fhcrc.org
Phone: (206) 667-5791
Fax: (206) 667-1319
More information about the R-devel
mailing list