summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHarald van Dijk <truedfx@gentoo.org>2006-05-23 05:12:13 +0000
committerHarald van Dijk <truedfx@gentoo.org>2006-05-23 05:12:13 +0000
commit1542b7cb72216980f3e88e3db98e5bd3ba0152bc (patch)
treea13488fc84624433c1e0cf6dfecfb624d668c614 /app-portage
parentMarking stable per bug #123066 (diff)
downloadgentoo-2-1542b7cb72216980f3e88e3db98e5bd3ba0152bc.tar.gz
gentoo-2-1542b7cb72216980f3e88e3db98e5bd3ba0152bc.tar.bz2
gentoo-2-1542b7cb72216980f3e88e3db98e5bd3ba0152bc.zip
Add support for 'source' in make.conf (#131275)
(Portage version: 2.1_rc1-r3)
Diffstat (limited to 'app-portage')
-rw-r--r--app-portage/ufed/ChangeLog8
-rw-r--r--app-portage/ufed/files/digest-ufed-0.40-r21
-rw-r--r--app-portage/ufed/files/ufed-0.40-source.patch68
-rw-r--r--app-portage/ufed/ufed-0.40-r2.ebuild39
4 files changed, 115 insertions, 1 deletions
diff --git a/app-portage/ufed/ChangeLog b/app-portage/ufed/ChangeLog
index 9cbf260a25d2..9cd83b1cd35c 100644
--- a/app-portage/ufed/ChangeLog
+++ b/app-portage/ufed/ChangeLog
@@ -1,6 +1,12 @@
# ChangeLog for app-portage/ufed
# Copyright 2003-2006 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/app-portage/ufed/ChangeLog,v 1.42 2006/04/04 10:21:20 flameeyes Exp $
+# $Header: /var/cvsroot/gentoo-x86/app-portage/ufed/ChangeLog,v 1.43 2006/05/23 05:12:13 truedfx Exp $
+
+*ufed-0.40-r2 (23 May 2006)
+
+ 23 May 2006; Harald van Dijk <truedfx@gentoo.org>
+ +files/ufed-0.40-source.patch, +ufed-0.40-r2.ebuild:
+ Add support for 'source' in make.conf (#131275)
04 Apr 2006; Diego Pettenò <flameeyes@gentoo.org> ufed-0.40-r1.ebuild:
Add ~x86-fbsd keyword.
diff --git a/app-portage/ufed/files/digest-ufed-0.40-r2 b/app-portage/ufed/files/digest-ufed-0.40-r2
new file mode 100644
index 000000000000..2345f518f492
--- /dev/null
+++ b/app-portage/ufed/files/digest-ufed-0.40-r2
@@ -0,0 +1 @@
+MD5 81c6dc3af93d6ab2f592ba2cd7b1ee7f ufed-0.40.tar.bz2 20288
diff --git a/app-portage/ufed/files/ufed-0.40-source.patch b/app-portage/ufed/files/ufed-0.40-source.patch
new file mode 100644
index 000000000000..d1e04f3dfd31
--- /dev/null
+++ b/app-portage/ufed/files/ufed-0.40-source.patch
@@ -0,0 +1,68 @@
+--- ufed-0.40/ufed.pl
++++ ufed-0.40/ufed.pl
+@@ -179,6 +179,7 @@
+ close $makeconf;
+ }
+
++ my $sourcing = 0;
+ eval {
+ # USE comment start/end (start/end of newline character at the end, specifically)
+ # default to end of make.conf, to handle make.confs without #USE=
+@@ -200,8 +200,12 @@
+ /\G$IDENT/gc or die;
+ my $name = $1;
+ /\G$BLANK/gc;
++ if($name ne 'source') {
+ /\G$ASSIG/gc or die;
+ /\G$BLANK/gc;
++ } else {
++ $sourcing = 1;
++ }
+ die if pos == length;
+ my $valstart = pos;
+ /\G(?:$BNUQV|$SQVAL|$BNDQV)+/gc or die;
+@@ -295,6 +300,10 @@
+ };
+ die "Parse error when writing make.conf - did you modify it while ufed was running?\n" if $@;
+
++ print STDERR <<EOF if $sourcing;
++Warning: source command found in /etc/make.conf. Flags may
++be saved incorrectly if the sourced file modifies them.
++EOF
+ {
+ open my $makeconf, '>', '/etc/make.conf' or die "Couldn't open /etc/make.conf\n";
+ print $makeconf $_;
+--- ufed-0.40/Portage.pm
++++ ufed-0.40/Portage.pm
+@@ -250,8 +250,10 @@
+ /\G$IDENT/gc or die;
+ my $name = $1;
+ /\G$BLANK/gc;
++ if($name ne 'source') {
+ /\G$ASSIG/gc or die;
+ /\G$BLANK/gc;
++ }
+ die if pos == length;
+ my $value = '';
+ for(;;) {
+@@ -275,7 +277,20 @@
+ last
+ }
+ }
++ if($name eq 'source') {
++ open my $f, '<', $value or die;
++ my $pos = pos;
++ substr($_, pos, 0) = do {
++ local $/;
++ my $text = <$f>;
++ die if not defined $text;
++ $text;
++ };
++ pos = $pos;
++ close $f or die;
++ } else {
+ $env{$name} = $value;
++ }
+ }
+ };
+ die "Parse error in $fname\n" if $@;
diff --git a/app-portage/ufed/ufed-0.40-r2.ebuild b/app-portage/ufed/ufed-0.40-r2.ebuild
new file mode 100644
index 000000000000..83c250e073df
--- /dev/null
+++ b/app-portage/ufed/ufed-0.40-r2.ebuild
@@ -0,0 +1,39 @@
+# Copyright 1999-2006 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/app-portage/ufed/ufed-0.40-r2.ebuild,v 1.1 2006/05/23 05:12:13 truedfx Exp $
+
+inherit eutils
+
+DESCRIPTION="Gentoo Linux USE flags editor"
+HOMEPAGE="http://www.gentoo.org/"
+SRC_URI="mirror://gentoo/${P}.tar.bz2
+ http://dev.gentoo.org/~truedfx/${P}.tar.bz2"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~x86-fbsd"
+IUSE=""
+DEPEND="sys-libs/ncurses"
+RDEPEND="${DEPEND}
+ dev-lang/perl"
+
+src_unpack() {
+ unpack ${A}
+ cd "${S}"
+ epatch "${FILESDIR}"/${P}-useorder.patch
+ epatch "${FILESDIR}"/${P}-source.patch
+}
+
+src_compile() {
+ ./configure || die "configure failed"
+ emake || die "make failed"
+}
+
+src_install() {
+ newsbin ufed.pl ufed
+ doman ufed.8
+ insinto /usr/lib/ufed
+ doins *.pm
+ exeinto /usr/lib/ufed
+ doexe ufed-curses
+}