Although PHP has a great library of functions, many of them are not included in the standard build, or haven’t been included into the popular package installers like yum or apt-get. The man page doesn’t leave you with much instruction, other than something like “compile PHP with the flag –with-pspell[=dir]”. At this point you have 2 options:
.so) that you copy into a PHP directory, and edit php.ini. If you are running multiple machines on the same OS, you can just copy the file to all those machines as well. Much easier, and you can turn it on and off at will.
Here’s how to create the extension for modules that appear in the PHP manual on a linux-based system (for third-party extensions, it’s most likely the same).
php-devel. You’ll need its components in a few steps.ext/ directory that should contain a subdirectory for the module that you’re looking for. Change to that subdirectory, i.e. ext/pspell/.phpize./configure –with-pspell=/usr--with-mysqli=/usr/local/mysql/bin/mysql_config. Be aware that the path is sometimes a base directory, and sometimes needs to point to a specific file. Read the PHP docs carefully.make.so file (most likely in the modules/ subdirectory of your current location). Copy the .so file to your PHP extensions directory, i.e. /usr/lib/php/modules. If you don’t know this, it’s listed in your php.ini file under the extension_dir parameter. You’ll need root access to do this.extension=pspell.so/etc/php.d directory in it’s own ini file for a cleaner installation approach.
phpinfo() to verify that your new module is installedRSS feed for comments on this post. TrackBack URI
What’s a “man page”?
Comment by Jeff — June 17, 2006 @ 9:03 am
I guess he mean “main” :p
Comment by Alixky — June 21, 2006 @ 6:05 pm
Um… no. By a “man page” he’s referring to the *nix command ‘man’ which accesses the MANual pages for a given app/command/etc–in other words, the built-in help file.
The fact that you don’t know this suggests that everything in this tutorial is beyond your *nix knowledge and/or ability. Caution is advised.
Comment by Nomina — July 17, 2006 @ 2:13 pm