Re: Conditional package dependencies?

From: Date: Fri, 08 Jun 2007 18:25:13 +0000
Subject: Re: Conditional package dependencies?
References: 1  Groups: php.pear.dev 
Request: Send a blank email to pear-dev+get-46981@lists.php.net to get a copy of this message
Hi, So I could use the SQL driver on PHP 4 if I use dbquery or mdb2, right ? Really the only thing you can do is have php 4 and php 5 as optional, the only real way is to have things split up so that you can have proper deps, that I know of anyway. - Helgi On 6/8/07, Mark Wiesemann <wiesemann@php.net> wrote:
Hi, we like to publish a new DataSource driver for Structures_DataGrid soon. This new driver will combine the current DBQuery and MDB2 drivers (which will be marked as deprecated then), and add additional support for PDO. Because of the usage of a try/catch block around the PDO constructor, we need to require PHP 5 for the new driver, while Structures_DataGrid itself remains PHP 4 compatible. The problem now is that we want to make the new SQLQuery driver the default driver for PHP 5 users if a SQL query is passed to the bind() method. This modified auto-detection would require that our users have the new SQLQuery driver installed; otherwise backwards compatibility would be broken. To keep it short: Is there a way to define a conditional dependency that requires the new driver if PHP 5 is used, and that defines only an optional dependency if PHP 4 is used? Other suggestions on this problem are also welcome, of course. Regards, Mark -- http://www.markwiesemann.eu -- PEAR Development Mailing List (http://pear.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php


« previous php.pear.dev (#46981) next »