ソースからRをインストール
Posted by 0093 in Tech Memo on 2006/10/25
基本的にはインストーラーを使うから余りこの方法をとることはないと思うけど,念のためメモ.
基本はmake installでいいんだけど,./configureにつくオプションが結構多い.
(R for Mac Wikiより抜粋)
##IntelMacにソースからRをインストールする方法
##必要な物
gcc(GNU C Compiler) -Xcodeに付属の物でOK
g77(GNU Fortran Compiler) -Universal版かどうかは分からないけど,R2.2.1のインストーラーにはg77のインストーラーが付属している(ソースからインストールするのに,そのソフトのインストーラーを使うのは本末転倒な気がするけど)
##インストール方法
#1
The R Project for Statistical ComputingのDownloadから適当なCRANを選んでソースファイルをダウンロードする.
とりあえず2006/10/24現在最新版のバージョンは2.4.0
#2
適当な所に移動して解凍して,そのフォルダに移動する
tar zxvf /hogehoge/R-2.4.0.tar.gz
cd R-2.4.0
#3
./configureする.これが長い.
./configure --with-blas="-lptf77blas -lpthread -latlas"
CPPFLAGS=-msse3 CFLAGS="-g -O2 -march=pentium-m -mtune=prescott"
CXXFLAGS="-g -O2 -march=pentium-m -mtune=prescott"
FFLAGS="-g -O2 -march=pentium-m -mtune=prescott"
#4
あとはmake, make installするだけ
make
sudo make install
これでインストールは完了.
This entry was posted on 2006/10/25 at 8:02 and is filed under Tech Memo . You can follow any responses to this entry through the RSS 2.0 . You can leave a response .
- No comments yet.