summaryrefslogtreecommitdiff
path: root/media-libs/ming
diff options
context:
space:
mode:
Diffstat (limited to 'media-libs/ming')
-rw-r--r--media-libs/ming/Manifest8
-rw-r--r--media-libs/ming/files/ming-0.4.8-CVE-2017-8782.patch28
-rw-r--r--media-libs/ming/metadata.xml12
-rw-r--r--media-libs/ming/ming-0.4.7.ebuild94
-rw-r--r--media-libs/ming/ming-0.4.8-r1.ebuild96
5 files changed, 238 insertions, 0 deletions
diff --git a/media-libs/ming/Manifest b/media-libs/ming/Manifest
new file mode 100644
index 000000000000..eb2a714fe3a7
--- /dev/null
+++ b/media-libs/ming/Manifest
@@ -0,0 +1,8 @@
+AUX ming-0.4.8-CVE-2017-8782.patch 772 SHA256 05855ed7b619a6ba60416b070d356eaab93b65371b49033f4d9ef18f0b19b566 SHA512 69a445d41856e4a567c253d5a0a1f63128ad8f71d8c418da855d62e2f1ff13e2a19a6887a22cfdaa8682811695b79b3bc736b569756f88e8472d294d89561005 WHIRLPOOL c10d538d11bd1aa4b7d5f2cbf29856934ddae18bbd97962480b9fefb43f0e7297edfc0e1b1fadff77ce5529d9b813be15044ec079cd08716c7fcd0c7801f07d1
+DIST ming-0_4_7.tar.gz 14903570 SHA256 118aa1338dd74b34dd2cd22bce286ca0571e8b9aa433999646d1c0157ea9a7dc SHA512 232cf45daabd7b60203c9382aa6568455a42ddcd1bd60eec9bfe3f5e80376fcc9ff6304efbafca1ac8a504e2e167bc394e4902e0d067303d9582551461e09d3c WHIRLPOOL 075794f170e7f529ba79a66af4504745da786d7cd73e9673ffd4c48e943fbc8bf1f952f1cc0b0b7b0ca1e26a3bdb255feeaaeb675032616d2060c40f19d4dbdd
+DIST ming-0_4_8.tar.gz 14908459 SHA256 2a44cc8b7f6506adaa990027397b6e0f60ba0e3c1fe8c9514be5eb8e22b2375c SHA512 e395acde9119ad32f4cedd500bcceee70bdd563222a41dda899cc318d5e34eb580abc38ac39c6dec7821913a0a70d2f953fc81f52255b623e34f7c3aaafbc9c0 WHIRLPOOL 4c82d80310f559aaddcebc25208b5947bdea5f4d0d40ece59b39fad2cc087c13140915cf6bd44a5af894737ef61807b4a3f1affb323732dc2cd8b948a7f03dcb
+EBUILD ming-0.4.7.ebuild 2119 SHA256 efbabe8de0db75a6688ddce3b35253e408d18339e6434028d9c01147b7681d1e SHA512 9f4652a5c63ffb44cd87ec8c6536ed53666074e72af8bb1e15cbf8329667d23c7333e177428eb37aab6d7baa99cb107955da847604212fc8b76243dda42afd26 WHIRLPOOL 41d1731c8811ae2d1f157f16ff8bc04b7651c8deaca1bea4c1501aa3bf060859191915ad49ce776690099ccc878b771bd1c81832c677299fec7896dedbca37a7
+EBUILD ming-0.4.8-r1.ebuild 2185 SHA256 3c95d8b923cb8710c8056d49a5ad6d1cb558a4f70a40873edc5f6fd27faa84f1 SHA512 701d0be12876a3d143960f6478d499f7cc2d9906f18675a1aef51b983f0ed40d5a0c153b612f630d8c7477f397e246c07e12a083f08b9eb87ff976852e196ae6 WHIRLPOOL 53ca6a306e62ebc5f793b7140bb8fc767324f2fdd978e8f1c03644694127bbc1efb164e4e7d13d295bb8f6c76a7c56570016db381405db67810e72b326ba0a60
+MISC ChangeLog 3694 SHA256 8bf06d761b6c67aab0d4b2b70a76caa5e40867e1cc54fe0d7469f9bb83136cd3 SHA512 46c1f82f22b94f2f7601357f4c66f136c0acf4007d6a3f985edfd5ce3515b10abd5d7eed2423f7388c1f25a6d1ceabbe2907c57adcbdffb0ede2a2cacb83091a WHIRLPOOL 2193bbdbe3debc9c728abe97395c095147785a1ab43b81fb37edddfa56369dc3d6047b33ff5e9c3676167e12c5d59e9e8d97dfd415f5e33bb7ad4203beb0df29
+MISC ChangeLog-2015 15257 SHA256 aaf7a4534f28702d6e324af1818899a2e00ccc573fff4ff0985723174a0666be SHA512 07f676493f66bc9bdac5de2005e23db8d711669ee3c2ee7cc3be4ac98ddfe2cc97e06eb6543764196add41e1ca6a501ce08d7634bea499486ed7b436c78c388d WHIRLPOOL 73c7a3272e237758905931b5ae2d26e6c9380d0f9ab9679aab30b02edef5bdf3b9d737ec4196e9f1ebb47131c66e9f32895c134b53371b337bd8190af893fc52
+MISC metadata.xml 388 SHA256 e1617f5782a85c801c4aead51362c8f6429ffea4f131e829b6d292babd0e1bf7 SHA512 0efbb0ad1eadfd764bdf6e182cf8865994ca8e96ccc6e14845829638730e1ce6ff7ac2777e9ad3d396e7e29d77e034b818c95259eb8aab53a23b3c0815f787d0 WHIRLPOOL c7db75b4374f9c27246b13a9c8c83af92d0e372fd8fd014bf2943d299a84766b9810c9742f271a126c0bea336b1ac9be9ff0a77444a4bba7886d4b25d46fae05
diff --git a/media-libs/ming/files/ming-0.4.8-CVE-2017-8782.patch b/media-libs/ming/files/ming-0.4.8-CVE-2017-8782.patch
new file mode 100644
index 000000000000..223d363ae0b0
--- /dev/null
+++ b/media-libs/ming/files/ming-0.4.8-CVE-2017-8782.patch
@@ -0,0 +1,28 @@
+https://github.com/libming/libming/commit/6eca133ee9985c298186cbe05f888082c30bf2d9
+
+--- a/util/read.c
++++ b/util/read.c
+@@ -247,6 +247,11 @@ char *readString(FILE *f)
+ if(len >= buflen-2)
+ {
+ buf = (char *)realloc(buf, sizeof(char)*(buflen+256));
++ if ( ! buf )
++ {
++ fprintf(stderr, "failed reallocating %d bytes\n", buflen+256);
++ exit(-1);
++ }
+ buflen += 256;
+ p = buf+len;
+ }
+@@ -350,6 +355,11 @@ char *readSizedString(FILE *f,int size)
+ if(len >= buflen-2)
+ {
+ buf = (char *)realloc(buf, sizeof(char)*(buflen+256));
++ if ( ! buf )
++ {
++ fprintf(stderr, "failed reallocating %d bytes\n", buflen+256);
++ exit(-1);
++ }
+ buflen += 256;
+ p = buf+len;
+ }
diff --git a/media-libs/ming/metadata.xml b/media-libs/ming/metadata.xml
new file mode 100644
index 000000000000..e85491fe7d63
--- /dev/null
+++ b/media-libs/ming/metadata.xml
@@ -0,0 +1,12 @@
+<?xml version='1.0' encoding='UTF-8'?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer type="project">
+ <email>graphics@gentoo.org</email>
+ <name>Gentoo Graphics Project</name>
+ </maintainer>
+ <upstream>
+ <remote-id type="sourceforge">ming</remote-id>
+ <remote-id type="github">libming/libming</remote-id>
+ </upstream>
+</pkgmetadata>
diff --git a/media-libs/ming/ming-0.4.7.ebuild b/media-libs/ming/ming-0.4.7.ebuild
new file mode 100644
index 000000000000..5d5b23fa2fa6
--- /dev/null
+++ b/media-libs/ming/ming-0.4.7.ebuild
@@ -0,0 +1,94 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+
+PYTHON_COMPAT=( python2_7 )
+PHP_EXT_NAME=ming
+PHP_EXT_OPTIONAL_USE=php
+AUTOTOOLS_AUTORECONF=yes
+GENTOO_DEPEND_ON_PERL=no
+inherit autotools distutils-r1 flag-o-matic multilib perl-module vcs-snapshot
+
+DESCRIPTION="An Open Source library for Flash movie generation"
+HOMEPAGE="http://ming.sourceforge.net/"
+SRC_URI="https://github.com/libming/libming/archive/${P//./_}.tar.gz"
+
+LICENSE="LGPL-2.1"
+SLOT="0"
+KEYWORDS="alpha amd64 arm hppa ia64 ~mips ppc ppc64 ~s390 ~sh sparc x86 ~amd64-fbsd ~x86-fbsd"
+IUSE="+perl php +python static-libs"
+
+RDEPEND="perl? ( dev-lang/perl:= )
+ python? ( ${PYTHON_DEPS} )
+ media-libs/freetype:=
+ media-libs/libpng:0=
+ media-libs/giflib:=
+ sys-libs/zlib:=
+ !media-libs/libswf"
+DEPEND="${RDEPEND}
+ sys-devel/flex
+ virtual/yacc"
+PDEPEND="php? ( dev-php/ming-php )"
+
+REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )"
+S=${WORKDIR}/${P//./_}
+
+# Tests only work when the package is tested on a system
+# which does not presently have any version of ming installed.
+RESTRICT="test"
+
+src_prepare() {
+ default
+
+ # Let's get rid of the TEXTRELS, link dynamic. Use gif.
+ sed -i \
+ -e 's/libming.a/libming.so/' \
+ -e 's/lungif/lgif/' \
+ perl_ext/Makefile.PL
+
+ sed -i -e 's:AM_CONFIG_HEADER:AC_CONFIG_HEADERS:' configure.in || die
+
+ eautoreconf
+}
+
+src_configure() {
+ # build is sensitive to -O3 (bug #297437)
+ replace-flags -O3 -O2
+
+ # build python via distutils calls, disable here
+ # php is done in dev-php/ming-php
+ local myconf=(
+ --disable-python
+ --disable-php
+ $(use_enable static-libs static)
+ $(use_enable perl)
+ )
+ econf "${myconf[@]}"
+}
+
+run_distutils() {
+ if use python; then
+ pushd py_ext > /dev/null || die
+ distutils-r1_"${@}"
+ popd > /dev/null || die
+ fi
+}
+
+src_compile() {
+ # some parallel make issues on flex/bison
+ emake -C src/actioncompiler -j1
+ emake
+
+ run_distutils ${FUNCNAME}
+}
+
+src_install() {
+ run_distutils ${FUNCNAME}
+
+ emake DESTDIR="${D}" INSTALLDIRS="vendor" install
+ einstalldocs
+
+ perl_delete_localpod
+ find "${ED}"usr/lib* -name '*.la' -delete
+}
diff --git a/media-libs/ming/ming-0.4.8-r1.ebuild b/media-libs/ming/ming-0.4.8-r1.ebuild
new file mode 100644
index 000000000000..8015aff99bfa
--- /dev/null
+++ b/media-libs/ming/ming-0.4.8-r1.ebuild
@@ -0,0 +1,96 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+
+PYTHON_COMPAT=( python2_7 )
+PHP_EXT_NAME=ming
+PHP_EXT_OPTIONAL_USE=php
+AUTOTOOLS_AUTORECONF=yes
+GENTOO_DEPEND_ON_PERL=no
+inherit autotools distutils-r1 flag-o-matic multilib perl-module vcs-snapshot
+
+DESCRIPTION="An Open Source library for Flash movie generation"
+HOMEPAGE="http://ming.sourceforge.net/"
+SRC_URI="https://github.com/libming/libming/archive/${P//./_}.tar.gz"
+
+LICENSE="LGPL-2.1"
+SLOT="0"
+KEYWORDS="alpha amd64 arm ~arm64 hppa ia64 ~mips ppc ppc64 ~s390 ~sh sparc x86 ~amd64-fbsd ~x86-fbsd"
+IUSE="+perl php +python static-libs"
+
+RDEPEND="perl? ( dev-lang/perl:= )
+ python? ( ${PYTHON_DEPS} )
+ media-libs/freetype:=
+ media-libs/libpng:0=
+ media-libs/giflib:=
+ sys-libs/zlib:=
+ !media-libs/libswf"
+DEPEND="${RDEPEND}
+ sys-devel/flex
+ virtual/yacc"
+PDEPEND="php? ( dev-php/ming-php )"
+
+REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )"
+S=${WORKDIR}/${P//./_}
+
+PATCHES=( "${FILESDIR}"/${PN}-0.4.8-CVE-2017-8782.patch )
+
+# Tests only work when the package is tested on a system
+# which does not presently have any version of ming installed.
+RESTRICT="test"
+
+src_prepare() {
+ default
+
+ # Let's get rid of the TEXTRELS, link dynamic. Use gif.
+ sed -i \
+ -e 's/libming.a/libming.so/' \
+ -e 's/lungif/lgif/' \
+ perl_ext/Makefile.PL
+
+ sed -i -e 's:AM_CONFIG_HEADER:AC_CONFIG_HEADERS:' configure.in || die
+
+ eautoreconf
+}
+
+src_configure() {
+ # build is sensitive to -O3 (bug #297437)
+ replace-flags -O3 -O2
+
+ # build python via distutils calls, disable here
+ # php is done in dev-php/ming-php
+ local myconf=(
+ --disable-python
+ --disable-php
+ $(use_enable static-libs static)
+ $(use_enable perl)
+ )
+ econf "${myconf[@]}"
+}
+
+run_distutils() {
+ if use python; then
+ pushd py_ext > /dev/null || die
+ distutils-r1_"${@}"
+ popd > /dev/null || die
+ fi
+}
+
+src_compile() {
+ # some parallel make issues on flex/bison
+ emake -C src/actioncompiler -j1
+ emake
+
+ run_distutils ${FUNCNAME}
+}
+
+src_install() {
+ run_distutils ${FUNCNAME}
+
+ emake DESTDIR="${D}" INSTALLDIRS="vendor" install
+ einstalldocs
+
+ perl_delete_localpod
+ find "${ED}"usr/lib* -name '*.la' -delete
+}