From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) by finch.gentoo.org (Postfix) with ESMTP id 69A5813857C for ; Sat, 19 Jan 2013 21:43:46 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 71BF321C05D; Sat, 19 Jan 2013 21:43:39 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) (using TLSv1 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id BB15021C05D for ; Sat, 19 Jan 2013 21:43:38 +0000 (UTC) Received: from hornbill.gentoo.org (hornbill.gentoo.org [94.100.119.163]) (using TLSv1 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id BD85433DABC for ; Sat, 19 Jan 2013 21:43:37 +0000 (UTC) Received: from localhost.localdomain (localhost [127.0.0.1]) by hornbill.gentoo.org (Postfix) with ESMTP id E654EE4089 for ; Sat, 19 Jan 2013 21:43:34 +0000 (UTC) From: "Sven Eden" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Sven Eden" Message-ID: <1358444698.b7470f766b642212fc25f4e78cc8facd2816c6f2.yamakuzure@gentoo> Subject: [gentoo-commits] proj/ufed:master commit in: / X-VCS-Repository: proj/ufed X-VCS-Files: Portage.pm X-VCS-Directories: / X-VCS-Committer: yamakuzure X-VCS-Committer-Name: Sven Eden X-VCS-Revision: b7470f766b642212fc25f4e78cc8facd2816c6f2 X-VCS-Branch: master Date: Sat, 19 Jan 2013 21:43:34 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Archives-Salt: 39c8a9a7-e5f4-44da-8bcc-7285763cb99e X-Archives-Hash: e32cfdc94f6f16043cf575abeeb44d30 commit: b7470f766b642212fc25f4e78cc8facd2816c6f2 Author: Sven Eden gmx de> AuthorDate: Thu Jan 17 17:44:58 2013 +0000 Commit: Sven Eden gmx de> CommitDate: Thu Jan 17 17:44:58 2013 +0000 URL: http://git.overlays.gentoo.org/gitweb/?p=proj/ufed.git;a=commit;h=b7470f76 Added more commentary to the useless looking part of read_packages() and fixed a copy&paste move error (although that was harmless). --- Portage.pm | 6 +++++- 1 files changed, 5 insertions(+), 1 deletions(-) diff --git a/Portage.pm b/Portage.pm index a69795e..2caed7d 100644 --- a/Portage.pm +++ b/Portage.pm @@ -243,12 +243,14 @@ sub read_packages { # Load PROVIDE ## FIXME: There is no file "PROVIDE" anywhere, at least on my system! if(open my $provide, '<', "$eprefix/var/db/pkg/$cat/$pkg/PROVIDE") { + local $/; @provide = split ' ', <$provide>; close $provide; } # Load USE if(open my $use, '<', "$eprefix/var/db/pkg/$cat/$pkg/USE") { + local $/; @use = split ' ', <$use>; close $use; } @@ -256,9 +258,11 @@ sub read_packages { # could be shortened, but make sure not to strip off part of the name $pkg =~ s/-\d+(?:\.\d+)*\w?(?:_(?:alpha|beta|pre|rc|p)\d*)?(?:-r\d+)?$//; $packages{"$cat/$pkg"} = 1; - local $/; # FIXME: What is this supposed to achieve? + # Currently this does nothing as there is no PROVIDE anywhere, + # but even if it were, there is nothing really done at all with + # @use. for(my $i=0; $i<@provide; $i++) { my $pkg = $provide[$i]; next if $pkg eq '(' || $pkg eq ')';