Thodoris wrote:

Is fileinfo pecl extension installed as a package or with pecl? In case it is installed as an rpm try to remove it and install it as an extension in case the package is broken for some reason.

I installed it with PECL:

/usr/share/pear/bin/pecl install fileinfo

Other question: where does PECL install this? It's not under /usr/share/pear AFAIK. This is the same as with the dev box, so I don't think it's an issue; I'm just curious.

Pear and pecl are different. Pear is used to install pure PHP-coded extensions that you can include in your projects. You can use this piece of code that pear provides by just copying it somewhere and including it though not recommended IMHO. Pecl on the other hand provides C-coded extensions that you need to compile and may provide for eg APIs for known libraries that must exist in your system.

That is what pecl command does downloads, compiles and installs the extension.

A wild guess is that your modules probably live under the /usr/lib/php/modules directory or in a directory under the /usr/lib/php.


Anyway, as I said, phpinfo() tells me it's installed & enabled.

Have in mind that you will need the magic_open library for this to work.

You mean libmagic? I have file-4.17-15.el5_3.1, which provides libmagic, installed. Strangely, for Fedora, it comes in the file-libs package. But I know that, for the dev box, I had to install file-devel to get this all working. Neither of these appear to be available for RHEL, which I'm discovering is a bit "interesting" to deal with, package-wise.

The file package also provides /usr/share/file/magic*, which I have. I'd created a link to /etc/magic.mime but decided in the end to just pass the correct path to finfo().



--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to