logo

overlay

My (experimental) gentoo overlay
commit: 24759874c5f5d59b2f3b0dd7f4d2f0b1e5459958
parent: 3578a39dbb037d980f48a71967c2faf0aa8b8d0a
Author: Haelwenn (lanodan) Monnier <contact@hacktivis.me>
Date:   Wed, 16 May 2018 03:10:08 +0200

media-libs/libsidplay: Clang compatibility (imported from ::gentoo)

Diffstat:

MREADME3+++
Amedia-libs/libsidplay/Manifest1+
Amedia-libs/libsidplay/files/libsidplay-2.1.1-fbsd.patch11+++++++++++
Amedia-libs/libsidplay/files/libsidplay-2.1.1-gcc41.patch37+++++++++++++++++++++++++++++++++++++
Amedia-libs/libsidplay/files/libsidplay-2.1.1-no_libtool_reference.patch18++++++++++++++++++
Amedia-libs/libsidplay/libsidplay-2.1.1-r5.ebuild55+++++++++++++++++++++++++++++++++++++++++++++++++++++++
6 files changed, 125 insertions(+), 0 deletions(-)

diff --git a/README b/README @@ -31,3 +31,6 @@ Adding this overlay: layman -a lanodanOverlay ## app-misc/kanatest • Bumped from EAPI 5 to EAPI 6 • Add patch removing __DATE__ __TIME__ + +## media-libs/libsidplay:2 +• Clang compatibility (removed a GCC-4.3 patch) diff --git a/media-libs/libsidplay/Manifest b/media-libs/libsidplay/Manifest @@ -0,0 +1 @@ +DIST sidplay-libs-2.1.1.tar.gz 1900252 BLAKE2B f04e34f4cfc641a8222e5d53575108bd52deb2de2dc0b0d58e91581ade7128ac87f320f16e044baa23b54de6b5b6b833e9f6c0d37a1885341a329e778c0a0228 SHA512 754cd41f3d2d76754049522c395022bc090f99ea838e6d1ffb8d7689f3aedad9b3879be0312d0af49ba108563296c1176d1e533d1151d5b33368bfda0a1910e3 diff --git a/media-libs/libsidplay/files/libsidplay-2.1.1-fbsd.patch b/media-libs/libsidplay/files/libsidplay-2.1.1-fbsd.patch @@ -0,0 +1,11 @@ +--- a/libsidutils/src/ini/ini.cpp ++++ b/libsidutils/src/ini/ini.cpp +@@ -100,7 +100,7 @@ + //******************************************************************************************************************* + #include <assert.h> + #include <ctype.h> +-#include <malloc.h> ++#include <stdlib.h> + #include <stdio.h> + #include <string.h> + diff --git a/media-libs/libsidplay/files/libsidplay-2.1.1-gcc41.patch b/media-libs/libsidplay/files/libsidplay-2.1.1-gcc41.patch @@ -0,0 +1,37 @@ +--- a/libsidplay/include/sidplay/SmartPtr.h ++++ b/libsidplay/include/sidplay/SmartPtr.h +@@ -211,16 +211,16 @@ + { + if ( bufferLen >= 1 ) + { +- pBufCurrent = ( bufBegin = buffer ); +- bufEnd = bufBegin + bufferLen; +- bufLen = bufferLen; +- status = true; ++ this->pBufCurrent = ( this->bufBegin = buffer ); ++ this->bufEnd = this->bufBegin + bufferLen; ++ this->bufLen = bufferLen; ++ this->status = true; + } + else + { +- pBufCurrent = bufBegin = bufEnd = 0; +- bufLen = 0; +- status = false; ++ this->pBufCurrent = this->bufBegin = this->bufEnd = 0; ++ this->bufLen = 0; ++ this->status = false; + } + } + }; +--- a/libsidutils/include/sidplay/utils/SidUsage.h ++++ b/libsidutils/include/sidplay/utils/SidUsage.h +@@ -33,7 +33,7 @@ + uint_least16_t length; // usage scan length + + // Copy common parts of basic usage to extended usage. +- sid2_usage_t &sid2_usage_t::operator= (const sid_usage_t &usage) ++ sid2_usage_t &operator= (const sid_usage_t &usage) + { + *((sid_usage_t *) this) = usage; + return *this; diff --git a/media-libs/libsidplay/files/libsidplay-2.1.1-no_libtool_reference.patch b/media-libs/libsidplay/files/libsidplay-2.1.1-no_libtool_reference.patch @@ -0,0 +1,18 @@ +--- a/libsidplay/unix/libsidplay2.pc.in ++++ b/libsidplay/unix/libsidplay2.pc.in +@@ -7,5 +7,5 @@ + Name: @PACKAGE@ + Description: C64 cycle exact stereo sidplayer library. + Version: @VERSION@ +-Libs: ${libdir}/libsidplay2.la ++Libs: -lsidplay2 + Cflags: -DHAVE_UNIX -I${includedir} +--- a/libsidutils/unix/libsidutils.pc.in ++++ b/libsidutils/unix/libsidutils.pc.in +@@ -6,5 +6,5 @@ + Name: @PACKAGE@ + Description: Utils for supporting the libsidplay2 library. + Version: @VERSION@ +-Libs: ${libdir}/libsidutils.la ++Libs: -lsidutils + Cflags: -DHAVE_UNIX -I${includedir} diff --git a/media-libs/libsidplay/libsidplay-2.1.1-r5.ebuild b/media-libs/libsidplay/libsidplay-2.1.1-r5.ebuild @@ -0,0 +1,55 @@ +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=4 +inherit eutils 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" + +S=${WORKDIR}/${MY_P} + +MULTILIB_WRAPPED_HEADERS=( + /usr/include/sidplay/sidconfig.h + /usr/include/sidplay/sidint.h +) + +src_prepare() { + epatch \ + "${FILESDIR}"/${P}-gcc41.patch \ + "${FILESDIR}"/${P}-fbsd.patch \ + "${FILESDIR}"/${P}-no_libtool_reference.patch + + elibtoolize + multilib_copy_sources +} + +multilib_src_configure() { + econf \ + --enable-shared \ + $(use_enable static-libs static) \ + --with-pic +} + +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 + + prune_libtool_files --all +}