summaryrefslogtreecommitdiff
path: root/media-libs/aldumb
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2017-10-09 18:53:29 +0100
committerV3n3RiX <venerix@redcorelinux.org>2017-10-09 18:53:29 +0100
commit4f2d7949f03e1c198bc888f2d05f421d35c57e21 (patch)
treeba5f07bf3f9d22d82e54a462313f5d244036c768 /media-libs/aldumb
reinit the tree, so we can have metadata
Diffstat (limited to 'media-libs/aldumb')
-rw-r--r--media-libs/aldumb/Manifest7
-rw-r--r--media-libs/aldumb/aldumb-0.9.3.ebuild47
-rw-r--r--media-libs/aldumb/files/aldumb-0.9.3-PIC-as-needed.patch72
-rw-r--r--media-libs/aldumb/files/aldumb-0.9.3_CVE-2006-3668.patch16
-rw-r--r--media-libs/aldumb/metadata.xml11
5 files changed, 153 insertions, 0 deletions
diff --git a/media-libs/aldumb/Manifest b/media-libs/aldumb/Manifest
new file mode 100644
index 000000000000..766824d96afa
--- /dev/null
+++ b/media-libs/aldumb/Manifest
@@ -0,0 +1,7 @@
+AUX aldumb-0.9.3-PIC-as-needed.patch 2730 SHA256 483baf39a2540ca06051e91b7c629b7ada76e0b137fc00c673624c0681be28da SHA512 b97bfdedfe4f64cc37ca52e50d0ac919747dd523f686350d8681a7629508f83ae87220622f9d431132aeb149dc6011e1461ac560ccece20a4dfb6a7d2ec9d962 WHIRLPOOL f13e4bd72c9c1a44c12d0c4e7578c5d3f439ef8e9a797351c78265b5ae2d034b53156030fb570888c435135f22535d875f1267eade73c215a519445772966416
+AUX aldumb-0.9.3_CVE-2006-3668.patch 637 SHA256 9f6785435757db725bc73b1c4874b91e80b9277c6fdd2b56e47dae1cfbc968e6 SHA512 ecce27757b27d997fffcc8b5736c1921a947664e2a73a4fc9ff269d8d24524fe3823a9076a3270b4296d6294102c0c7f5d2fc5c05152878dcaa11d6acede2125 WHIRLPOOL d59963d4634b3601e30c6a00fb722949e638559c1e8ec8c3d51ae74a77af759413ec5d21a769cc06b624a7e4c51626cfc1f548fdefd3ccaf253af8412552056d
+DIST dumb-0.9.3.tar.gz 167379 SHA256 8d44fbc9e57f3bac9f761c3b12ce102d47d717f0dd846657fb988e0bb5d1ea33 SHA512 9ecdea460858b7e6ad7ca2534ecb3581397e6c1fa904459affe19ce49f528e580e143b42b13413b292ae7b57901a8008e6a9ee3821824f6ff7914b136f75c658 WHIRLPOOL c5139d6d845245fc60a9984064b5bf9b0cb54e0499ddd55db56ca5faa31ebc6158b486b70409dc6068c8261330e9200c84c278e19c9fa16bf32b67c403f44e9b
+EBUILD aldumb-0.9.3.ebuild 1030 SHA256 30a1c7031fe7b03557d7ec11b5ef90df5d22b6870045b86bbb047d2dc519269e SHA512 e5afa5a8c2a3d33918b3717ac757ceb32f4bf7c0617dbd8a1a2f4bb1dc077887b784a12f0a93d9f8bf8ef78f4ad65d1c5d95be084ddc57998d0284649a1ea6b6 WHIRLPOOL 03082ed2e8fc98c4506a5a5f9da3033cd192c6f89d661e483a67c1f568cbc950a23731ab6a9e3ac7690a8b3c68b5a094f59560618720da34e40582b90ee09a45
+MISC ChangeLog 2510 SHA256 a25307fafc526129739d70ed9d3cd857e2a710176e3d0f8e0457cb1bb2606801 SHA512 2e0fb75c4633ed40f2df5d57459cc8a09abf666dbec3e3515815a77f969d778920d48310459f0c1b1120f2d230aa2f18ce047c6b40f484aaecbfe8d4bc1a4a71 WHIRLPOOL d5e61409121e795ee37c6334467577bcda69ac5f89cb915bdb004f0777088d048316dc35e5716c175a38956ec38501f76f53327af64f55f398a0bc80c28e8fc4
+MISC ChangeLog-2015 3320 SHA256 514bec69d924a6d391fc993714b19787e208e101b8c07dfbb321293dc3ac269a SHA512 10ce06f026748d65804b0370ecb73672557e9bb2b9da864aaa5fc4b61e451d02f4d463d6733d7a1d8f8d237a8ba12bcb6b5615c0c4efda41f95a423b5d0732b8 WHIRLPOOL b36d24a12d403391cc3ce3608818d06b8e0cf6ac26acac3842a0270995127952426ed34cbab85432cdf05c289471dba348b24b3696a5c7a323e217006f138779
+MISC metadata.xml 327 SHA256 dec9608122868a77678970c42c37153bc78ade535c7066b7a326c9c72b95ead1 SHA512 e82c8c18d0744758b19a533b606aee382cdf2cbc36f431c3ed286704d75b759e663f2c3aaa2259c7a62352f4d73587ad34aff26a47ae06e20ab7372aa5a8c82c WHIRLPOOL d88f55d711a3c35fddb880356143d06d06d39b81daed62586a7b50619278040abcf597e3b55be31b2c56e59480f0842718cf6500ce77c42784f8b0039458ccb7
diff --git a/media-libs/aldumb/aldumb-0.9.3.ebuild b/media-libs/aldumb/aldumb-0.9.3.ebuild
new file mode 100644
index 000000000000..b6fd72d59ff7
--- /dev/null
+++ b/media-libs/aldumb/aldumb-0.9.3.ebuild
@@ -0,0 +1,47 @@
+# Copyright 1999-2011 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=2
+inherit eutils
+
+DESCRIPTION="Allegro support for DUMB (an IT, XM, S3M, and MOD player library)"
+HOMEPAGE="http://dumb.sourceforge.net/"
+SRC_URI="mirror://sourceforge/dumb/dumb-${PV}.tar.gz"
+
+LICENSE="DUMB-0.9.2"
+SLOT="0"
+KEYWORDS="amd64 ppc x86"
+IUSE="debug"
+
+DEPEND=">=media-libs/dumb-0.9.3
+ <media-libs/allegro-5"
+
+RDEPEND="${DEPEND}"
+
+S="${WORKDIR}/${P/aldumb/dumb}"
+
+src_prepare() {
+ cat << EOF > make/config.txt
+include make/unix.inc
+ALL_TARGETS := allegro allegro-examples allegro-headers
+PREFIX := /usr
+EOF
+ epatch "${FILESDIR}"/${P}-PIC-as-needed.patch
+ epatch "${FILESDIR}"/${P}_CVE-2006-3668.patch
+ sed -i '/= -s/d' Makefile || die "sed failed"
+ cp -f Makefile Makefile.rdy
+}
+
+src_compile() {
+ emake OFLAGS="${CFLAGS}" all || die "emake failed"
+}
+
+src_install() {
+ dobin examples/dumbplay
+ dolib.so lib/unix/libaldmb.so
+
+ use debug && lib/unix/libaldmd.so
+
+ insinto /usr/include
+ doins include/aldumb.h
+}
diff --git a/media-libs/aldumb/files/aldumb-0.9.3-PIC-as-needed.patch b/media-libs/aldumb/files/aldumb-0.9.3-PIC-as-needed.patch
new file mode 100644
index 000000000000..217caa406b3e
--- /dev/null
+++ b/media-libs/aldumb/files/aldumb-0.9.3-PIC-as-needed.patch
@@ -0,0 +1,72 @@
+diff -Naur dumb.orig/Makefile dumb/Makefile
+--- dumb.orig/Makefile 2003-04-03 16:34:18.000000000 -0800
++++ dumb/Makefile 2004-07-06 14:43:38.158063165 -0700
+@@ -199,11 +199,11 @@
+ ALLEGRO_EXAMPLES_EXE := $(addprefix examples/, $(notdir $(patsubst %.c, %$(EXE_SUFFIX), $(ALLEGRO_EXAMPLES))))
+
+
+-CORE_LIB_FILE_RELEASE := $(LIBDIR)/libdumb.a
+-ALLEGRO_LIB_FILE_RELEASE := $(LIBDIR)/libaldmb.a
++CORE_LIB_FILE_RELEASE := $(LIBDIR)/libdumb.so
++ALLEGRO_LIB_FILE_RELEASE := $(LIBDIR)/libaldmb.so
+
+-CORE_LIB_FILE_DEBUG := $(LIBDIR)/libdumbd.a
+-ALLEGRO_LIB_FILE_DEBUG := $(LIBDIR)/libaldmd.a
++CORE_LIB_FILE_DEBUG := $(LIBDIR)/libdumbd.so
++ALLEGRO_LIB_FILE_DEBUG := $(LIBDIR)/libaldmd.so
+
+
+ core: $(CORE_LIB_FILE_RELEASE) $(CORE_LIB_FILE_DEBUG)
+@@ -272,22 +272,22 @@
+
+ OBJDIR := $(OBJDIR_BASE)/release
+ CFLAGS := $(CFLAGS_RELEASE)
+-CORE_LIB_FILE := $(LIBDIR)/libdumb.a
+-ALLEGRO_LIB_FILE := $(LIBDIR)/libaldmb.a
++CORE_LIB_FILE := $(LIBDIR)/libdumb.so
++ALLEGRO_LIB_FILE := $(LIBDIR)/libaldmb.so
+ include make/Makefile.inc
+
+ OBJDIR := $(OBJDIR_BASE)/debug
+ CFLAGS := $(CFLAGS_DEBUG)
+-CORE_LIB_FILE := $(LIBDIR)/libdumbd.a
+-ALLEGRO_LIB_FILE := $(LIBDIR)/libaldmd.a
++CORE_LIB_FILE := $(LIBDIR)/libdumbd.so
++ALLEGRO_LIB_FILE := $(LIBDIR)/libaldmd.so
+ include make/Makefile.inc
+
+
+ $(CORE_EXAMPLES_EXE): examples/%$(EXE_SUFFIX): examples/%.o $(CORE_LIB_FILE_RELEASE)
+- $(CC) $^ -o $@ $(LDFLAGS) $(LINK_MATH)
++ $(CC) $^ -o $@ $(LDFLAGS) $(LINK_MATH)
+
+ $(ALLEGRO_EXAMPLES_EXE): examples/%$(EXE_SUFFIX): examples/%.o $(ALLEGRO_LIB_FILE_RELEASE) $(CORE_LIB_FILE_RELEASE)
+- $(CC) $^ -o $@ $(LDFLAGS) $(LINK_ALLEGRO)
++ $(CC) $^ -o $@ $(LDFLAGS) $(LINK_ALLEGRO)
+
+ $(CORE_EXAMPLES_OBJ): examples/%.o: examples/%.c include/dumb.h
+ $(CC) -c $< -o $@ $(CFLAGS_RELEASE)
+diff -Naur dumb.orig/make/Makefile.inc dumb/make/Makefile.inc
+--- dumb.orig/make/Makefile.inc 2003-04-03 16:34:18.000000000 -0800
++++ dumb/make/Makefile.inc 2004-07-06 14:37:13.082037585 -0700
+@@ -10,8 +10,8 @@
+ # accurately, create a local copy of the current CFLAGS variable. This is
+ # necessary because Make doesn't expand variables in commands until they are
+ # executed.
+-$(CORE_LIB_FILE): CFLAGS := $(CFLAGS)
+-$(ALLEGRO_LIB_FILE): CFLAGS := $(CFLAGS)
++$(CORE_LIB_FILE): CFLAGS := $(CFLAGS) -fPIC -DPIC
++$(ALLEGRO_LIB_FILE): CFLAGS := $(CFLAGS) -fPIC -DPIC
+
+
+ $(OBJDIR)/%.o: src/core/%.c include/dumb.h include/internal/dumb.h
+@@ -28,7 +28,7 @@
+ $(CC) -c -o $@ $< $(CFLAGS) $(WFLAGS_ALLEGRO)
+
+ $(CORE_LIB_FILE): $(CORE_OBJECTS)
+- $(AR) rs $@ $^
++ $(CC) -shared -o $@ $(LDFLAGS) -Wl,-shared,-soname,$(shell basename $@) $^ -lm
+
+ $(ALLEGRO_LIB_FILE): $(ALLEGRO_OBJECTS)
+- $(AR) rs $@ $^
++ $(CC) -shared -o $@ $(LDFLAGS) -Wl,-shared,-soname,$(shell basename $@) $^ -ldumb
diff --git a/media-libs/aldumb/files/aldumb-0.9.3_CVE-2006-3668.patch b/media-libs/aldumb/files/aldumb-0.9.3_CVE-2006-3668.patch
new file mode 100644
index 000000000000..09d2fb68f4cb
--- /dev/null
+++ b/media-libs/aldumb/files/aldumb-0.9.3_CVE-2006-3668.patch
@@ -0,0 +1,16 @@
+Index: libdumb-0.9.3/src/it/itread.c
+===================================================================
+--- libdumb-0.9.3.orig/src/it/itread.c 2006-07-21 11:05:48.000000000 +0200
++++ libdumb-0.9.3/src/it/itread.c 2006-07-21 11:07:22.000000000 +0200
+@@ -292,6 +292,11 @@
+
+ envelope->flags = dumbfile_getc(f);
+ envelope->n_nodes = dumbfile_getc(f);
++ if(envelope->n_nodes > 25) {
++ TRACE("IT error: wrong number of envelope nodes (%d)\n", envelope->n_nodes);
++ envelope->n_nodes = 0;
++ return -1;
++ }
+ envelope->loop_start = dumbfile_getc(f);
+ envelope->loop_end = dumbfile_getc(f);
+ envelope->sus_loop_start = dumbfile_getc(f);
diff --git a/media-libs/aldumb/metadata.xml b/media-libs/aldumb/metadata.xml
new file mode 100644
index 000000000000..18f5db992196
--- /dev/null
+++ b/media-libs/aldumb/metadata.xml
@@ -0,0 +1,11 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer type="project">
+ <email>sound@gentoo.org</email>
+ <name>Gentoo Sound project</name>
+ </maintainer>
+ <upstream>
+ <remote-id type="sourceforge">dumb</remote-id>
+ </upstream>
+</pkgmetadata>