Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
HOWTO: Clean your /etc/portage/package.* files
View unanswered posts
View posts from last 24 hours

Goto page Previous  1, 2, 3  
Reply to topic    Gentoo Forums Forum Index Unsupported Software
View previous topic :: View next topic  
Author Message
gentoo_lan
l33t
l33t


Joined: 08 Sep 2004
Posts: 887
Location: Osan AB, South Korea

PostPosted: Mon Jan 23, 2006 4:02 am    Post subject: Reply with quote

I'm glad I found this script again. I had an older version I hadn't used in a while and the new version works great.
_________________
Registered Linux user# 375038.
Back to top
View user's profile Send private message
teh-steve
n00b
n00b


Joined: 28 Jan 2005
Posts: 27
Location: Worcester

PostPosted: Fri Feb 10, 2006 4:14 am    Post subject: Reply with quote

Still waiting for that update So Tired. How's it coming along?
Back to top
View user's profile Send private message
gentoo_lan
l33t
l33t


Joined: 08 Sep 2004
Posts: 887
Location: Osan AB, South Korea

PostPosted: Sun Feb 12, 2006 10:32 pm    Post subject: Reply with quote

This script also needs improvements to include checks for package.provided. I may try to alter the script myself to see if I can improve it.
_________________
Registered Linux user# 375038.
Back to top
View user's profile Send private message
red-wolf76
l33t
l33t


Joined: 13 Apr 2005
Posts: 713
Location: Rhein-Main Area

PostPosted: Mon Apr 17, 2006 11:01 pm    Post subject: Reply with quote

First of all, this script rocks for a lark! 8)

I did find a bit of a cockup with some of the fonts from the modular Xorg list, though. The relevant part of portage.keywords reads:
Code:
media-fonts/font-adobe-100dpi
media-fonts/font-adobe-75dpi
media-fonts/font-adobe-utopia-100dpi
media-fonts/font-adobe-utopia-75dpi
media-fonts/font-adobe-utopia-type1
media-fonts/font-alias
media-fonts/font-arabic-misc
media-fonts/font-bh-100dpi
media-fonts/font-bh-75dpi
media-fonts/font-bh-lucidatypewriter-100dpi
media-fonts/font-bh-lucidatypewriter-75dpi
media-fonts/font-bh-ttf
media-fonts/font-bh-type1
media-fonts/font-bitstream-100dpi
media-fonts/font-bitstream-75dpi
The script will incorrectly mark duplicates for
media-fonts/font-adobe
media-fonts/font-adobe-utopia
media-fonts/font-bh
media-fonts/font-bh-lucidatypewriter and
media-fonts/font-bitstream,
all of which have numbers directly following them. So I guess the script thinks they're versioned...

Other than that, great!
_________________
0mFg, G3nt00 r0X0r$ T3h B1g!1111 ;)

Use sane CFLAGS! If for no other reason, do it for the lulz!
Back to top
View user's profile Send private message
slycordinator
Advocate
Advocate


Joined: 31 Jan 2004
Posts: 3050
Location: Houston, TX

PostPosted: Tue Apr 18, 2006 12:38 am    Post subject: Reply with quote

red-wolf76 wrote:
First of all, this script rocks for a lark! 8)

I did find a bit of a cockup with some of the fonts from the modular Xorg list, though. The relevant part of portage.keywords reads:
Code:
media-fonts/font-adobe-100dpi
media-fonts/font-adobe-75dpi
media-fonts/font-adobe-utopia-100dpi
media-fonts/font-adobe-utopia-75dpi
media-fonts/font-adobe-utopia-type1
media-fonts/font-alias
media-fonts/font-arabic-misc
media-fonts/font-bh-100dpi
media-fonts/font-bh-75dpi
media-fonts/font-bh-lucidatypewriter-100dpi
media-fonts/font-bh-lucidatypewriter-75dpi
media-fonts/font-bh-ttf
media-fonts/font-bh-type1
media-fonts/font-bitstream-100dpi
media-fonts/font-bitstream-75dpi
The script will incorrectly mark duplicates for
media-fonts/font-adobe
media-fonts/font-adobe-utopia
media-fonts/font-bh
media-fonts/font-bh-lucidatypewriter and
media-fonts/font-bitstream,
all of which have numbers directly following them. So I guess the script thinks they're versioned...

Other than that, great!


Actually, what I'm seeing happen is this:
There is no such package as media-fonts/font-adobe. But there is a package called media-fonts/font-adobe-100dpi. The script is assuming the "100dpi" part is part of the version number when it is not.

For instance, I have media-fonts/font-adobe-100dpi-1.0.0 installed. 1.0.0 is the version. Everything before it is a package name.
Back to top
View user's profile Send private message
nesl247
Veteran
Veteran


Joined: 15 Jun 2004
Posts: 1614
Location: Florida

PostPosted: Tue Apr 18, 2006 3:23 am    Post subject: Reply with quote

Sly, that is exactly what he said..
Back to top
View user's profile Send private message
slycordinator
Advocate
Advocate


Joined: 31 Jan 2004
Posts: 3050
Location: Houston, TX

PostPosted: Tue Apr 18, 2006 5:32 am    Post subject: Reply with quote

nesl247 wrote:
Sly, that is exactly what he said..


I assumed when he said "incorrectly mark duplicates" it was meaning that those entries would incorrectly be marked as duplicate entries, rather than being marked as entries for items not installed.
Back to top
View user's profile Send private message
nesl247
Veteran
Veteran


Joined: 15 Jun 2004
Posts: 1614
Location: Florida

PostPosted: Tue Apr 18, 2006 5:34 am    Post subject: Reply with quote

I was referring to your explanation, and when he said "all of which have numbers directly following them. So I guess the script thinks they're versioned...". Didn't catch that other part.
Back to top
View user's profile Send private message
red-wolf76
l33t
l33t


Joined: 13 Apr 2005
Posts: 713
Location: Rhein-Main Area

PostPosted: Tue Apr 18, 2006 9:02 am    Post subject: Reply with quote

slycordinator wrote:
Actually, what I'm seeing happen is this:
There is no such package as media-fonts/font-adobe. But there is a package called media-fonts/font-adobe-100dpi. The script is assuming the "100dpi" part is part of the version number when it is not.

For instance, I have media-fonts/font-adobe-100dpi-1.0.0 installed. 1.0.0 is the version. Everything before it is a package name.
Absolutely correct. So while media-fonts/adobe-100dpi and media-fonts/adobe-75dpi are installed - regardless of their true version number - the script (erroneously) treats them as versions 100 and 75 of a fictitious package called "media-fonts/adobe".

Given that the RegEx is such a pain to edit, I'm guessing there would be a way to get it to recognize font dpis, but it would be somewhat hard and stony. :?

I just posted that to ensure that people don't go off deleting "duplicates" and thrashing their modular Xorg installation's fonts...
_________________
0mFg, G3nt00 r0X0r$ T3h B1g!1111 ;)

Use sane CFLAGS! If for no other reason, do it for the lulz!
Back to top
View user's profile Send private message
slycordinator
Advocate
Advocate


Joined: 31 Jan 2004
Posts: 3050
Location: Houston, TX

PostPosted: Tue Apr 18, 2006 8:26 pm    Post subject: Reply with quote

red-wolf76 wrote:
I just posted that to ensure that people don't go off deleting "duplicates" and thrashing their modular Xorg installation's fonts...


Since the script only provides removing entries in an "all-or-none" fashion all you'd have to do is:

1) Run the script, remove all entries it says are bad.
2) Run "emerge world --update --deep --newuse -pv"
3) Whenever a package comes up as being needed but masked, unmask it again
4) Repeat steps 2 and 3 until no errors occur.
Back to top
View user's profile Send private message
Onip
Advocate
Advocate


Joined: 02 Sep 2004
Posts: 2735
Location: Parma (Italy)

PostPosted: Thu Jul 13, 2006 4:41 pm    Post subject: Reply with quote

I've noticed a little problem
Code:
Hal9000 ~ # ./etcportclean
Check package.keywords for unnecessary keywords? (yes/no)
y
Check package.mask for needlessly masked packages? (yes/no)
y
Check package.use for unnecessary use flags? (yes/no)
y
Check package.cflags for repeat cflags? (yes/no)
n
Check package.cxxflags for repeat cxxflags? (yes/no)
n
./etcportclean: line 738: [: too many arguments  <-- PROBLEM

Checking for unnecessary entries in package.keywords...


Here's what I have at that line
Code:
   if [ ${ynarray[0]} -eq 1 -o ${ynarray[1]} -eq 1 -o ${ynarray[2]} -eq 1 ] ; then checkworld ; fi


Thanks
_________________
Linux Registered User n. 373835

Titus Lucretius Carus, De Rerum Natura - Tanto religio potuit suadere malorum
Back to top
View user's profile Send private message
aguettinger
Tux's lil' helper
Tux's lil' helper


Joined: 26 Sep 2003
Posts: 83

PostPosted: Sat Jul 15, 2006 3:05 pm    Post subject: Reply with quote

This script is very useful. :!:
I have a request, though. As I want maximum control myself, I would love to see a flag so the script just comments (#) the obsolete entries in packages.keywords instead to actually remove them. I usually have a lot of commented lines in package.keywords.
Furthermore I support the request for a --pretend flag. :)

Hope to see a rewrite of this soon.
_________________
regards
- andy
Back to top
View user's profile Send private message
basiaf
n00b
n00b


Joined: 25 Feb 2005
Posts: 38
Location: Dortmund

PostPosted: Sun Aug 27, 2006 8:18 pm    Post subject: Reply with quote

Just found this script again (my last version was 1.13). I like this script very much, but it would be great if you could add support for the portage 2.1 config-files-as-directories feature ( e.g. package.keywords/xgl, package.keywords/foo )
Back to top
View user's profile Send private message
mv
Advocate
Advocate


Joined: 20 Apr 2005
Posts: 2589

PostPosted: Thu Aug 31, 2006 7:48 am    Post subject: Reply with quote

basiaf wrote:
Just found this script again (my last version was 1.13). I like this script very much, but it would be great if you could add support for the portage 2.1 config-files-as-directories feature ( e.g. package.keywords/xgl, package.keywords/foo )

As it still seems to be rather unknown, I would like to point out that >=eix-0.6.3 provides with eix -tT a similar functionality as this script, however without actual removal of the entries; details of the mentioned functionality are highly cusomizable - see man eix. eix supports this config-files-as-directories feature.

Concerning the other bug with the falsely recognized version numbers and the fonts: It seems rather obvious to me that some regular expression in the script fails to be greedy, as the version number is the last (not the first) item of the name starting with -[0-9]. However, I did not check through the script where this happens, since for my purposes eix is more appropriate anyway...
Back to top
View user's profile Send private message
slycordinator
Advocate
Advocate


Joined: 31 Jan 2004
Posts: 3050
Location: Houston, TX

PostPosted: Thu Aug 31, 2006 8:25 am    Post subject: Reply with quote

Gatak wrote:
What do you mean with versioned keywords? The example ~dev-php/jpgraph-1.17 ~x86 is wrong. It should be =dev-php/jpgraph-1.17 ~x86 or >=dev-php/jpgraph-1.17 ~x86 or <=dev-php/jpgraph-1.17 ~x86


That's not true.
~dev-php/jpgraph-1.17 ~x86

is perfectly valid.

What it does is it unmasks any version which has 1.17 in it. So if I had version 1.17-r1 then it would get unmasked as well. So it essentially unmasks any revision of 1.17.

edit:
None of your suggestions do what this one does.
1) =dev-php/jpgraph-1.17 just unmasks that version and no others
2) >=dev-php/jpgraph-1.17 unmasks EVERY version greater than or equal to it.
3) <=dev-php/jpgraph-1.17 unmasks EVERY version less than or equal to it

The usefulness of this is if I think a newer branch is too buggy I can force my unmask to just work on the 1.17 branch.
Back to top
View user's profile Send private message
lmcogs
Guru
Guru


Joined: 03 Apr 2005
Posts: 340

PostPosted: Fri Nov 17, 2006 7:51 pm    Post subject: Reply with quote

Hi I tried this and seems to work fine for me. Pretty handy it seems but have not tried extensively only etcportclean -c

2.6.17-gentoo-r4 #1 SMP Mon Aug 21 01:27:10 GMT 2006 x86_64 AMD Athlon(tm) 64 X2 Dual Core Processor 4400+ AuthenticAMD GNU/Linux
Back to top
View user's profile Send private message
cpicton
n00b
n00b


Joined: 12 Oct 2004
Posts: 7

PostPosted: Tue Jan 01, 2008 5:56 am    Post subject: Reply with quote

Hi

Script has problems with directories:

I have /etc/portage/package.keywords/*, so I can keep track of keyworded packages more easily. The script fails saying that package.keywords must exist.
Back to top
View user's profile Send private message
red-wolf76
l33t
l33t


Joined: 13 Apr 2005
Posts: 713
Location: Rhein-Main Area

PostPosted: Tue Jan 01, 2008 12:48 pm    Post subject: Reply with quote

slycordinator wrote:
Gatak wrote:
What do you mean with versioned keywords? The example ~dev-php/jpgraph-1.17 ~x86 is wrong. It should be =dev-php/jpgraph-1.17 ~x86 or >=dev-php/jpgraph-1.17 ~x86 or <=dev-php/jpgraph-1.17 ~x86


That's not true.
~dev-php/jpgraph-1.17 ~x86

is perfectly valid.

What it does is it unmasks any version which has 1.17 in it. So if I had version 1.17-r1 then it would get unmasked as well. So it essentially unmasks any revision of 1.17.

edit:
None of your suggestions do what this one does.
1) =dev-php/jpgraph-1.17 just unmasks that version and no others
2) >=dev-php/jpgraph-1.17 unmasks EVERY version greater than or equal to it.
3) <=dev-php/jpgraph-1.17 unmasks EVERY version less than or equal to it

The usefulness of this is if I think a newer branch is too buggy I can force my unmask to just work on the 1.17 branch.

I concur. I use the
Code:
~package-foo/bar-0.0.1
syntax almost exclusively in my package.keywords file. It would be nice if it were more commonly recognized.
_________________
0mFg, G3nt00 r0X0r$ T3h B1g!1111 ;)

Use sane CFLAGS! If for no other reason, do it for the lulz!
Back to top
View user's profile Send private message
dfelicia
Apprentice
Apprentice


Joined: 11 May 2005
Posts: 281
Location: Southwestern Connecticut

PostPosted: Fri Jul 25, 2008 1:49 pm    Post subject: Reply with quote

Script doesn't work with latest sed (sys-apps/sed-4.1.5-r1):

Code:

sed: -e expression #1, char 41: Invalid range end
Back to top
View user's profile Send private message
loftwyr
l33t
l33t


Joined: 29 Dec 2004
Posts: 970
Location: 43°38'23.62"N 79°27'8.60"W

PostPosted: Fri Jul 25, 2008 4:29 pm    Post subject: Reply with quote

This script was abandoned two years ago.

We need someone to step up and revamp it. It would be nice if it also handled paludis and other package managers.
_________________
My emerge --info
Have you run revdep-rebuild lately? It's in gentoolkit and it's worth a shot if things don't work well.
Celebrating 5 years of Gentoo-ing.
Back to top
View user's profile Send private message
forkboy
Apprentice
Apprentice


Joined: 24 Nov 2004
Posts: 200
Location: Blackpool, UK

PostPosted: Fri Jul 25, 2008 4:37 pm    Post subject: Reply with quote

I use app-portage/portpeek from portage, does it do the same thing?
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Unsupported Software All times are GMT
Goto page Previous  1, 2, 3
Page 3 of 3

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum