diff --git a/sdk_container/src/third_party/portage-stable/metadata/md5-cache/sys-apps/sed-4.2.1 b/sdk_container/src/third_party/portage-stable/metadata/md5-cache/sys-apps/sed-4.2.1-r1 similarity index 73% rename from sdk_container/src/third_party/portage-stable/metadata/md5-cache/sys-apps/sed-4.2.1 rename to sdk_container/src/third_party/portage-stable/metadata/md5-cache/sys-apps/sed-4.2.1-r1 index 9df7f0fd5f..83fa453b64 100644 --- a/sdk_container/src/third_party/portage-stable/metadata/md5-cache/sys-apps/sed-4.2.1 +++ b/sdk_container/src/third_party/portage-stable/metadata/md5-cache/sys-apps/sed-4.2.1-r1 @@ -1,12 +1,12 @@ DEFINED_PHASES=compile install unpack -DEPEND=nls? ( virtual/libintl ) acl? ( virtual/acl ) nls? ( sys-devel/gettext ) +DEPEND=acl? ( virtual/acl ) nls? ( virtual/libintl ) nls? ( sys-devel/gettext ) DESCRIPTION=Super-useful stream editor HOMEPAGE=http://sed.sourceforge.net/ IUSE=acl nls selinux static -KEYWORDS=alpha amd64 arm hppa ia64 m68k ~mips ppc ppc64 s390 sh sparc x86 ~sparc-fbsd ~x86-fbsd +KEYWORDS=alpha amd64 arm hppa ia64 m68k ~mips ppc ppc64 s390 sh sparc x86 ~amd64-fbsd ~sparc-fbsd ~x86-fbsd LICENSE=GPL-3 -RDEPEND=nls? ( virtual/libintl ) acl? ( virtual/acl ) +RDEPEND=acl? ( virtual/acl ) nls? ( virtual/libintl ) SLOT=0 SRC_URI=mirror://gnu/sed/sed-4.2.1.tar.bz2 _eclasses_=eutils 33ef77a15337022e05342d2c772a7a5a flag-o-matic 01a8b1eb019305bc4b4a8bd0b04e4cd8 multilib 5f4ad6cf85e365e8f0c6050ddd21659e portability 0be430f759a631e692678ed796e09f5c toolchain-funcs 6526ac6fc9aedf391efb91fcd75ace68 user 9e552f935106ff0bc92af16da64b4b29 -_md5_=5e15ed8f07422e4e07e2c325de10bfb0 +_md5_=fdaf151e6272cb4d81e4a56ea0ec50dc diff --git a/sdk_container/src/third_party/portage-stable/sys-apps/sed/files/sed-4.2.1-handle-incomplete-sequences-as-if-they-were-invalid.patch b/sdk_container/src/third_party/portage-stable/sys-apps/sed/files/sed-4.2.1-handle-incomplete-sequences-as-if-they-were-invalid.patch new file mode 100644 index 0000000000..dfd9206d3b --- /dev/null +++ b/sdk_container/src/third_party/portage-stable/sys-apps/sed/files/sed-4.2.1-handle-incomplete-sequences-as-if-they-were-invalid.patch @@ -0,0 +1,45 @@ +http://bugs.gentoo.org/284403 + +From 20f68fb1abe862a98bc0378e5bb54d94bb98b8fe Mon Sep 17 00:00:00 2001 +From: Paolo Bonzini +Date: Thu, 15 Oct 2009 19:56:12 +0200 +Subject: [PATCH] handle incomplete sequences as if they were invalid + +2009-10-15 Paolo Bonzini + WANG Yunfeng + + * sed/execute.c (str_append, str_append_modified): Handle incomplete + sequences as if they were invalid. +--- + ChangeLog | 6 ++++++ + NEWS | 4 +++- + sed/execute.c | 6 +++--- + 3 files changed, 12 insertions(+), 4 deletions(-) + +diff --git a/sed/execute.c b/sed/execute.c +index 66cb809..d5903be 100644 +--- a/sed/execute.c ++++ b/sed/execute.c +@@ -254,8 +254,8 @@ str_append(to, string, length) + { + size_t n = MBRLEN (string, length, &to->mbstate); + +- /* An invalid sequence is treated like a singlebyte character. */ +- if (n == (size_t) -1) ++ /* An invalid or imcomplete sequence is treated like a singlebyte character. */ ++ if (n == (size_t) -1 || n == (size_t) -2) + { + memset (&to->mbstate, 0, sizeof (to->mbstate)); + n = 1; +@@ -341,7 +341,7 @@ str_append_modified(to, string, length, type) + /* Copy the new wide character to the end of the string. */ + n = WCRTOMB (to->active + to->length, wc, &to->mbstate); + to->length += n; +- if (n == -1) ++ if (n == -1 || n == -2) + { + fprintf (stderr, "Case conversion produced an invalid character!"); + abort (); +-- +1.7.3.1 + diff --git a/sdk_container/src/third_party/portage-stable/sys-apps/sed/sed-4.2.1.ebuild b/sdk_container/src/third_party/portage-stable/sys-apps/sed/sed-4.2.1-r1.ebuild similarity index 76% rename from sdk_container/src/third_party/portage-stable/sys-apps/sed/sed-4.2.1.ebuild rename to sdk_container/src/third_party/portage-stable/sys-apps/sed/sed-4.2.1-r1.ebuild index 514e229dae..cffb0a89eb 100644 --- a/sdk_container/src/third_party/portage-stable/sys-apps/sed/sed-4.2.1.ebuild +++ b/sdk_container/src/third_party/portage-stable/sys-apps/sed/sed-4.2.1-r1.ebuild @@ -1,6 +1,6 @@ -# Copyright 1999-2010 Gentoo Foundation +# Copyright 1999-2012 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/sys-apps/sed/sed-4.2.1.ebuild,v 1.9 2010/11/28 17:21:42 ranger Exp $ +# $Header: /var/cvsroot/gentoo-x86/sys-apps/sed/sed-4.2.1-r1.ebuild,v 1.12 2012/08/26 17:00:34 armin76 Exp $ inherit eutils flag-o-matic toolchain-funcs @@ -10,11 +10,11 @@ SRC_URI="mirror://gnu/sed/${P}.tar.bz2" LICENSE="GPL-3" SLOT="0" -KEYWORDS="alpha amd64 arm hppa ia64 m68k ~mips ppc ppc64 s390 sh sparc x86 ~sparc-fbsd ~x86-fbsd" +KEYWORDS="alpha amd64 arm hppa ia64 m68k ~mips ppc ppc64 s390 sh sparc x86 ~amd64-fbsd ~sparc-fbsd ~x86-fbsd" IUSE="acl nls selinux static" -RDEPEND="nls? ( virtual/libintl ) - acl? ( virtual/acl )" +RDEPEND="acl? ( virtual/acl ) + nls? ( virtual/libintl )" DEPEND="${RDEPEND} nls? ( sys-devel/gettext )" @@ -34,6 +34,7 @@ src_unpack() { unpack ${A} cd "${S}" epatch "${FILESDIR}"/${PN}-4.1.5-alloca.patch + epatch "${FILESDIR}"/${P}-handle-incomplete-sequences-as-if-they-were-invalid.patch #284403 # don't use sed here if we have to recover a broken host sed } @@ -50,7 +51,8 @@ src_compile() { bindir=/usr/bin fi - use selinux || export ac_cv_{search_setfilecon,header_selinux_{context,selinux}_h}=no + export ac_cv_search_setfilecon=$(usex selinux -lselinux) + export ac_cv_header_selinux_{context,selinux}_h=$(usex selinux) use static && append-ldflags -static econf \ --bindir=${bindir} \