Installation
PHP Manual

Manually Installing the MongoDB HHVM Driver

At the time of this writing, HHVM does not have a package manager for extensions. Download the latest driver from » GitHub. Alternatively, you may clone the repository to build the latest source code:

$ git clone https://github.com/mongodb/mongo-hhvm-driver.git
$ cd mongo-hhvm-driver
$ git submodule sync && git submodule update --init --recursive

Set up the make files by running:

$ hphpize
$ cmake .

Generate the configure files for the bundled libraries. For this this to work, you need to have the automake, autoconf, and libtool packages installed (e.g. through apt-get).

$ make configlib

Build and install the driver by running:

$ make -j 5
$ sudo make install

Hinweis:

If the hphpize command is not available, you will need to either compile HHVM from source or install the hhvm-dev package (e.g. through apt-get).

The last step will report where mongodb.so has been installed, similar to:

Installing:     /usr/local/hhvm/3.9.1/lib/hhvm/extensions/20150212/mongodb.so

Add the following line to your php.ini file (usually found in "/etc/hhvm"):

hhvm.dynamic_extension_path=/usr/local/hhvm/3.9.1/lib/hhvm/extensions/20150212
hhvm.dynamic_extensions[mongodb]=mongodb.so


Installation
PHP Manual