Archive

Posts Tagged ‘satsolver’

zypper – dependency graph
1 star2 stars3 stars4 stars5 stars
(no votes yet)
Loading ... Loading ...

March 24th, 2010 11 comments

Yesterday, we needed with darix to obtain a dependency graph of the package you are about to install. I knew that something similar was planned in zypper, so I went to Jano Kupec to check the status of it. Unfortunately, I learned that this feature is not implemented yet. I think it should not be very hard to enhance the zypper package list with some eye-candy, but I haven’t looked into it yet. I would love to have these outputs similar to Gentoo ones (colors and simple ASCII art dependency trees). Btw, zypper already has color support, so if you want to start hacking, there is source code in gitorious.

Jano also showed me a neat trick how to obtain the results we wanted anyway. If you are in similar situation, just follow these steps (they are of course not suitable for everyday use, but still better than nothing):

  1. install package libzypp-testsuite-tools
  2. run zypper install --debug-solver pkg
  3. cd into /var/log/zypper.solverTestCase
  4. open solver-test.xml in your favorite editor
  5. add <graphic/> tag just above the </trial> closing tag
  6. run /usr/lib/zypp/testsuite/bin/deptestomatic.multi solver-test.xml (as normal user, you won’t get any graph when running as root)
  7. you can pan the graph, rotate it with the right click or even save it to disk!

The resulting image can be seen here:

Scout finally searches in zypp repositories
1 star2 stars3 stars4 stars5 stars
(no votes yet)
Loading ... Loading ...

August 8th, 2008 No comments

I finally implemented very important feature of scout: It is now able to search for binaries in all enabled zypp repositories. SAT-solver files are used for this, so user does not have to install any external index files. I really would like to thank Klaus Kaempf for his exhaustive help with python bindings for satsolver. Another great news are that Werner Fink applied command-not-found patch for bash package, so 11.1 will probably contain this feature working out of the box! Current early implementation has one problem though: it is pretty slow comparing to older use-own-sqlite-database approach (2 seconds compared to 0.2 seconds). But it indexes more repositories at once (I have 14 enabled) and I believe the code could more optimized and thus whole search faster in the (near) future.

Feel free to test the packages from BuildService (follow the instructions on wiki) and tell me what you think of it ! :)