Attached is an ebuild for the PEAR base system. I propose to pass "--without-pear" to configure in the dev-php/php and dev-php/mod_php ebuilds and let them RDEPEND on dev-php/PEAR-PEAR instead. This way new versions of the PEAR base system can be available in Portage before a new PHP release occurs. Independence from release cycles (PHP and PEAR in this case) is generally a good thing, IMHO. Reproducible: Always Steps to Reproduce: 1. 2. 3.
Created attachment 47819 [details] PEAR-PEAR-1.3.4.ebuild
dev-php/PEAR-PEAR-1.3.4 is in portage now. Passing "--without-pear" to configure in the dev-php/php and dev-php/mod_php ebuilds makes no sense as the bundled PEAR is needed for bootstrapping the PEAR installer. Just adding dev-php/PEAR-PEAR to the RDEPEND of these packages will do the trick.
Created attachment 51405 [details, diff] Patch to the PHP SAPI eclasses that adds RDEPEND on dev-php/PEAR-PEAR Patch to the PHP SAPI eclasses that adds RDEPEND on dev-php/PEAR-PEAR. It works fine with the dev-php/mod_php ebuild. It does not work with the dev-php/php ebuild as this want to pull in the RDEPENDencies *before* dev-php/php: wopr-mobile ~ # emerge -p php These are the packages that I would merge, in order: Calculating dependencies ...done! [ebuild N ] dev-php/PEAR-XML_RPC-1.1.0 [ebuild N ] dev-php/PEAR-Archive_Tar-1.2 [ebuild N ] dev-php/PEAR-Console_Getopt-1.2 [ebuild N ] dev-php/PEAR-PEAR-1.3.4 [ebuild N ] dev-php/php-5.0.3 wopr-mobile ~ # emerge -p mod_php These are the packages that I would merge, in order: Calculating dependencies ...done! [ebuild N ] dev-php/php-5.0.3 [ebuild N ] dev-php/PEAR-Archive_Tar-1.2 [ebuild N ] dev-php/PEAR-XML_RPC-1.1.0 [ebuild N ] dev-php/PEAR-Console_Getopt-1.2 [ebuild N ] dev-php/PEAR-PEAR-1.3.4 [ebuild N ] dev-php/mod_php-5.0.3 wopr-mobile ~ # emerge -p php These are the packages that I would merge, in order: Calculating dependencies ...done! [ebuild N ] media-libs/pdflib-5.0.4_p1-r1 [ebuild N ] app-text/sablotron-1.0.1 [ebuild N ] dev-php/PEAR-XML_RPC-1.1.0 [ebuild N ] dev-php/PEAR-Archive_Tar-1.2 [ebuild N ] dev-php/PEAR-Console_Getopt-1.2 [ebuild N ] dev-php/PEAR-PEAR-1.3.4 [ebuild N ] net-libs/libwww-5.4.0-r2 [ebuild N ] dev-php/php-4.3.10 wopr-mobile ~ # emerge -p mod_php These are the packages that I would merge, in order: Calculating dependencies ...done! [ebuild N ] media-libs/pdflib-5.0.4_p1-r1 [ebuild N ] app-text/sablotron-1.0.1 [ebuild N ] net-libs/libwww-5.4.0-r2 [ebuild N ] dev-php/php-4.3.10 [ebuild N ] dev-php/PEAR-Archive_Tar-1.2 [ebuild N ] dev-php/PEAR-XML_RPC-1.1.0 [ebuild N ] dev-php/PEAR-Console_Getopt-1.2 [ebuild N ] dev-php/PEAR-PEAR-1.3.4 [ebuild N ] dev-php/mod_php-4.3.10
Another issue with eclass patch that is attached to this bug is the fact that remerging/updating dev-php/php or dev-php/mod_php results in overwriting the files installed by dev-php/PEAR-PEAR. The eclass needs to check whether dev-php/PEAR-PEAR is installed and add "--disable-pear" to the configure options if that is the case.
Hi Sebastian, This is an interesting idea. Couple of thoughts which might prove useful. a) Why not simply *always* install dev-php/php with --disable-pear? And then make sure that the php[5]-sapi.eclass *never* installs any PEAR-related files? b) Try using PDEPEND instead of RDEPEND. Best regards, Stu
If we were to use --disable-pear always we could not use the pear eclass for dev-php/PEAR-PEAR and the packages it depends on.
Created attachment 51762 [details, diff] Patch to the PHP SAPI eclasses that adds PDEPEND on dev-php/PEAR-PEAR
Re comment #6: why would that prevent the PEAR eclass from working?
ebuilds that use the PEAR eclass call "pear install <package>" to install a PEAR package. This obviously requires the PEAR Installer to be installed.
The new PEAR-PEAR-1.3.5-r1 ebuild fixes the issue in #9.
http://bugs.gentoo.org/show_bug.cgi?id=86685 This needs to be corrected in the php-sapi.eclass as well. Hoping this is done soon, since it breaks pear entirely. Wendall
i have emerged on a new gentoo install: apache-2.0.54-r11 mod_php-5.1.0_beta-r1 php-5.1.0_beta-r1 but the "pear command" is not found, so i unmasked the PEAR-PEAR-1.3.5-r1 as reported in this bugreport (#9) that correct the problem; i put in packages.keywords: =dev-php/PEAR-PEAR-1.3.5-r1 ~x86 but when i merge, the problem persist: /usr/portage/dev-php/PEAR-PEAR/PEAR-PEAR/1.3.5-r1.ebuild: line 101: pear: command not found. the problem at #9 point is not fixed! tested this situation on 2 gentoo machine, same problem.
there is an other bug with PEAR-PEAR-1.3.5-r1: is missing the file PEAR.php
Hi, This should now be fixed by the packages in the Gentoo PHP Overlay [1]. Please test, and re-open this bug if you still have issues. [1] http://svn.gnqs.org/projects/gentoo-php-overlay/ Best regards, Stu