[Rd] Suggested change to build.pl

Uwe Ligges ligges at statistik.tu-dortmund.de
Mon Jun 7 12:15:30 CEST 2010



On 04.06.2010 17:11, Dominick Samperi wrote:
> Under Linux the cleanup script (if it exists) is run at the end, before
> the package archive is created, and this prevents intermediate files
> that are no longer needed from being written to the archive.
>
> Unfortunately, this does not happen under Windows when there
> is a cleanup.win. That is, cleanup.win is not run before the
> archive is created.
>
> Here is the code in build.pl that checks for cleanup and runs
> it before building the archive:
>
> if(!$WINDOWS&&  -x "./cleanup") {
>      $log->message("running cleanup");
>      R_system("./cleanup");
>   }
>
> But the case where $WINDOWS is true is never
> addressed.
>
> The problem can be resolved by adding:
>
> if($WINDOWS&&  -e "./cleanup.win") {
>       $log->message("running cleanup.win");
>       R_system("./cleanup.win")
> }
>
> Does this make sense?


Since changes can only happen for R-devel, I'd suggest to think about 
the *R* code in R-devel rather than a perl script that does not exists 
any more (just its backup copy obuild.pl exists) in the current R-devel 
sources.

Another point to be considered is why you need a cleanup script. I have 
rarely seen cases where this is required.

Best,
Uwe Ligges


> Thanks,
> Dominick
>
> 	[[alternative HTML version deleted]]
>
> ______________________________________________
> R-devel at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-devel



More information about the R-devel mailing list