Solaris10失敗記 | HardReggaeCafe@Ameblo.jp

Solaris10失敗記

これからSolaris10を始めようとする人はよく読んで置いてください。

とにかくLinuxとは違うんだということがしみじみわかったということです。


とりあえず、やる気のある人にはこんな本も薦めておきます。

著者: 一条 博
タイトル: Solaris 10インストールと環境構築


”やりたかったこと”
→Solaris10インストールして、PHP4入れて、Wikiを立ち上げる

失敗した理由は
1)Apacheインストールされているもんだと思っていた
  Solarisは何もインストールされていないと思った方がいいです。
  Cコンパイラもインストールする羽目に陥りました。
2)PHPインストールなんてお茶の子さいさいと思っていた
  これはソースからコンパイルしなくてはならないとは知らなくて、
  ここで挫折したといっても過言じゃないです。

一応、挫折に至る過程ですが・・・
・Apacheはここ でインストールしたところ成功
・PHPインストールでSolarisFreeWare というサイトからダウンロード
 (死ぬほど時間かかりました。このサイトは腐ってます)
・Gunzipで展開してそのフォルダにアクセス
・マニュアルなどによれば最初にconfigureというツールを使って
 makefileを作る必要があるとの事。どういうオプションを選択しなければ
 いけないのか調べるのがかなりつらい
・configureを試しに実行するとCコンパイラがないことが判明
 上記サイトからgccをダウンロードしてpkgadd -dでインストールした
・再度configureすると今度はgccへのパスが通ってないので
 PATH=・・・と書いてexportコマンドしてパスを設定
・これで再度実行したらやっとmakefileできたけど、これで
 makeしたらいくつか存在しないモジュールがあったらしく(mysqlとかも)
 上記サイトからダウンロードしてひたすらpkgadd -dコマンドした
・努力もむなしくこんなエラー

# /usr/ccs/bin/make
/bin/sh /opt/src/php-4.3.11/libtool --silent --preserve-dup-deps --mode=compile gcc -I/opt/src/php-4.3.11/ext/gd/libgd -DHAVE_LIBPNG -DHAVE_LIBJPEG -Iext/gd/ -I/opt/src/php-4.3.11/ext/gd/ -DPHP_ATOM_INC -I/opt/src/php-4.3.11/include -I/opt/src/php-4.3.11/main -I/opt/src/php-4.3.11 -I/usr/local/include -I/include -I/opt/src/php-4.3.11/ext/mbstring/mbregex -I/opt/src/php-4.3.11/ext/mbstring/libmbfl -I/opt/src/php-4.3.11/ext/mbstring/libmbfl/mbfl -I/opt/src/php-4.3.11/ext/xml/expat -I/opt/src/php-4.3.11/TSRM -I/opt/src/php-4.3.11/Zend  -D_POSIX_PTHREAD_SEMANTICS  -g -O2   -c /opt/src/php-4.3.11/ext/gd/gd.c -o ext/gd/gd.lo
/opt/src/php-4.3.11/libtool: od: 見つかりません。
/opt/src/php-4.3.11/libtool: rm: not found
/opt/src/php-4.3.11/libtool: rm: not found
In file included from /usr/include/sys/wait.h:24,
                 from /opt/src/php-4.3.11/ext/gd/gd.c:41:
/usr/include/sys/siginfo.h:259: error: parse error before "ctid_t"
/usr/include/sys/siginfo.h:292: error: parse error before '}' token
/usr/include/sys/siginfo.h:294: error: parse error before '}' token
/usr/include/sys/siginfo.h:390: error: parse error before "ctid_t"
/usr/include/sys/siginfo.h:392: error: conflicting types for `__proc'
/usr/include/sys/siginfo.h:261: error: previous declaration of `__proc'
/usr/include/sys/siginfo.h:398: error: conflicting types for `__fault'
/usr/include/sys/siginfo.h:267: error: previous declaration of `__fault'
/usr/include/sys/siginfo.h:404: error: conflicting types for `__file'
/usr/include/sys/siginfo.h:273: error: previous declaration of `__file'
/usr/include/sys/siginfo.h:420: error: conflicting types for `__prof'
/usr/include/sys/siginfo.h:287: error: previous declaration of `__prof'
/usr/include/sys/siginfo.h:424: error: conflicting types for `__rctl'
/usr/include/sys/siginfo.h:291: error: previous declaration of `__rctl'
/usr/include/sys/siginfo.h:426: error: parse error before '}' token
/usr/include/sys/siginfo.h:428: error: parse error before '}' token
/usr/include/sys/siginfo.h:432: error: parse error before "k_siginfo_t"
/usr/include/sys/siginfo.h:437: error: parse error before '}' token
In file included from /usr/include/sys/procset.h:24,
                 from /usr/include/sys/wait.h:25,
                 from /opt/src/php-4.3.11/ext/gd/gd.c:41:
/usr/include/sys/signal.h:85: error: parse error before "siginfo_t"
In file included from /opt/src/php-4.3.11/ext/gd/gd.c:41:
/usr/include/sys/wait.h:86: error: parse error before "siginfo_t"
/opt/src/php-4.3.11/libtool: rm: not found
*** Error code 1
make: Fatal error: Command failed for target `ext/gd/gd.lo'

何が足りないのかこのエラーからはわかりません。
どっかの掲示板に聞く力も残ってないのでここで断念。

まとめますが、Solarisは本当に不親切です。
情熱ある人かIAサーバで最初からインストールされているものを
使う以外は勧められません。。。


といいつつ後からUNIX User5月号のの「オープンソースの常識」

を読んでわかったことですけど、もしかしたら

・automake

・autoconf

・libtool

が入っていればもっと楽チンだったかも。


ともあれ、アー時間損した。まあ、勉強になったけど。

そんなわけでFedraCoreに浮気しちゃいます。