summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndreas K. Hüttel <dilfridge@gentoo.org>2013-10-29 22:26:13 +0000
committerAndreas K. Hüttel <dilfridge@gentoo.org>2013-10-29 22:26:13 +0000
commit17e4f4ea81eda5f923f8d68fdfe5acd0a1a5e455 (patch)
tree1144eda4f8dad1e5718d78797e93b7032f475750 /dev-libs/icu
parentUpdate sed lines to respect CFLAGS and CC. (diff)
downloadgentoo-2-17e4f4ea81eda5f923f8d68fdfe5acd0a1a5e455.tar.gz
gentoo-2-17e4f4ea81eda5f923f8d68fdfe5acd0a1a5e455.tar.bz2
gentoo-2-17e4f4ea81eda5f923f8d68fdfe5acd0a1a5e455.zip
Add patched versions of both subslots for bug 486948
(Portage version: 2.2.7/cvs/Linux x86_64, signed Manifest commit with key EBE6A336BE19039C!)
Diffstat (limited to 'dev-libs/icu')
-rw-r--r--dev-libs/icu/ChangeLog9
-rw-r--r--dev-libs/icu/files/icu-51.1-CVE-2013-2924.patch36
-rw-r--r--dev-libs/icu/icu-51.1-r1.ebuild119
-rw-r--r--dev-libs/icu/icu-51.2-r1.ebuild117
4 files changed, 280 insertions, 1 deletions
diff --git a/dev-libs/icu/ChangeLog b/dev-libs/icu/ChangeLog
index d0d199be2d04..f76d4e97cd42 100644
--- a/dev-libs/icu/ChangeLog
+++ b/dev-libs/icu/ChangeLog
@@ -1,6 +1,13 @@
# ChangeLog for dev-libs/icu
# Copyright 1999-2013 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/dev-libs/icu/ChangeLog,v 1.247 2013/07/24 13:24:10 aballier Exp $
+# $Header: /var/cvsroot/gentoo-x86/dev-libs/icu/ChangeLog,v 1.248 2013/10/29 22:26:13 dilfridge Exp $
+
+*icu-51.2-r1 (29 Oct 2013)
+*icu-51.1-r1 (29 Oct 2013)
+
+ 29 Oct 2013; Andreas K. Huettel <dilfridge@gentoo.org> +icu-51.1-r1.ebuild,
+ +files/icu-51.1-CVE-2013-2924.patch, +icu-51.2-r1.ebuild:
+ Add patched versions of both subslots for bug 486948
24 Jul 2013; Alexis Ballier <aballier@gentoo.org> icu-51.2.ebuild:
Rekeyword x86-fbsd too...
diff --git a/dev-libs/icu/files/icu-51.1-CVE-2013-2924.patch b/dev-libs/icu/files/icu-51.1-CVE-2013-2924.patch
new file mode 100644
index 000000000000..65e734c7b3c1
--- /dev/null
+++ b/dev-libs/icu/files/icu-51.1-CVE-2013-2924.patch
@@ -0,0 +1,36 @@
+Index: /icu/trunk/source/i18n/csrucode.cpp
+===================================================================
+--- /icu/trunk/source/i18n/csrucode.cpp (revision 34075)
++++ /icu/trunk/source/i18n/csrucode.cpp (revision 34076)
+@@ -1,5 +1,5 @@
+ /*
+ **********************************************************************
+- * Copyright (C) 2005-2012, International Business Machines
++ * Copyright (C) 2005-2013, International Business Machines
+ * Corporation and others. All Rights Reserved.
+ **********************************************************************
+@@ -34,6 +34,7 @@
+ const uint8_t *input = textIn->fRawInput;
+ int32_t confidence = 0;
++ int32_t length = textIn->fRawLength;
+
+- if (input[0] == 0xFE && input[1] == 0xFF) {
++ if (length >=2 && input[0] == 0xFE && input[1] == 0xFF) {
+ confidence = 100;
+ }
+@@ -58,6 +59,7 @@
+ const uint8_t *input = textIn->fRawInput;
+ int32_t confidence = 0;
++ int32_t length = textIn->fRawLength;
+
+- if (input[0] == 0xFF && input[1] == 0xFE && (input[2] != 0x00 || input[3] != 0x00)) {
++ if (length >= 4 && input[0] == 0xFF && input[1] == 0xFE && (input[2] != 0x00 || input[3] != 0x00)) {
+ confidence = 100;
+ }
+@@ -82,5 +84,5 @@
+ int32_t confidence = 0;
+
+- if (getChar(input, 0) == 0x0000FEFFUL) {
++ if (limit > 0 && getChar(input, 0) == 0x0000FEFFUL) {
+ hasBOM = TRUE;
+ }
diff --git a/dev-libs/icu/icu-51.1-r1.ebuild b/dev-libs/icu/icu-51.1-r1.ebuild
new file mode 100644
index 000000000000..b28a80971e32
--- /dev/null
+++ b/dev-libs/icu/icu-51.1-r1.ebuild
@@ -0,0 +1,119 @@
+# Copyright 1999-2013 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/dev-libs/icu/icu-51.1-r1.ebuild,v 1.1 2013/10/29 22:26:13 dilfridge Exp $
+
+EAPI=5
+
+inherit eutils toolchain-funcs base autotools
+
+DESCRIPTION="International Components for Unicode"
+HOMEPAGE="http://www.icu-project.org/"
+SRC_URI="http://download.icu-project.org/files/icu4c/${PV/_/}/icu4c-${PV//./_}-src.tgz"
+
+LICENSE="BSD"
+SLOT="0/51.1"
+KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 -amd64-fbsd -x86-fbsd"
+IUSE="debug doc examples static-libs"
+
+DEPEND="
+ doc? (
+ app-doc/doxygen[dot]
+ )
+"
+
+S="${WORKDIR}/${PN}/source"
+
+PATCHES=(
+ "${FILESDIR}/${PN}-4.8.1-fix_binformat_fonts.patch"
+ "${FILESDIR}/${PN}-4.8.1.1-fix_ltr.patch"
+ "${FILESDIR}/${PN}-51.1-CVE-2013-2924.patch"
+)
+
+src_prepare() {
+ local variable
+
+ base_src_prepare
+
+ # Do not hardcode flags in icu-config and icu-*.pc files.
+ # https://ssl.icu-project.org/trac/ticket/6102
+ for variable in CFLAGS CPPFLAGS CXXFLAGS FFLAGS LDFLAGS; do
+ sed \
+ -e "/^${variable} =.*/s: *@${variable}@\( *$\)\?::" \
+ -i config/icu.pc.in \
+ -i config/Makefile.inc.in \
+ || die
+ done
+
+ # Disable renaming as it is stupind thing to do
+ sed -i \
+ -e "s/#define U_DISABLE_RENAMING 0/#define U_DISABLE_RENAMING 1/" \
+ common/unicode/uconfig.h || die
+
+ # Fix linking of icudata
+ sed -i \
+ -e "s:LDFLAGSICUDT=-nodefaultlibs -nostdlib:LDFLAGSICUDT=:" \
+ config/mh-linux || die
+
+ # Append doxygen configuration to configure
+ sed -i \
+ -e 's:icudefs.mk:icudefs.mk Doxyfile:' \
+ configure.in || die
+ eautoreconf
+}
+
+src_configure() {
+ local cross_opts
+
+ # bootstrap for cross compilation
+ if tc-is-cross-compiler; then
+ CFLAGS="" CXXFLAGS="" ASFLAGS="" LDFLAGS="" \
+ CC="$(tc-getBUILD_CC)" CXX="$(tc-getBUILD_CXX)" AR="$(tc-getBUILD_AR)" \
+ RANLIB="$(tc-getBUILD_RANLIB)" LD="$(tc-getBUILD_LD)" \
+ ./configure --disable-renaming --disable-debug \
+ --disable-samples --enable-static || die
+ emake
+ mkdir -p "${WORKDIR}/host/"
+ cp -a {bin,lib,config,tools} "${WORKDIR}/host/"
+ emake clean
+
+ cross_opts="--with-cross-build=${WORKDIR}/host"
+ fi
+
+ econf \
+ --disable-renaming \
+ $(use_enable debug) \
+ $(use_enable examples samples) \
+ $(use_enable static-libs static) \
+ ${cross_opts}
+}
+
+src_compile() {
+ default
+
+ if use doc; then
+ doxygen -u Doxyfile || die
+ doxygen Doxyfile || die
+ fi
+}
+
+src_test() {
+ # INTLTEST_OPTS: intltest options
+ # -e: Exhaustive testing
+ # -l: Reporting of memory leaks
+ # -v: Increased verbosity
+ # IOTEST_OPTS: iotest options
+ # -e: Exhaustive testing
+ # -v: Increased verbosity
+ # CINTLTST_OPTS: cintltst options
+ # -e: Exhaustive testing
+ # -v: Increased verbosity
+ emake -j1 VERBOSE="1" check
+}
+
+src_install() {
+ default
+
+ dohtml ../readme.html
+
+ use doc && dohtml -p api -r doc/html/
+}
diff --git a/dev-libs/icu/icu-51.2-r1.ebuild b/dev-libs/icu/icu-51.2-r1.ebuild
new file mode 100644
index 000000000000..2d8d9014b447
--- /dev/null
+++ b/dev-libs/icu/icu-51.2-r1.ebuild
@@ -0,0 +1,117 @@
+# Copyright 1999-2013 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/dev-libs/icu/icu-51.2-r1.ebuild,v 1.1 2013/10/29 22:26:13 dilfridge Exp $
+
+EAPI=5
+
+inherit eutils toolchain-funcs base autotools
+
+DESCRIPTION="International Components for Unicode"
+HOMEPAGE="http://www.icu-project.org/"
+SRC_URI="http://download.icu-project.org/files/icu4c/${PV/_/}/icu4c-${PV//./_}-src.tgz"
+
+LICENSE="BSD"
+SLOT="0/51.2"
+KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~x86-fbsd"
+IUSE="debug doc examples static-libs"
+
+DEPEND="
+ doc? (
+ app-doc/doxygen[dot]
+ )
+"
+
+S="${WORKDIR}/${PN}/source"
+
+PATCHES=(
+ "${FILESDIR}/${PN}-51.1-CVE-2013-2924.patch"
+)
+
+src_prepare() {
+ local variable
+
+ base_src_prepare
+
+ # Do not hardcode flags in icu-config and icu-*.pc files.
+ # https://ssl.icu-project.org/trac/ticket/6102
+ for variable in CFLAGS CPPFLAGS CXXFLAGS FFLAGS LDFLAGS; do
+ sed \
+ -e "/^${variable} =.*/s: *@${variable}@\( *$\)\?::" \
+ -i config/icu.pc.in \
+ -i config/Makefile.inc.in \
+ || die
+ done
+
+ # Disable renaming as it is stupind thing to do
+ sed -i \
+ -e "s/#define U_DISABLE_RENAMING 0/#define U_DISABLE_RENAMING 1/" \
+ common/unicode/uconfig.h || die
+
+ # Fix linking of icudata
+ sed -i \
+ -e "s:LDFLAGSICUDT=-nodefaultlibs -nostdlib:LDFLAGSICUDT=:" \
+ config/mh-linux || die
+
+ # Append doxygen configuration to configure
+ sed -i \
+ -e 's:icudefs.mk:icudefs.mk Doxyfile:' \
+ configure.in || die
+ eautoreconf
+}
+
+src_configure() {
+ local cross_opts
+
+ # bootstrap for cross compilation
+ if tc-is-cross-compiler; then
+ CFLAGS="" CXXFLAGS="" ASFLAGS="" LDFLAGS="" \
+ CC="$(tc-getBUILD_CC)" CXX="$(tc-getBUILD_CXX)" AR="$(tc-getBUILD_AR)" \
+ RANLIB="$(tc-getBUILD_RANLIB)" LD="$(tc-getBUILD_LD)" \
+ ./configure --disable-renaming --disable-debug \
+ --disable-samples --enable-static || die
+ emake
+ mkdir -p "${WORKDIR}/host/"
+ cp -a {bin,lib,config,tools} "${WORKDIR}/host/"
+ emake clean
+
+ cross_opts="--with-cross-build=${WORKDIR}/host"
+ fi
+
+ econf \
+ --disable-renaming \
+ $(use_enable debug) \
+ $(use_enable examples samples) \
+ $(use_enable static-libs static) \
+ ${cross_opts}
+}
+
+src_compile() {
+ default
+
+ if use doc; then
+ doxygen -u Doxyfile || die
+ doxygen Doxyfile || die
+ fi
+}
+
+src_test() {
+ # INTLTEST_OPTS: intltest options
+ # -e: Exhaustive testing
+ # -l: Reporting of memory leaks
+ # -v: Increased verbosity
+ # IOTEST_OPTS: iotest options
+ # -e: Exhaustive testing
+ # -v: Increased verbosity
+ # CINTLTST_OPTS: cintltst options
+ # -e: Exhaustive testing
+ # -v: Increased verbosity
+ emake -j1 VERBOSE="1" check
+}
+
+src_install() {
+ default
+
+ dohtml ../readme.html
+
+ use doc && dohtml -p api -r doc/html/
+}