Situation: Every time I set up a Gentoo system I like to go through and consider each USE-flag. Lately I've been doing it a lot :) but because there is a lot of USE-flags I do not remember every single in detail. The result is that I do have to keep 3 windows open switching between /usr/portage/profiles/use.desc, /etc/make.profile/make.defaults and /etc/make.conf. It is not always so easy to keep track of where I am in each window at every moment, at least that is my experience. Suggested solution: a simple script can parse the files, find which use-flags that is Valid, which use-flags that are in your Profile and which that are Enable. Furthermore the script can print the current state of the USE-flag (with respect to /etc/make.profile/make.defaults and /etc/make.conf) the USE-flag-desription and an option (Enable or Disable) the USE-flag. f.ex. <snip> [ VPE ] x86 - indicates that architecture is x86 Disable or Enable [E]: _ </snip> This indicates that x86 is a valid USE-flag (with respect to use.desc) and is in your profile and currently enabled. Possible pitfalls: 1) There are some flags one should not set/unset oneself, i.e. at least bootstrap, build, x86, ppc, sparc, sparc64 unless you for certain indeed know what you are doing. 2) There might be something that I've overlooked, but as far as I remember are USE-flags set by first parsing make.defaults, then taking USE=... from make.conf (and then USE=... from the environment when running emerge mypackage.) 3) In the future there might be changes in how all this is glued together, but that I cannot take in consideration. Most vise would probably been to write this in pyton, but as I needed it quick and have not touched any python code yet, I wrote an implementation using perl. I believe that it would be better to have this in python (portage-native) and maybe even as a part of portage(?) - what is your opinion about that? Happy gsetuse (Gentoo SET USE-flags)! and .. well .. I sugest this package goes to app-admin/gsetuse All the best, Christian
Created attachment 3656 [details] gentoo-setuse.ebuild.tar.bz2
Created attachment 4545 [details] gsetuse-0.2.tar.bz2
Talked with blizzy on #gentoo-dev today. Seemed like it were interest in a dialog-box for this script and I think it is a good ide
Talked with blizzy on #gentoo-dev today. Seemed like it were interest in a dialog-box for this script and I think it is a good ideá. Blizzy had already made http://www.gentoo.org/~blizzy/use.sh - which require dev-util/dialog merged. I stole a lot from him for my last attachment 4545 [details] now i do not anylonger prompt the user for flags containing internal nor flags containing ( indicates and arcitechture ) In order to use gsetuse-0.2 (attachment 4545 [details]) one needs dev-util/dialog dev-perl/TermReadKey merged .. I'll provide you with a revided ebuild soon Christian
Created attachment 4551 [details] gsetuse-ebuild.tar.bz2 This tar-package includes ebuilds both for gsetuse-0.1 and gsetuse-0.2
ad comment #3, a little specification when talking about "flags containing" I here thought about the part of the line in use.desc that follows the actual use-flag. Regards, Christian
*** Bug 7266 has been marked as a duplicate of this bug. ***
Don't you think you could close this? ufed is out for quite some time...
solution: `emerge ufed`