POSTS
Gearman Install OSX
安裝Gearman 在OSX上面
$ sudo -s
$ cd /tmp
$ wget https://github.com/downloads/libevent/libevent/libevent-2.0.15-stable.tar.gz
$ tar zxvf libevent-2.0.15-stable.tar.gz
$ cd libevent-2.0.15-stable
$ ./configure
$ make
$ make install
$ cd ..
$ wget https://launchpad.net/ubuntu/lucid/+source/libdrizzle/0.7-1/+files/libdrizzle_0.7.orig.tar.gz
$ tar libdrizzle_0.7.orig.tar.gz
$ cd libdrizzle-0.7/
$ ./configure
$ make
$ make install
$ cd ..
$ wget http://launchpad.net/gearmand/trunk/0.14/+download/gearmand-0.14.tar.gz
$ tar zxvf gearmand-0.14.tar.gz
$ cd gearmand-0.14/
$ ./configure
$ make
$ make install
$ cd ..
$ wget http://pecl.php.net/get/gearman-0.8.0.tgz
$ tar zxvf gearman-0.8.0.tgz
$ cd gearman-0.8.0
$ phpize
$ ./configure
$ make
$ sudo make install
/bin/sh /tmp/gearman-0.8.0/libtool --mode=install cp ./gearman.la /tmp/gearman-0.8.0/modules
cp ./.libs/gearman.so /tmp/gearman-0.8.0/modules/gearman.so
cp ./.libs/gearman.lai /tmp/gearman-0.8.0/modules/gearman.la
----------------------------------------------------------------------
Libraries have been installed in:
/tmp/gearman-0.8.0/modules
If you ever happen to want to link against installed libraries
in a given directory, LIBDIR, you must either use libtool, and
specify the full pathname of the library, or use the `-LLIBDIR'
flag during linking and do at least one of the following:
- add LIBDIR to the `DYLD_LIBRARY_PATH' environment variable
during execution
See any operating system documentation about shared libraries for
more information, such as the ld(1) and ld.so(8) manual pages.
----------------------------------------------------------------------
Installing shared extensions: /usr/lib/php/extensions/no-debug-non-zts-20090626/
$ which php
/usr/bin/php
$ php --info | grep -i configuration (11-17 13:30)
Configuration File (php.ini) Path => /etc
Loaded Configuration File => /private/etc/php.ini
Configuration
$ vi /private/etc/php.ini
======= 加入以下資訊 ======
extension_dir = " /usr/lib/php/extensions/no-debug-non-zts-20090626/" <~~這不一定要
extension="gearman.so"
========================
$ php --info | egrep -i "(configuration|gearman)"
Configuration File (php.ini) Path => /etc
Loaded Configuration File => /private/etc/php.ini
Configuration
gearman
gearman support => enabled
libgearman version => 0.14