From ripley at stats.ox.ac.uk  Tue Oct  5 22:16:04 2004
From: ripley at stats.ox.ac.uk (Prof Brian Ripley)
Date: Tue Oct  5 22:16:10 2004
Subject: [Rd] R 2.0.0: problem: installing --with-package-versions
In-Reply-To: <4162F34A.9070202@epigenomics.com>
Message-ID: <Pine.LNX.4.44.0410052047180.13559-100000@gannet.stats>

It seems that if you first install this without --with-package-versions
then with and then remove the first version, it works.

Here is a patch, shortly to appear in R-patched/R-devel:

--- INSTALL.in  (revision 31298)
+++ INSTALL.in  (working copy)
@@ -601,10 +601,10 @@
     ## is no namespace).  Argh.
     ## </NOTE>
     save_image_defaults="list(compress=TRUE, safe=FALSE)"
-    code_file="${R_PACKAGE_DIR}/R/${R_PACKAGE_NAME}"
+    code_file="${R_PACKAGE_DIR}/R/${pkg_name}"
     rda_file="${R_PACKAGE_DIR}/R/all.rda"
     if test -f NAMESPACE; then
-      code_cmd="echo invisible(.libPaths(c(\"${lib}\", .libPaths()))); 
.getRequiredPackages(); saveNamespaceImage(\"${pkg_name}\", 
\"${rda_file}\", \"${lib}\")"
+      code_cmd="echo invisible(.libPaths(c(\"${lib}\", .libPaths()))); 
.getRequiredPackages(); saveNamespaceImage(\"${R_PACKAGE_NAME}\", 
\"${rda_file}\", \"${lib}\")"
       loader_file=nsrdaload.R
       R_save_args="--vanilla --slave"
     else


On Tue, 5 Oct 2004, Matthias Burger wrote:

> 
> Hello R developers,
> 
> installing R 2.0.0 from source on a Linux Debian system (gcc 3.2.2)
>   - which worked just fine - I encountered the following problem when trying to
> update/install packages with the option --with-package-versions:
> 
> example: RUnit 0.4.0 (also on CRAN)
> 
> R20 CMD INSTALL -l /mnt/local/R/R-2.0.x-libs-EpiR --with-package-versions 
> RUnit_0.4.0.tar.gz
> 
> or after untaring
> R20 CMD INSTALL -l /mnt/local/R/R-2.0.x-libs-EpiR --with-package-versions RUnit
> 
> I get
> * Installing *source* package 'RUnit' as 'RUnit_0.4.0' ...
> ** R
> ** inst
> ** save image
> Error in loadNamespace(package, lib.loc, keep.source, TRUE, TRUE) :
>          package 'RUnit' does not have a name space
> Execution halted
> ERROR: execution of package source for 'RUnit' failed
> 
> This happens only with the --with-package-versions option.
> I scanned the manual and ?INSTALL but did not find mention of this behaviour.
> 
> Any suggestion what I have overlooked or how to cure the failure?
> 
> 
> Regards,
> 
>    Matthias
> 
> 
>  >version
>           _
> platform i686-pc-linux-gnu
> arch     i686
> os       linux-gnu
> system   i686, linux-gnu
> status
> major    2
> minor    0.0
> year     2004
> month    10
> day      04
> language R
> 
> 

-- 
Brian D. Ripley,                  ripley@stats.ox.ac.uk
Professor of Applied Statistics,  http://www.stats.ox.ac.uk/~ripley/
University of Oxford,             Tel:  +44 1865 272861 (self)
1 South Parks Road,                     +44 1865 272866 (PA)
Oxford OX1 3TG, UK                Fax:  +44 1865 272595


[Rd] R 2.0.0: problem: installing --with-package-versions
Prof Brian Ripley