From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 5C413138206 for ; Wed, 3 Jan 2018 08:31:13 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id A4DF3E0883; Wed, 3 Jan 2018 08:31:12 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 710C5E0883 for ; Wed, 3 Jan 2018 08:31:12 +0000 (UTC) Received: from oystercatcher.gentoo.org (unknown [IPv6:2a01:4f8:202:4333:225:90ff:fed9:fc84]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 21F01335C30 for ; Wed, 3 Jan 2018 08:31:11 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id AB4C4126 for ; Wed, 3 Jan 2018 08:31:09 +0000 (UTC) From: "Slawek Lis" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Slawek Lis" Message-ID: <1514968238.9297efe754fb1e7e470dfe3f1081f3dacb8fee46.slis@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: dev-python/Kivy/files/, dev-python/Kivy/ X-VCS-Repository: repo/gentoo X-VCS-Files: dev-python/Kivy/Kivy-1.10.0.ebuild dev-python/Kivy/files/modplug-fix.patch X-VCS-Directories: dev-python/Kivy/files/ dev-python/Kivy/ X-VCS-Committer: slis X-VCS-Committer-Name: Slawek Lis X-VCS-Revision: 9297efe754fb1e7e470dfe3f1081f3dacb8fee46 X-VCS-Branch: master Date: Wed, 3 Jan 2018 08:31:09 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Archives-Salt: 1027c1c4-cbe8-4eb7-af66-2e40dd956666 X-Archives-Hash: 67dfc7ba973c5e8ca32a7db6ac29b915 commit: 9297efe754fb1e7e470dfe3f1081f3dacb8fee46 Author: Slawomir Lis gentoo org> AuthorDate: Wed Jan 3 08:30:38 2018 +0000 Commit: Slawek Lis gentoo org> CommitDate: Wed Jan 3 08:30:38 2018 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=9297efe7 dev-python/Kivy: Patch fixing bug with sdl-mixer Bug id: 636012 Package-Manager: Portage-2.3.19, Repoman-2.3.6 dev-python/Kivy/Kivy-1.10.0.ebuild | 6 +- dev-python/Kivy/files/modplug-fix.patch | 109 ++++++++++++++++++++++++++++++++ 2 files changed, 114 insertions(+), 1 deletion(-) diff --git a/dev-python/Kivy/Kivy-1.10.0.ebuild b/dev-python/Kivy/Kivy-1.10.0.ebuild index 8e2cb32ef0b..0a913ae26c1 100644 --- a/dev-python/Kivy/Kivy-1.10.0.ebuild +++ b/dev-python/Kivy/Kivy-1.10.0.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2017 Gentoo Foundation +# Copyright 1999-2018 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 EAPI=6 @@ -38,6 +38,10 @@ DEPEND="${RDEPEND} S="${WORKDIR}/${P,,}" +PATCHES=( + "${FILESDIR}/modplug-fix.patch" +) + python_prepare_all() { # sed -e '/data_files=/d' -i "${S}/setup.py" || die # sed -e 's/PYTHON = python/PYTHON ?= python/' -i Makefile || die diff --git a/dev-python/Kivy/files/modplug-fix.patch b/dev-python/Kivy/files/modplug-fix.patch new file mode 100644 index 00000000000..18abe6e8f80 --- /dev/null +++ b/dev-python/Kivy/files/modplug-fix.patch @@ -0,0 +1,109 @@ +From 3b85f3e1c292b3f6c3f226490f52a2ab78251730 Mon Sep 17 00:00:00 2001 +From: Terje Skjaeveland +Date: Sun, 29 Oct 2017 12:35:46 +0100 +Subject: [PATCH] audio_sdl2: Update for mixer v2.0.2 support + +Flags MIX_INIT_MODPLUG was removed, and MIX_INIT_FLUIDSYNTH was +renamed to MIX_INIT_MID. +--- + kivy/core/audio/audio_sdl2.pyx | 45 +++++++++++++++++++++++++++++------------- + kivy/lib/sdl2.pxi | 4 ++-- + 2 files changed, 33 insertions(+), 16 deletions(-) + +diff --git a/kivy/core/audio/audio_sdl2.pyx b/kivy/core/audio/audio_sdl2.pyx +index 2ab569fe60..c6f26be5c8 100644 +--- a/kivy/core/audio/audio_sdl2.pyx ++++ b/kivy/core/audio/audio_sdl2.pyx +@@ -15,9 +15,23 @@ Depending the compilation of SDL2 mixer and/or installed libraries: + * ogg since 1.9.1 (mixer needs libvorbis/libogg) + * flac since 1.9.1 (mixer needs libflac) + * mp3 since 1.9.1 (mixer needs libsmpeg/libmad; only use mad for GPL apps) ++ * Since 1.10.1 + mixer 2.0.2, mpg123 can also be used + * sequenced formats since 1.9.1 (midi, mod, s3m, etc. Mixer needs + libmodplug or libmikmod) + ++.. Note:: ++ ++ Sequenced format support changed with mixer v2.0.2. If mixer is ++ linked with one of libmodplug or libmikmod, format support for ++ both libraries is assumed. This will work perfectly with formats ++ upported by both libraries, but if you were to try to load an ++ obscure format (like `apun` file with mikmod only), it will fail. ++ ++ * Kivy <= 1.10.0: will fail to build with mixer >= 2.0.2 ++ will report correct format support with < 2.0.2 ++ * Kivy >= 1.10.1: will build with old and new mixer, and ++ will "guesstimate" sequenced format support ++ + .. Warning:: + + Sequenced formats use the SDL2 Mixer music channel, you can only play +@@ -57,8 +71,13 @@ cdef mix_init(): + mix_is_init = -1 + return 0 + ++ # In mixer 2.0.2, MIX_INIT_MODPLUG is now implied by MIX_INIT_MOD, ++ # and MIX_INIT_FLUIDSYNTH was renamed to MIX_INIT_MID. In previous ++ # versions, we requested both _MODPLUG and _MOD + _FLUIDSYNTH. ++ # 0x20 used to be MIX_INIT_FLUIDSYNTH, now MIX_INIT_MID ++ # 0x4 used to be MIX_INIT_MODPLUG before 2.0.2 + want_flags = MIX_INIT_FLAC | MIX_INIT_OGG | MIX_INIT_MP3 +- want_flags |= MIX_INIT_MOD | MIX_INIT_MODPLUG | MIX_INIT_FLUIDSYNTH ++ want_flags |= MIX_INIT_MOD | 0x20 | 0x4 + + mix_flags = Mix_Init(want_flags) + +@@ -244,25 +263,23 @@ class MusicSDL2(Sound): + @staticmethod + def extensions(): + mix_init() ++ # FIXME: this should probably evolve to use the new has_music() ++ # interface to determine format support + + # Assume native midi support (defaults to enabled), but may use + # modplug, fluidsynth or timidity in reality. It may also be + # disabled completely, in which case loading it will fail + extensions = set(['mid', 'midi']) + +- # libmodplug, may be incomplete +- if mix_flags & MIX_INIT_MODPLUG: +- extensions.update(['669', 'abc', 'amf', 'ams', 'dbm', 'dmf', +- 'dsm', 'far', 'it', 'j2b', 'mdl', 'med', +- 'mod', 'mt2', 'mtm', 'okt', 'pat', 'psm', +- 'ptm', 's3m', 'stm', 'ult', 'umx', 'xm']) +- +- # libmikmod, may be incomplete +- if mix_flags & MIX_INIT_MOD: +- extensions.update(['669', 'amf', 'apun', 'dsm', 'far', 'gdm', +- 'gt2', 'it', 'med', 'mod', 'mtm', 'okt', +- 's3m', 'stm', 'stx', 'ult', 'umx', 'uni', +- 'xm']) ++ # libmodplug and libmikmod, may be incomplete. ++ # 0x4 is for mixer < 2.0.2, MIX_INIT_MODPLUG ++ if mix_flags & (MIX_INIT_MOD | 0x4): ++ extensions.update(['669', 'abc', 'amf', 'ams', 'apun', 'dbm', ++ 'dmf', 'dsm', 'far', 'gdm', 'it', 'j2b', ++ 'mdl', 'med', 'mod', 'mt2', 'mtm', 'okt', ++ 'pat', 'psm', 'ptm', 's3m', 'stm', 'stx', ++ 'ult', 'umx', 'uni', 'xm']) ++ + return list(extensions) + + def __init__(self, **kwargs): +diff --git a/kivy/lib/sdl2.pxi b/kivy/lib/sdl2.pxi +index 07d055c903..ad62ce8023 100644 +--- a/kivy/lib/sdl2.pxi ++++ b/kivy/lib/sdl2.pxi +@@ -881,10 +881,10 @@ cdef extern from "SDL_mixer.h": + ctypedef enum MIX_InitFlags: + MIX_INIT_FLAC = 0x00000001 + MIX_INIT_MOD = 0x00000002 +- MIX_INIT_MODPLUG = 0x00000004 ++ MIX_INIT_MODPLUG = 0x00000004 # Removed in mixer 2.0.2 + MIX_INIT_MP3 = 0x00000008 + MIX_INIT_OGG = 0x00000010 +- MIX_INIT_FLUIDSYNTH = 0x00000020 ++ MIX_INIT_MID = 0x00000020 # Previously _FLUIDSYNTH + + cdef int MIX_MAX_VOLUME +