[R] Shared library loading in Win R 1071 and previous Win Rversions

Paul Y. Peng ypeng at math.mun.ca
Sat Aug 30 22:09:26 CEST 2003

Prof Brian D Ripley wrote:
> You probably need to recompile the DLL: have you tried that?
> On Sat, 30 Aug 2003, Paul Y. Peng wrote:
> > I recently upgraded R from rw1051 to rw1071 on a Win98se system and
> > surprisingly found my DLL library does not work any more. When I
> > tried to load the dll file by dyn.load("my.dll"), I got the following
> > message:
> >
> >   Error in dyn.load(x, as.logical(local), as.logical(now)) :
> >           unable to load shared library "C:/temp/my.dll":
> >     LoadLibrary failure:  A device attached to the system is not
> > functioning.
> >
> > I cannot figure out what is meant by this message.
> I think it is from an old version of Windows?  (Windows XP and 2000 are


> usually a lot more informative.)  It probably means that R.dll does not
> contain what your DLL expected, which is not surprising if you did not
> recompile it.

I did not recompile it because the dll file compiled for rw1062
worked flawlessly in rw1051. I thought it would work as well in
rw1071. I will recompile it and try again.

> > The DLL library has
> > been working up to version rw1062. I checked CHANGES in rw1071 directory
> > did not find anything related to loading a shared library. Can anyone
> > enlighten me on this?
> The NEWS file might enlighten you, BTW: CHANGES is only about
> Windows-specific changes.  No one has ever said that a DLL compiled for one
> version of R will work for any other, although it is likely to work between
> patch levels (1.7.0 to 1.7.1, for example).
> > Since rw1071 does not work,
> It is *your* code that does not work.

Points taken.

> > I am thinking to install rw1062 instead.
> > However, the "old" link in
> >
> >    http://lib.stat.cmu.edu/R/CRAN/bin/windows/base/
> >
> > does not work. Is this right place to get an old version of R?
> It does on the master CRAN site, but gets you to rw1070.  It also seems to
> work on that mirror.  The old link in the old area does not work, nor I
> suspect is it intended to.

OK. Then are there any way to retrieve other previous Windows
versions prior to rw1070? Do I miss anything obvious here?

Many thanks for your help.

More information about the R-help mailing list