From ripley at stats.ox.ac.uk  Tue May  3 17:48:23 2005
From: ripley at stats.ox.ac.uk (Prof Brian Ripley)
Date: Tue May  3 17:48:32 2005
Subject: [Rd] MacOS X: update.packages(type="mac.binary") fails (PR#7831)
In-Reply-To: <20050503151508.D908BA208@slim.kubism.ku.dk>
References: <20050503151508.D908BA208@slim.kubism.ku.dk>
Message-ID: <Pine.LNX.4.61.0505031644160.3505@gannet.stats>

On Tue, 3 May 2005 ripley@stats.ox.ac.uk wrote:

> Binary installs are AFAIK only supported in the GUI, where the default is
> as documented.

A bit more checking show that the documented default is

 	"source" except under the CRAN Mac OS X build

and the default is taken from .Platform$pkgType which is controlled by 
HAVE_AQUA.  So I have no idea why this is not working as documented.

> So .install.macbinary() is not loaded except in the GUI.

Looks like the version of src/library/utils/R/GUI.R is not that which got 
tested: over to Stefano.  .install.macbinary() should only be available 
under the GUI, though.

> The reason is that those binaries are tied to that particular build of R,
> and will not work with a general build on MacOS X.
>
> I would expect this to work from the command-line in the GUI console, and
> had believed it had been tested there.
>
>
> On Tue, 3 May 2005 jari.oksanen@oulu.fi wrote:
>
>> Full_Name: Jari Oksanen
>> Version: R 2.1.0
>> OS: MacOS 10.3.9
>> Submission from: (NULL) (130.231.102.145)
>>
>>
>> For various reasons (which need not be expanded here) I have tried to update my
>> long neglected R in MacOS X using handy command line tool update.packages()
>> using readily available binaries of contributed packages at CRAN. However, this
>> fails with message saying that packages xxxx_*_tar.gz is not found at the server
>> (HTTP error 404). Obviously, the package name is expanded wrongly as the binary
>> packages for MacOS X have type *.tgz. However, this seems not be the problem,
>> but there are two other problems:
>>
>> 1. update.packages does not transfer the value of 'type' to the next function
>> install.packages, but install.packages uses the value of getOption("pkgType")
>> which seems to be "source" in CRAN binary of MacOS X (contrary to documentation
>> at ?options).
>>
>> 2. If this is corrected, or first set options(pkgType="mac.binary"), the update
>> fails for missing function .install.macbinary().
>>
>> The first problem is easy to correct:
>>
>> --- update.packages.R   2005-05-03 17:13:36.000000000 +0300
>> +++ jarioksa.update.packages.R  2005-05-03 17:13:58.000000000 +0300
>> @@ -59,5 +59,5 @@
>>          install.packages(update[, "Package"], instlib, contriburl =
>> contriburl,
>>              method = method, available = available, destdir = destdir,
>> -            installWithVers = installWithVers, type)
>> +            installWithVers = installWithVers, type = type)
>>      }
>>  }
>>
>>
>> For the second, problem, I don't know what to do. grepping
>> R-patched_2005-05-03.tar.gz source found only one instance of
>> .install.macbinary(): the failed call in
>> R-patched/src/library/utils/R/packages2.R. I couldn't find the definition of the
>> function.
>>
>> Do I really have to use GUI? Uh.
>>
>> cheers, jari oksanen
>>
>> ______________________________________________
>> R-devel@stat.math.ethz.ch mailing list
>> https://stat.ethz.ch/mailman/listinfo/r-devel
>>
>>
>
> -- 
> 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 272860 (secr)
> Oxford OX1 3TG, UK                Fax:  +44 1865 272595
>
> ______________________________________________
> R-devel@stat.math.ethz.ch mailing list
> https://stat.ethz.ch/mailman/listinfo/r-devel
>
>

-- 
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] MacOS X: update.packages(type="mac.binary") fails (PR#7831)
Prof Brian Ripley