Hack Your Design!

MacOS Xで pear をインストール

Mac OS X (10.7) にpearをインストールしてみます。下記のコマンド一発でいけるようです。

$ sudo php /usr/lib/php/install-pear-nozlib.phar

実際に流した結果が以下。

$ sudo php /usr/lib/php/install-pear-nozlib.phar
No log handling enabled - using stderr logging
Created directory: /var/db/net-snmp
Created directory: /var/db/net-snmp/mib_indexes
[PEAR] Archive_Tar    - installed: 1.3.7
[PEAR] Console_Getopt - installed: 1.3.0
[PEAR] Structures_Graph- installed: 1.0.4
[PEAR] XML_Util       - installed: 1.2.1
[PEAR] PEAR           - installed: 1.9.4
Wrote PEAR system config file at: /private/etc/pear.conf
You may want to add: /usr/lib/php/pear to your php.ini include_path
$ pear
Commands:
build                  Build an Extension From C Source
bundle                 Unpacks a Pecl Package
channel-add            Add a Channel
......

あとは/etc/php.iniでパスをincludeするだけ。

include_path = ".:/usr/lib/php/pear"

参考

  • このエントリーをはてなブックマークに追加
comments powered by Disqus