[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[plamo:23679] Plamo Linux 4.0x にIntel Fortran Compilerfor Linux をインストールする手順



Plamo Linux 4.0x に Intel Fortran Compiler for Linux をインストールする手順

西松と申します。

Intel Fortran Compiler for Linux には Intel が noncommercial
用途に限り無料で提供してくれているものがあります。
ぼくはVersion 8.0をPlamo Linux 4.0にインストールして使って
います。いまのところifortが、gccでコンパイルしたライブラリ
をうまくリンクしてくれるなど、よいかんじで動いています
ので、インストールの手順をレポートします。ただし、この手順
でうまくいくかどうかは保証の限りではありません。

* Slackware 10.0 の rpm-4.2.1-i486-3.tgz を installpkg.

* rpmのデータベースを初期化。
     # rpm --initdb

* http://www.intel.com/software/products/noncom/ を起点に
  コンパイラ本体、最新のパッチ、ライセンスをもらってくる。
  Windows XP の InternetExplorer でないとうまくダウンロード
  などができないことがあった。

* ライセンスの説明や、インストールの手順をよく読む。

* コンパイラ本体のtarballを展開。install.sh の rpm -q rpm
  の部分をtrueと書き換える。

* ライセンスのファイルを/opt/intel/licenses/など適当な場所に
  置いておく。

* rootで
     # ./install.sh
  と実行。指示に従う。入力を求められるrpmのオプションは
  -U -replacefiles -nodeps

* パッチも同様の手順でインストールできる。
  
* ~/.bashrc または ~/.cshrc を書き換える。
  たとえば.bashrc なら
     . /opt/intel_fc_80/bin/ifortvars.sh
  を書き加える。

使用例:
$ cat testreal.f
      program testreal
      implicit none
      real*8 a,b,c
      a=0.1
      b=0.1
      c=a+b
      write(6,'(f20.17)') c
      end program testreal
$ ifort -o testreal testreal.f
$ ./testreal 
 0.20000000298023224
$ ifort -r8 -o testreal testreal.f
$ ./testreal 
 0.20000000000000001
$ 

以上です。ご参考になれば幸いです。
-- 
 love && peace && free_software
 NISHIMATSU Takeshi


[検索ページ] [メール一覧]
Plamo ML 公開システム