svn: /phpdoc/en/trunk/reference/mongo/ book.xml configure.xml setup.xml

From: Date: Fri, 15 Jan 2010 19:08:52 +0000
Subject: svn: /phpdoc/en/trunk/reference/mongo/ book.xml configure.xml setup.xml
Groups: php.doc.cvs 
Request: Send a blank email to doc-cvs+get-5860@lists.php.net to get a copy of this message
kristina Fri, 15 Jan 2010 19:08:52 +0000 Revision: http://svn.php.net/viewvc?view=revision&revision=293592 Log: added installation instructions Changed paths: U phpdoc/en/trunk/reference/mongo/book.xml U phpdoc/en/trunk/reference/mongo/configure.xml U phpdoc/en/trunk/reference/mongo/setup.xml Modified: phpdoc/en/trunk/reference/mongo/book.xml =================================================================== --- phpdoc/en/trunk/reference/mongo/book.xml 2010-01-15 18:50:53 UTC (rev 293591) +++ phpdoc/en/trunk/reference/mongo/book.xml 2010-01-15 19:08:52 UTC (rev 293592) @@ -9,14 +9,11 @@ &reftitle.intro; <para> MongoDB is a high-performance, open source, schema-free document database - designed for creating scalable websites. + designed for creating scalable websites. This is the PHP driver for MongoDB. + To use the PHP driver, you must first download the database server from + &url.mongodb;. </para> - <para> - More information and downloads for Mongo can be found at &url.mongodb; and - information about PHP in particular at &url.mongodb.php;. - </para> - </preface> &reference.mongo.setup; Modified: phpdoc/en/trunk/reference/mongo/configure.xml =================================================================== --- phpdoc/en/trunk/reference/mongo/configure.xml 2010-01-15 18:50:53 UTC (rev 293591) +++ phpdoc/en/trunk/reference/mongo/configure.xml 2010-01-15 19:08:52 UTC (rev 293592) @@ -8,6 +8,152 @@ &pecl.info; <link xlink:href="&url.pecl.package;mongo">&url.pecl.package;mongo</link>. </para> + + <simplesect> + <title>Installing on *NIX</title> + + <para> + Run: + <programlisting> +<![CDATA[ + +$ sudo pecl install mongo + +]]> + </programlisting> + </para> + + <para> + Add the following line to your php.ini file: + <programlisting> +<![CDATA[ +extension=mongo.so +]]> + </programlisting> + </para> + </simplesect> + + <simplesect> + <title>Installing on Windows</title> + + <para> + VC8 and VC9 precompiled binaries are available for thread safe and + non-thread-safe PHP 5.3 on + <link xlink:href="http://github.com/mongodb/mongo-php-driver/downloads">Github</link>. + VC6 precompiled binaries are available for thread safe and non-thread-safe + PHP 5.2 and 5.3 from <link xlink:href="http://downloads.php.net/pierre/">php.net</link>. + Unzip the archive and put php_mongo.dll in your PHP extension directory + ("ext" by default). + </para> + + <para> + Add the following line to your php.ini file: + <programlisting> +<![CDATA[ +extension=php_mongo.dll +]]> + </programlisting> + </para> + </simplesect> + + <simplesect> + <title>Manual Installation</title> + + <para>For driver developers and people interested in the latest bugfixes, you + can compile the driver from the latest source on + <link xlink:href="http://github.com/mongodb/mongo-php-driver">Github</link>. + Go to Github and click the "download" button. Then run: + + <programlisting> +<![CDATA[ +$ tar zxvf mongodb-mongodb-php-driver-<commit_id>.tar.gz +$ cd mongodb-mongodb-php-driver-<commit_id> +$ phpize +$ ./configure +$ sudo make install +]]> + </programlisting> + </para> + + <para> + Make the following changes to php.ini: + </para> + <itemizedlist> + <listitem> + <para> + 1. The build will display where it is installing the PHP driver with output that looks something like: + <programlisting> +<![CDATA[ + Installing '/usr/lib/php/extensions/no-debug-zts-20060613/mongo.so' +]]> + </programlisting> + + Make sure that it is the same as the PHP extension directory by runnning: + + <programlisting> +<![CDATA[ + $ php -i | grep extension_dir + extension_dir => /usr/lib/php/extensions/no-debug-zts-20060613 => + /usr/lib/php/extensions/no-debug-zts-20060613 +]]> + </programlisting> + + If it's not, change the extension_dir in php.ini or move mongo.so. + </para> + </listitem> + <listitem> + <para> + 2. To load the extension on PHP startup, add a line: Github + + <programlisting> +<![CDATA[ + extension=mongo.so +]]> + </programlisting> + + </para> + </listitem> + </itemizedlist> + </simplesect> + + <simplesect> + <title>OS X</title> + + <para> + If your system is unable to find autoconf, you'll need to install Xcode + (available on your installation DVD). + </para> + + <para> + Precompiled binaries are available from + <link xlink:href="http://www.github.com/mongodb/mongo-php-driver/downloads">Github</link> + (download the latest one with "osx" in the name that matches your version of + PHP). These for use with MAMP and XAMPP, which come without the headers + necessary to compile the extension from scratch. Extract mongo.so from the + archive and add it to MAMP or XAMPP's extension directory. Add + <programlisting> +<![CDATA[ + extension=mongo.so +]]> + </programlisting> + to the php.ini file being used and restart the server. + </para> + </simplesect> + + <simplesect> + <title>Gentoo</title> + <para>On Gentoo using PECL you might get an error that libtool is the wrong + version. Compiling from source you'll need to run aclocal and autoconf. + + <programlisting> +<![CDATA[ +$ phpize && aclocal && autoconf && ./configure && make && make install +]]> + </programlisting> + + (Thanks to <link xlink:href="http://twitter.com/riklaunim/status/5015388622">@riklaunim</link>) + </para> + </simplesect> </section> Modified: phpdoc/en/trunk/reference/mongo/setup.xml =================================================================== --- phpdoc/en/trunk/reference/mongo/setup.xml 2010-01-15 18:50:53 UTC (rev 293591) +++ phpdoc/en/trunk/reference/mongo/setup.xml 2010-01-15 19:08:52 UTC (rev 293592) @@ -6,11 +6,13 @@ <section xml:id="mongo.requirements"> &reftitle.required; - <!-- Use &no.requirement; if there no requirement --> <para> - Requires PHP 5.0 and up. - You can download MongoDB from &url.mongodb;. + Requires PHP 5.1 or greater. </para> + <para> + Requires a MongoDB database server, which can download MongoDB from + <link xlink:href="&url.mongodb;">&url.mongodb;</link>. + </para> </section> <!-- {{{ Installation -->

« previous php.doc.cvs (#5860) next »