R-beta: A new port of R to MS Windows on CRAN
Friedrich Leisch
Friedrich.Leisch at ci.tuwien.ac.at
Thu Mar 26 14:59:46 CET 1998
Hi,
I've included Guido Masarotto's port of R 0.61.1 to MS Windows 95/NT
in $CRAN/bin/ms-windows-32 ... you can find both the sources and
binaries there.
I include Guido's README below.
Thanks again to Guido for making this port available!
Best,
Fritz Leisch
**********************************************************
rgnwbin.tgz and rgnwsrc.tgz are the first results of an attempt to
build R for Win95 and WinNT using egcs-mingw32.
The advantages over the binaries for MsWindows that can be found in CRAN
are:
1. R seems to run faster. Some simple (perhaps too simple)
benchmarks point to a 20% gain.
2. The port is based on a more recent version (0.61.1) and it is more
complete (more "system calls": system, tempfile, unlink,
WinExec - to launch applications without waiting for the result;
support for the standard help system: try help(), help(abline),
help(line,eda), ?women, data(), library())
3. A new menu item "Stop current computation" make possible
to interupt long computation (but only when something is printed).
4. Since egcs-mingw32 uses the standard C calling convention,
you don't need a Watcom compiler to build dynamic link libraries.
Indeed, this was my original motivation.
5. It should be easy to use some other gnu-win32 compilers (maybe
running on a non MsWindows machine). It should be easy to
adapt the port to lcc-win32, too.
But remember: this is experimental code so
-----------------------------------------------------------------------------
USE IT AT YOUR RISK
-----------------------------------------------------------------------------
BINARY DISTRIBUTION
Just unpack rgwnbin.tgz somewhere.
The executable is R.GNW\bin\R.exe. This binary distribution
includes only the standard packages (base+eda+mva+stepfun).
SOURCE DISTRIBUTION
This is an add-on to the R-0.61.1 distribution.
So unpack R-0.61.1.tar.gz somewhere.
Then, from the same directory, unpack rgwnsrc.tgz.
To rebuild the system, go to R-0.61.1/src/gnuwin32.
Then
> make
should build the standard stuff.
To add a new package, you should
a) download it;
b) unpack it in the R-0.61.1/src directory.
c) go to the R-0.61.1/src/gnuwin32 directory and type
> make pkg-xxx
where xxx is the name of the package.
You should get the directory R-0.61.1/library/xxx
and its subdirectory R/ (the r-code) data/ (the
data of the package) R/libs (the dynamic link library) and
the support for the help system (INDEX, TITLE, an updated
LibIndex). Of course, the data and libs subdirectory
can be missing.
d) if you want the documentation, you can download
the preformatted one.Then unpack it in the R-0.61.1
(not in the R-0.61.1/src) directory. If you don't need
the LaTeX files, remove them.
Note:
(1) Of course, you need a compiler. As I have said I used
the egcs-mingw32 one:
http://www.xraylith.wisc.edu/~khan/software/gnu-win32/
(2) You must also have a GNU make and some standard unix
command (ls,cat,sed,rm). Furthemore, make and this
command must be able to overcome the MsDOS limitation
about the length of a command.
I used the ones coming with the djgpp compiler.
According to me, they are the best version for dos and
windows. You can find it in any SIMTEL mirror.
If you want, I can make available a small file with
only the needed tools.
(3) The gnuwin32/Makefile use the g77 Fortran compiler.
If you don't have it, or if you don't want to use it,
you can use something like
> make HAVEG77=NO
or
> make HAVEG77=NO pkg-xxx
For example, the g77 compiler in egcs-mingw32 was
not able to compile the fortran code in the acepack package.
However, I was able to build this package with the command
> make HAVEG77=NO pkg-acepack
(4) When installing a package, if in R-0.61.1/src/library/xxx/R
exist a file with name yyy.gnw then this file is used
and files with name yyy or yyy.somethingelse are
ignored. In this way, you can configure the R code
of the package. An example is the base/R/system.gnw
file.
(5) This is not a developer's distribution. For example, dependences
are written in a silly way. Furthemore, all the code
in src/appl/, src/appl-f,..... is compiled.
No use of the original Makefile is done.
Hence, you have to start from a cleaned distribution.
BUGS and TODO
(0) The English of this README.
(1) If you exit from the edit windows and this is empty you get a
segmentation fault. This happens also on my Linux box. So,
it seem to be a general problem.
(2) The dll's are statically linked with the other R code.
So they get support for the routines that they need.
In this way, they work but are big. We should have
a large R.dll with all the standard code. Then
the executable and the dll's should simply import
from R.dll.
(3) Try and adapt this port to other win32 compiler.
It should be easy. So, why don't try?
(4) The system command does not work if the command to be
execute require some user interaction. It is just a
"simulated reading pipe for a broken OS".
(5) I inserted an event loop at the beginning of the
function which print to the console. In this way,
you can interupt the computation or, for example,
give the focus to the graphics window.
But only when you print. A call to the event loop
must be inserted inside the "main" code.
But, for the moment, I decided to leave the "main"
code untouched.
(6) When building package xxx, all the C and Fortran files
found in library/xxx/src (or library/xxx/src-c if
you don't have the g77 compiler) are compiled
and putted in a dll. On the contrary, we have to make
use of the original Makefile.
(7) The Windows code must be cleaned.
guido masarotto 22 marzo 1998
guido at sirio.stat.unipd.it
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !) To: r-help-request at stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
More information about the R-help
mailing list