安装/配置
在线手册:中文 英文
PHP手册

安装

To install the AMQP PHP extension, you must first install the » librabbitmq library. You will need the 0-9-1 version of the rabbitmq-c client library, linked to the rabbitmq-codegen version that corresponds to the version of the broker you are using. Use the following steps to download and install the library:

# Download the rabbitmq-c library @ version 0-9-1
  hg clone http://hg.rabbitmq.com/rabbitmq-c/rev/b01825ecc112 rabbitmq-c
  cd rabbitmq-c
  # Add the codegen requirement. To find the full list, go here: http://hg.rabbitmq.com/rabbitmq-codegen/tags
  # and copy the URL for the appropriate broker version.
  hg clone http://hg.rabbitmq.com/rabbitmq-codegen/rev/16bbcb711380 codegen
  # Configure, compile and install
  autoreconf -i && ./configure && make && sudo make install

安装此 PECL 扩展相关的信息可在手册中标题为 PECL 扩展的安装 章节中找到。另外的信息,如新的发行版本、下载、源文件、 Additional information such as new releases,维护人员信息及变更日志等,都在此处: » http://pecl.php.net/package/amqp.

Note to Windows users: This extension does not currently support Windows since the librabbitmq library does not yet support Windows.


安装/配置
在线手册:中文 英文
PHP手册
PHP手册 - N: 安装

用户评论:

rgagnon (18-Feb-2012 01:00)

PECL now has stable version 1.0.0 of this code that does compile cleanly with PHP >= 5.0 (as of 15-Feb-2012).    I personally had a clean build with no warnings under 5.2.17

Previously the code was not stable, and only compiled nicely under 5.3

I don't know what's up with the extension posted on code.google.com, but the PECL one is the supported extension.

http://pecl.php.net/amqp

LilaeaMedia (12-Dec-2011 12:54)

Make sure you are using http://pecl.php.net/get/amqp

soham (03-May-2011 07:41)

If you get these errors:

"error: possibly undefined macro: AM_PROG_LIBTOOL" ===> you need to install 'libtool'.

"Can't exec "aclocal"  ===> You need to install 'automake'

Use your linux distro's default providers to install them e.g. on opensuse, I'd use 'zypper install ..'

brian dot ngure at gmail dot com (10-Dec-2010 07:26)

Have a look at the installation instructions on the Google Code site, found here: http://code.google.com/p/php-amqp/

Brian