Skip to content

Instantly share code, notes, and snippets.

@blpraveen
Forked from Kamisama666/phpzmqinstall.sh
Created December 27, 2022 09:34
Show Gist options
  • Save blpraveen/a346b022eacf04ce035c52f7e18b625c to your computer and use it in GitHub Desktop.
Save blpraveen/a346b022eacf04ce035c52f7e18b625c to your computer and use it in GitHub Desktop.
Installation of ZeroMQ and php-zmq extension on Ubuntu 14.04. Must be run as root
#!/bin/bash
cd /tmp
apt-get update
apt install -y libtool pkg-config build-essential autoconf automake uuid-dev git wget
git clone git://github.com/jedisct1/libsodium.git
cd libsodium/
./autogen.sh
./configure && make check
make install
ldconfig
cd ..
wget http://download.zeromq.org/zeromq-4.1.4.tar.gz
tar -xvf zeromq-4.1.4.tar.gz
cd zeromq-4.1.4
./autogen.sh
./configure && make check
make install
ldconfig
cd ..
git clone https://github.com/zeromq/czmq
cd czmq
git checkout tags/v3.0.2
./autogen.sh
./configure
make -j 8
make install
ldconfig
cd ..
apt -y install php5-dev
git clone https://github.com/mkoppanen/php-zmq.git
cd php-zmq/
phpize
./configure --with-czmq
make
make test
make install
echo "extension=zmq.so" >> /etc/php5/cli/php.ini
echo "extension=zmq.so" >> /etc/php5/apache2/php.ini
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment