Showing posts with label equery. Show all posts
Showing posts with label equery. Show all posts

Friday, February 19, 2010

New gentoolkit utility --- analyse

Well, I've gone and done it again, I haven't finished the eclean re-write and I've found something else to work on. It all started from a forum post. He wanted to fix his mistakes and it looked like the only way was the hard way.

Having been doing more gentoolkit coding I put together a quick and dirty python script to output some USE flag info about his installed pkgs. With that and me saying I could add some more code to spit out a package.use file populated with what is installed/what flags enabled/disabled. I have now been coding it up and have it now working for USE flag analysis and rebuild. I plan on adding more so it can analyse and repair keywords and mask files too.














I also would like to code up yet another /etc/portage/package.* cleaning tool. Since It'll have nearly/all the functions needed for gathering the info, may as well do that too. All the main functionality will also be importable for other apps to use as library functions/methods.

analyse rebuild -pv use


analyse analyse -uv use








left: showing the output of the report. Enabled USE flags are marked with a leading + and colored blue. Disabled USE flags are marked - and colored red. Unset USE flags are plain text.

It also indicates if the flag is a system default, the number of packages that have it enabled/disabled/unset and using the --verbose option lists the packages.


right: Part way down the report. notice that mplayer has faac faad flags enabled but ffmpeg does not. Something that I didn't notice before. Now I know to set them for ffmpeg too.




This last one shows the totals at the end of the analyse report.

Also if you can think of a good "e" name for it to go along with the other gentoolkit apps like eclean & equery. Post a comment.

some of the names so far:
  • erepair
  • esylana (analyse spelled backward)

Saturday, November 21, 2009

gentoolkit fun

I've been having some fun working with djanderson on the gentoolkit equery code. We've made great speed improvements to the depends module for reverse dep searches. The real speed improvements were by djanderson's rewrite of the base search code after I had initially split it up into separate search and print modules. There have been 2 benefits so far
  1. Is that consumer apps will be able to import the python modules for its own use without having to parse terminal output. Great for making a plugin for porthole (my original intent)
  2. Is the major speed improvement as a result of the complete rewrite of all the dependency related code from the original package object into its own class. The speeds are now about 25% that of the original code. most equery depends package will now be around the 2 to 3 second mark instead of 8 to 12 seconds. Really long detailed searches are down from 2 - 3 minutes to around 2o seconds!
With the depends module nearing its completion, I'll get back to working on the belongs module. Maybe we'll be able to get more speed out of that one as well.