[pacman-dev] [PATCH v2 0/6] Patches for better optdep support
Resend, as I've incorporated Dan's suggestions from last time. The feature set is still the same, but I've thought about how removal of optdepends should work. See https://wiki.archlinux.org/index.php/User:Moben/Pacman_OptDepends This implements most features from https://wiki.archlinux.org/index.php/User:Allan/Pacman_OptDepends What is there: - No regressions afaics - Only show uninstalled optdepends during install/upgrade - In package info, show [installed] after installed optdepends - In package info (local or -ii) show packages which optionally depend on the queried package - '-Qt' doesn't consider optdepends to be orphans, unless '--nooptdeps/-n' is given What is still missing: - Show which of the packages listed by '-Qtn' is an optdepend and what optdeps on it - In package info display the description alongside the "reverse optdeps" - Recursive removal of unneeded optdeps - Anything listed under "Other Ideas" - Tests (mainly needed for the package removal stuff I think) - Docs with less sucky english ;-) --- Benedikt PS: I'll start working on the rest soon, but that might be delayed due to me going on vacation in the first two weeks of August ;-) Benedikt Morbach (6): Split optdep into alpm_depend_t and description Hook new optdepend structures up Only display uninstalled optdepends during install/upgrade Show optdep install status in package info optdepends are not orphans unless --nooptdepends is specified Make package info show optional requirements doc/pacman.8.txt | 6 +++ lib/libalpm/alpm.h | 14 ++++++- lib/libalpm/be_local.c | 11 ++++- lib/libalpm/be_package.c | 5 +- lib/libalpm/be_sync.c | 7 +++- lib/libalpm/deps.c | 68 +++++++++++++++++++++++++++++++ lib/libalpm/deps.h | 3 + lib/libalpm/package.c | 39 ++++++++++++------ src/pacman/conf.h | 1 + src/pacman/package.c | 13 +++++- src/pacman/pacman.c | 3 + src/pacman/query.c | 16 ++++++- src/pacman/util.c | 99 ++++++++++++++++++++++++++++++++++++++++------ src/pacman/util.h | 1 + src/util/pactree.c | 2 +- 15 files changed, 251 insertions(+), 37 deletions(-) -- 1.7.6
This is done as a preparation to better handle optdepends.
This commit should not change pacman's behaviour, as it simply adds new
functions and data structures and doesn't yet hook them up anywhere.
Signed-off-by: Benedikt Morbach
No new behaviour introduced, everything should work exactly as before.
Signed-off-by: Benedikt Morbach
Signed-off-by: Benedikt Morbach
Signed-off-by: Benedikt Morbach
Signed-off-by: Benedikt Morbach
Signed-off-by: Benedikt Morbach
Signed-off-by: Benedikt Morbach
I forgot to add: This (and future) work is also availiable in the optdep branch on github: https://github.com/moben/pacman --- Benedikt
On 26/07/11 06:31, Benedikt Morbach wrote:
Resend, as I've incorporated Dan's suggestions from last time.
The feature set is still the same, but I've thought about how removal of optdepends should work. See https://wiki.archlinux.org/index.php/User:Moben/Pacman_OptDepends
I took a quick look at your proposal and they seem fine to me. BTW, feel free to add these to "my" page so that the ideas for this can be kept all in one place. Either that, or add a link through to your page. And when I say one place... You could add details in the roadmap: https://wiki.archlinux.org/index.php/Pacman_Roadmap And your git repo details here: https://wiki.archlinux.org/index.php/Pacman_Development
This implements most features from https://wiki.archlinux.org/index.php/User:Allan/Pacman_OptDepends
What is there: - No regressions afaics - Only show uninstalled optdepends during install/upgrade - In package info, show [installed] after installed optdepends - In package info (local or -ii) show packages which optionally depend on the queried package - '-Qt' doesn't consider optdepends to be orphans, unless '--nooptdeps/-n' is given
I have not taken a decent look at the code yet (although, opt_cmp in src/pacman/util.c needs to be declared "static"), but I did take the patches for a spin in a chroot to see this in action. Everything that is in the list above worked for me!
What is still missing: - Show which of the packages listed by '-Qtn' is an optdepend and what optdeps on it - In package info display the description alongside the "reverse optdeps" - Recursive removal of unneeded optdeps - Anything listed under "Other Ideas" - Tests (mainly needed for the package removal stuff I think) - Docs with less sucky english ;-)
--- Benedikt
PS: I'll start working on the rest soon, but that might be delayed due to me going on vacation in the first two weeks of August ;-)
Cool. There is not rush here as I think these patches will probably be scheduled to be included in 4.1 given we appear to be thinking about a 4.0 release in the not to distant future. This will also allow us to correct the optdepends syntax enforcement for the addition of ":" due to epoch in the 4.0 release. Allan
participants (2)
-
Allan McRae
-
Benedikt Morbach