phpbrewでインストール時に詰まったところメモ

今回の環境はCentOS 6.5(Final: x86_64)

$ phpbrew install 5.5.20 +default +mysql
===> phpbrew will now build 5.5.20
===> Loading and resolving variants...
Checking distribution checksum...
Checksum matched: 9dfc1d4d2b44fb7e2b4ee9651d032203
===> Distribution file was successfully extracted, skipping...
Found existing build.log, renaming it to /home/dimgraycat/.phpbrew/build/php-5.5.20/build.log.1423373902
===> Configuring 5.5.20...


Use tail command to see what's going on:
   $ tail -F /home/dimgraycat/.phpbrew/build/php-5.5.20/build.log



Configure failed. 1

エラーが出てたので tail を確認すると

configure: error: Cannot find OpenSSL's libraries

OpenSSLは昔入れた覚えがあるけどとりあえず確認する

$ yum list installed|grep openssl
openssl.x86_64        1.0.1e-30.el6_6.5 @updates
openssl-devel.x86_64  1.0.1e-30.el6_6.5 @updates

やはり、入ってるよねー。
ということは、configure時のパスが違うはず?
同じようなことが起きてる人が居ないかggr(定番)と
やはり居た!→ Cannot find OpenSSL's libraries · Issue #418 · phpbrew/phpbrew · GitHub

OpenSSLの場所を指定するのか、なるほど。

〜 +openssl=/usr -- --with-libdir=lib64

とりあえず、やってみる。

$ phpbrew install 5.5.20 +default +mysql +openssl=/usr -- --with-libdir=lib64
===> phpbrew will now build 5.5.20
===> Loading and resolving variants...
Checking distribution checksum...
Checksum matched: 9dfc1d4d2b44fb7e2b4ee9651d032203
===> Distribution file was successfully extracted, skipping...
Found existing build.log, renaming it to /home/dimgraycat/.phpbrew/build/php-5.5.20/build.log.1423375821
===> Configuring 5.5.20...


Use tail command to see what's going on:
   $ tail -F /home/dimgraycat/.phpbrew/build/php-5.5.20/build.log


===> Building...
Build finished: 19.6 minutes.
Installing...
      • > Creating php-fpm.conf
      • > Creating php.ini
      • > Copying /home/dimgraycat/.phpbrew/build/php-5.5.20/php.ini-development
      • > Found date.timezone is not set, patching...
Initializing pear config... sh: pear: コマンドが見つかりません sh: pear: コマンドが見つかりません sh: pear: コマンドが見つかりません Enabling pear auto-discover... sh: pear: コマンドが見つかりません Congratulations! Now you have PHP with 5.5.20 as php-5.5.20 To use the newly built PHP, try the line(s) below: $ phpbrew use php-5.5.20 Or you can use switch command to switch your default php to php-5.5.20: $ phpbrew switch php-5.5.20 Enjoy!

おkインストール出来た。
けど、「sh pear: コマンドが見つかりません」ってなんだ・・・!
しかし、build.log見るとインストールしてくれてるみたいなので気にしないでおこう。