[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: [PHP] Standard placement of PHP libraries?



On Wednesday 03 of August 2005 15:34, Jose Carlos do Nascimento wrote:
> Do you know  if is possible  configure pear  to read 2 directories ?
> example,  /usr/share/pear  and /usr/local/share/pear  ?
> Because if it read just one directory,  we wont  waste time  thinking
> about it;.

AFAIR know. See `pear config-show` output.

> we can disable "-upgrade" option in pear   creating one patch :)    and
> disable other options too.
> or change these options to other thing,  like  try upgrade packages
> that  arent  installed in /usr/share/pear,   and if it try upgrade one
> module that was installed by php-pear return an error.

What will happen if you upgrade PEAR itself? I think we shouldn't mess with 
original libraries and the best thing would be installing them into other 
directory.

Just my `pear config-list' output:

PEAR executables directory     bin_dir         /usr/local/bin
PEAR documentation directory   doc_dir         /usr/local/share/php/docs
PHP extension directory        ext_dir         /usr/local/lib/php
PEAR directory                 php_dir         /usr/local/share/php
PEAR Installer cache directory cache_dir       /tmp/pear/cache
PEAR data directory            data_dir        /usr/local/share/php/data
PHP CLI/CGI binary             php_bin         /usr/bin/php
PEAR test directory            test_dir        /usr/local/share/php/data

So, even I'll do `pear install PEAR', I won't destroy my system.

> pear cant upgrade files in php4-pear  package.
> we can create links to pear modules   in /usr/loca/share/pear  to
> /usr/share/pear.
> if I install  php4-pear and php5-pear   ,,  both  will try to install
> /usr/sbin/pear  command,,   we need to solve it

IMHO, we *shouldn't* mix Debian packaging system (/usr/share) and PEAR 
packaging system (/usr/local/share). PEAR shouldn't overwrite dpkg's files 
and dpkg shouldn't overwrite files installed by `pear install'!

dpkg-alternatives gives the best solution for co-existing php4-pear and 
php5-pear. The first installs /usr/bin/pear4 binary, the second 
installs /usr/bin/pear5 binary, then dpkg-alternatives installs 
symlink /usr/bin/pear.

-- 
 .''`.    Piotr Roszatycki, Netia SA
: :' :    mailto:Piotr_Roszatycki@netia.net.pl
`. `'     mailto:dexter@debian.org
  `-



Reply to: