domenica 21 novembre 2010

HowTo: R 2.12 on Mac OS X Tiger 10.4 PPC

R_GUI for Tiger is supported until R 2.10.
If you need R 2.12 the only way is to forget about graphical interfaces.
Manual compilations was a dependencies hell, fortunately there is a port called "r-base" in fink.

  1. Install Xcode from your Mac OS X DVD.
  2. Install X11 from the same DVD.
  3. Install Fink from here.
  4. If you want a GUI install Fink commander from here.
  5. Enable Unstable packages, read how here.
  6. Install "r-base". It will take some time...





Now you have R binary in:
/sw/bin/R
and R Framework in:
/Volumes/YourHD/sw/Library/Framework/R.framework/
I tried to manually compile R.app without luck, it doesn't like a library. If you can do it please tell me how.

Anyway, if you open X11 (Applications/Utilities/X11.app) you have an old school terminal where you can type:
cd /Volumes/YourHD/sw/bin
./R

R version 2.12.0 (2010-10-15)
Copyright (C) 2010 The R Foundation for Statistical Computing
ISBN 3-900051-07-0
Platform: powerpc-apple-darwin8.11.0 (32-bit)

R `e un software libero ed `e rilasciato SENZA ALCUNA GARANZIA.
Siamo ben lieti se potrai redistribuirlo, ma sotto certe condizioni.
Scrivi 'license()' o 'licence()' per dettagli su come distribuirlo.

R `e un progetto di collaborazione con molti contributi esterni.
Scrivi 'contributors()' per maggiori informazioni e 'citation()'
per sapere come citare R o i pacchetti di R nelle pubblicazioni.

Scrivi 'demo()' per una dimostrazione, 'help()' per la guida in linea, o
'help.start()' per l'help navigabile con browser HTML.
Scrivi 'q()' per uscire da R.

> 
Nice, it calls an X11 window if you plot() something too!


Just too simple, obviously it's no time to claim victory. Try to compile some external library, probably you will get something like:
MACOSX_DEPLOYMENT_TARGET environment variable set to: 10.1
For which you have to type:
Sys.setenv("MACOSX_DEPLOYMENT_TARGET"="10.4")
before every:
install.packages()


Finally, I find X11 terminal too ugly, I like I-Term, try it!

------------------------------------------------------------------------------------

UPDATE:
Read here how to open Tcl/Tk windows.

Nessun commento:

Posta un commento