Last active
November 4, 2024 13:32
-
-
Save wcomnisky/6d276a9894a5b2078b552cc492fa1abd to your computer and use it in GitHub Desktop.
Install PHP AMQp on MacOS
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
brew search librabbitmq | |
brew install rabbitmq-c | |
pecl install amqp | |
# set the path to librabbitmq install prefix [autodetect] : /usr/local/Cellar/rabbitmq-c/0.10.0 | |
# if it fails follow the following (reference: https://github.com/pdezwart/php-amqp/issues/355#issuecomment-563203121): | |
git clone https://github.com/pdezwart/php-amqp.git github-pdezwart-php-amqp/ | |
cd github-pdezwart-php-amqp | |
#git checkout tags/v1.9.4 ./ | |
sudo phpize | |
./configure --with-librabbitmq-dir=/usr/local/Cellar/rabbitmq-c/0.10.0 | |
make && make install | |
# Then you just add extension=amqp to your php.ini, restart your php service | |
php -i|grep amqp |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
As people already say, pecl do not detect correctly the install folder of rabbitmq-c.
The following couple of commands worked for me:
It ends well with :