Package home | Report new bug | New search | Development Roadmap Status: Open | Feedback | All | Closed Since Version 1.10.18

Request #11213 Portage-like USE flags to automatically install optional dependencies
Submitted: 2007-06-03 07:55 UTC
From: isnull Assigned:
Status: Wont fix Package: PEAR (version 1.5.4)
PHP Version: Irrelevant OS: Irrevelant
Roadmaps: (Not assigned)    
Subscription  
Comments Add Comment Add patch


Anyone can comment on a bug. Have a simpler test case? Does it work for you on a different platform? Let us know! Just going to say 'Me too!'? Don't clutter the database with that please !
Your email address:
MUST BE VALID
Solve the problem : 44 + 32 = ?

 
 [2007-06-03 07:55 UTC] isnull
Description: ------------ PEAR CLI could use a system similar to portage with optionnal packages. If you don't know what is portage, i'll try to explain : * package foo has optionnal dependency : bar * if foo is installed with USE flag 'bar', bar is installed along with foo * if foo is installed with USE flag '-bar', foo is installed without bar * USE could be used like USE='bar' pear install --pretend foo * USE could be setup in a global USE configuration, or locally with a per-package USE flag list Example, sysadmin might install foo with bar : # USE="bar" pear install --pretend foo Sysadmin agrees, sets bar to foo (locally) # echo "foo bar" >> /etc/pear/package.use Sysadmin installs foo with bar : # pear install foo Other example, sysadmin thinks that all packages should have 'bar' USE flag, adds it to a global USE, or to a profile. Then, sysadmin doesn't want 'bar1' in foo : # echo "foo bar -bar1" >> /etc/pear/package.use Finally, default USE flags could be setup in profiles, for example a server profile that would set -gtk, a cli profile that would set -web to PEAR (web would trigger install of the pear web frontend). Also, there could be keywords, like alpha or stable. Sysadmin wants to check what dependencies for alpha package foo : # ACCEPT_KEYWORDS="alpha" pear install --pretend foo Again, keywords could be set up in profile, globally or localy.

Comments

 [2007-06-03 07:56 UTC] cweiske (Christian Weiske)
I think this would be mostly useful for automatically selecting optional dependencies.
 [2007-06-03 07:58 UTC] isnull
cweiske just recalled me that the keyword already exists (prefered_state). But, it could be usefull to be able to set it individually to packages.
 [2007-06-03 19:52 UTC] berdir (Sascha Grossenbacher)
This is possible too pear install Package-beta is the same as pear config-set preferred_state beta pear install Package pear config-set preferred_state stable
 [2007-06-06 07:24 UTC] cweiske (Christian Weiske)
I think with pyrus' tag support, this will be easy to integrate. The list of tags prefixed with "use:" in the optional packages would just need to be checked and compared with local files.
 [2007-06-06 16:04 UTC] cellog (Greg Beaver)
I don't see how adding complex environment variables is preferrable to: pear install Package-beta Package-beta#option1 optional dependency groups are designed for this exact purpose. If you wish to install a subset of optional dependencies, how is this: USE="dep1 dep2" pear install Package-beta any better than pear install Package-beta dep1 dep2 ?
 [2007-06-06 16:16 UTC] cweiske (Christian Weiske)
Those use flags are just to temporary override default ones. The power lies in the default configuration in which you can define default options to be used everytime.
 [2014-06-07 03:17 UTC] cweiske (Christian Weiske)
-Status: Open +Status: Wont fix
We probably will never implement this. You can however provide a patch implementing this feature.