summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndreas Sturmlechner <asturm@gentoo.org>2019-02-09 20:55:19 +0100
committerAndreas Sturmlechner <asturm@gentoo.org>2019-02-09 21:57:45 +0100
commit78c098995b8818447e70e06437d01058aff568c6 (patch)
tree97a63c4d03064c27ac1ffc7e308e482255f08ced
parentwww-client/falkon: Drop 3.0.1 (r0) (diff)
downloadgentoo-78c098995b8818447e70e06437d01058aff568c6.tar.gz
gentoo-78c098995b8818447e70e06437d01058aff568c6.tar.bz2
gentoo-78c098995b8818447e70e06437d01058aff568c6.zip
media-libs/libsidplay: EAPI-7 bump, fix arm64/ppc64 build with GCC-6
Patch kindly borrowed from Debian. Reported-by: ernsteiswuerfel <erhard_f@mailbox.org> Bug: https://bugs.gentoo.org/649804 Package-Manager: Portage-2.3.59, Repoman-2.3.12 Signed-off-by: Andreas Sturmlechner <asturm@gentoo.org>
-rw-r--r--media-libs/libsidplay/files/libsidplay-2.1.1-gcc6.patch22
-rw-r--r--media-libs/libsidplay/libsidplay-2.1.1-r5.ebuild61
2 files changed, 83 insertions, 0 deletions
diff --git a/media-libs/libsidplay/files/libsidplay-2.1.1-gcc6.patch b/media-libs/libsidplay/files/libsidplay-2.1.1-gcc6.patch
new file mode 100644
index 000000000000..7cfac32b2295
--- /dev/null
+++ b/media-libs/libsidplay/files/libsidplay-2.1.1-gcc6.patch
@@ -0,0 +1,22 @@
+Description: explicit cast to int8_t
+ Fix FTBFS with GCC 6 due to narrowing conversions from 'char' to 'int8_t'.
+Author: Laszlo Boszormenyi (GCS) <gcs@debian.org>
+Forwarded: no
+Bug-Debian: https://bugs.debian.org/837378
+Last-Update: 2016-09-19
+
+---
+
+--- sidplay-libs-2.1.1.orig/libsidplay/src/xsid/xsid.cpp
++++ sidplay-libs-2.1.1/libsidplay/src/xsid/xsid.cpp
+@@ -96,8 +96,8 @@ const int8_t XSID::sampleConvertTable[16
+ */
+ const int8_t XSID::sampleConvertTable[16] =
+ {
+- '\x80', '\x94', '\xa9', '\xbc', '\xce', '\xe1', '\xf2', '\x03',
+- '\x1b', '\x2a', '\x3b', '\x49', '\x58', '\x66', '\x73', '\x7f'
++ (int8_t)'\x80', (int8_t)'\x94', (int8_t)'\xa9', (int8_t)'\xbc', (int8_t)'\xce', (int8_t)'\xe1', (int8_t)'\xf2', (int8_t)'\x03',
++ (int8_t)'\x1b', (int8_t)'\x2a', (int8_t)'\x3b', (int8_t)'\x49', (int8_t)'\x58', (int8_t)'\x66', (int8_t)'\x73', (int8_t)'\x7f'
+ };
+
+ const char *XSID::credit =
diff --git a/media-libs/libsidplay/libsidplay-2.1.1-r5.ebuild b/media-libs/libsidplay/libsidplay-2.1.1-r5.ebuild
new file mode 100644
index 000000000000..cb385dd5622a
--- /dev/null
+++ b/media-libs/libsidplay/libsidplay-2.1.1-r5.ebuild
@@ -0,0 +1,61 @@
+# Copyright 1999-2019 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit libtool multilib-minimal
+
+MY_P=sidplay-libs-${PV}
+
+DESCRIPTION="C64 SID player library"
+HOMEPAGE="http://sidplay2.sourceforge.net/"
+SRC_URI="mirror://sourceforge/sidplay2/${MY_P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="2"
+KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sparc ~x86 ~amd64-fbsd ~x86-fbsd"
+IUSE="static-libs"
+
+MULTILIB_WRAPPED_HEADERS=(
+ /usr/include/sidplay/sidconfig.h
+)
+
+PATCHES=(
+ "${FILESDIR}"/${P}-gcc41.patch
+ "${FILESDIR}"/${P}-fbsd.patch
+ "${FILESDIR}"/${P}-gcc43.patch
+ "${FILESDIR}"/${P}-no_libtool_reference.patch
+ "${FILESDIR}"/${P}-gcc6.patch
+)
+
+S="${WORKDIR}/${MY_P}"
+
+src_prepare() {
+ default
+ elibtoolize
+ multilib_copy_sources
+}
+
+multilib_src_configure() {
+ local myeconfargs=(
+ --enable-shared
+ --with-pic
+ $(use_enable static-libs static)
+ )
+ econf "${myeconfargs[@]}"
+}
+
+multilib_src_install_all() {
+ docinto libsidplay
+ dodoc libsidplay/{AUTHORS,ChangeLog,README,TODO}
+
+ docinto libsidutils
+ dodoc libsidutils/{AUTHORS,ChangeLog,README,TODO}
+
+ docinto resid
+ dodoc resid/{AUTHORS,ChangeLog,NEWS,README,THANKS,TODO}
+
+ doenvd "${FILESDIR}"/65resid
+
+ find "${D}" -name '*.la' -delete || die
+}