Re: Deploying binary PHP extensions
| From: | Pierre | Date: | Sun, 06 Jan 2008 22:14:16 +0000 |
| Subject: | Re: Deploying binary PHP extensions | ||
| References: | 1 | Groups: | php.pecl.dev |
| Request: | Send a blank email to pecl-dev+get-5029@lists.php.net to get a copy of this message | ||
On Jan 6, 2008 10:30 PM, Christian Dahlqvist <acdahlqvist@gmail.com> wrote:
> Hi,
>
> I have recently started developing a product (closed source) in PHP and need
> to implement portions of it as an extension, primarily for performance
> reasons. I would therefore like to deliver this extension in binary form as
> part of the product.
>
> Although I have never developed PHP extensions before I have started, and
> have got a simple one working. I can run it from the command line (php -f
> testscript.php) without any problems, but can not get it to work when I try
> to install it under the web server on another machine.
>
> I have copied over the .so file and placed it in the modules directory, and
> I have added an entry to the php.ini file for my new extension. (ALL
> php.inifiles I could find actually...). When I try to run it there
> using a couple
> of test scripts, it does not work. It does not seem to be able to execute
> the extension, and I can not see the extension or the extension parameters
> when I run php_info().
>
> I suspect there are one or more steps I must have missed somewhere. Can
> someone give me a pointer in the right direction?
>
> Do I need to recompile or reconfigure PHP on the server? How would I do
> this?
What do you see in the error logs?
You will need one build for each PHP version and its mode. For
example, 5.2.x thread safe and 5.2.x not thread safe, 5.1.x etc.
> What is the best way to deploy extensions in binary form to a customer?
There is no good way to deploy binary closed sources extension, or
provide packages for the major distributions :)
--
Pierre
http://blog.thepimp.net | http://www.libgd.org