aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid Roman <davidroman96@gmail.com>2024-06-11 23:32:15 +0200
committerDavid Roman <davidroman96@gmail.com>2024-06-11 23:32:39 +0200
commit2811ebc1e0708e328bcb950817b41a20b9ce00dd (patch)
treef6ece7b4e4b112ced0313b3597fe620d7577ed98 /media-sound
parentnet-vpn/candy: Remove the dependence on libconfig (diff)
downloadguru-2811ebc1e0708e328bcb950817b41a20b9ce00dd.tar.gz
guru-2811ebc1e0708e328bcb950817b41a20b9ce00dd.tar.bz2
guru-2811ebc1e0708e328bcb950817b41a20b9ce00dd.zip
media-sound/TauonMusicBox: add 7.8.0
Signed-off-by: David Roman <davidroman96@gmail.com>
Diffstat (limited to 'media-sound')
-rw-r--r--media-sound/TauonMusicBox/Manifest1
-rw-r--r--media-sound/TauonMusicBox/TauonMusicBox-7.8.0.ebuild126
-rw-r--r--media-sound/TauonMusicBox/files/TauonMusicBox-7.8.0-phazor-fix.patch13
-rw-r--r--media-sound/TauonMusicBox/files/TauonMusicBox-7.8.0-unidecode-compat.patch102
4 files changed, 242 insertions, 0 deletions
diff --git a/media-sound/TauonMusicBox/Manifest b/media-sound/TauonMusicBox/Manifest
index 1b606799a..caaaa67a7 100644
--- a/media-sound/TauonMusicBox/Manifest
+++ b/media-sound/TauonMusicBox/Manifest
@@ -1 +1,2 @@
DIST TauonMusicBox-7.7.2.tar.gz 992102 BLAKE2B a7aca5e3aea42e045147f3768a57d74cf877f9b4e0114b982dc4f6291acdeacda9b5f709a4b26a340d162b9768bb1de4847f82839ec894d03d744531028e6584 SHA512 42a47b5795f2e49adb8bf0673fb932b10d3a3b8ad309b2fc88ed54f44f2b5ced4391d653773a1b34ef4dbbb18d16016b9d3b30eb1d99fac725fc6ac4c8e01d27
+DIST TauonMusicBox-7.8.0.tar.gz 1080654 BLAKE2B 6c671efc10f0e7340bb2db0ebcc59f25784a665a9a2e85ab5132a10362d9d0f7041affedc763ed5acde19c529c742e127eb1493578f9f79ca7f3b1dfd4439784 SHA512 0896e185314037e23d76776ce96b227ede8a96651958df7ca0acc0d37c431169aeb72395116d8887d37c1360c15f436f7488c751866e60fa5ba3a5082b9acef8
diff --git a/media-sound/TauonMusicBox/TauonMusicBox-7.8.0.ebuild b/media-sound/TauonMusicBox/TauonMusicBox-7.8.0.ebuild
new file mode 100644
index 000000000..5266e873e
--- /dev/null
+++ b/media-sound/TauonMusicBox/TauonMusicBox-7.8.0.ebuild
@@ -0,0 +1,126 @@
+# Copyright 2024 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+PLOCALES="cs de es fr_FR hu id it ja_JP nb_NO pl pt pt_BR pt_PT ru sv tr zh_CN"
+
+PYTHON_COMPAT=( python3_{10..12} )
+DISTUTILS_USE_PEP517=setuptools
+
+inherit cmake desktop distutils-r1 optfeature plocale xdg
+
+DESCRIPTION="The desktop music player of today!"
+HOMEPAGE="https://tauonmusicbox.rocks/"
+
+if [[ ${PV} == *9999 ]]; then
+ EGIT_SUBMODULES=()
+ inherit git-r3
+ EGIT_REPO_URI="https://github.com/Taiko2k/${PN}"
+else
+ SRC_URI="https://github.com/Taiko2k/${PN}/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz"
+ KEYWORDS="~amd64"
+fi
+
+S="${WORKDIR}/Tauon-${PV}"
+
+LICENSE="GPL-3"
+SLOT="0"
+
+PHAZOR_DEPS="
+ dev-libs/miniaudio
+ media-libs/flac
+ media-libs/game-music-emu
+ media-libs/libopenmpt
+ media-libs/opus
+ media-libs/opusfile
+ media-libs/libsamplerate
+ media-libs/libvorbis
+ media-sound/mpg123
+ media-sound/wavpack
+ sci-libs/kissfft[-cpu_flags_x86_sse]
+"
+
+DEPEND="
+ dev-python/beautifulsoup4[${PYTHON_USEDEP}]
+ dev-python/musicbrainzngs[${PYTHON_USEDEP}]
+ dev-python/natsort[${PYTHON_USEDEP}]
+ dev-python/pillow[${PYTHON_USEDEP}]
+ dev-python/PySDL2[${PYTHON_USEDEP}]
+ dev-python/requests[${PYTHON_USEDEP}]
+ dev-python/setproctitle[${PYTHON_USEDEP}]
+ dev-python/send2trash[${PYTHON_USEDEP}]
+ dev-python/unidecode[${PYTHON_USEDEP}]
+ media-video/ffmpeg
+ media-libs/mutagen[${PYTHON_USEDEP}]
+ media-libs/sdl2-image
+
+ ${PHAZOR_DEPS}
+"
+
+RDEPEND="
+ ${DEPEND}
+
+ dev-libs/libappindicator
+ x11-libs/libnotify
+"
+
+BDEPEND="sys-devel/gettext"
+
+src_prepare() {
+ # Workaround. If PATCHES is used it would be applied to times and fail
+ eapply "${FILESDIR}/${P}-phazor-fix.patch"
+ eapply "${FILESDIR}/${P}-unidecode-compat.patch"
+
+ distutils-r1_src_prepare
+ cmake_src_prepare
+}
+
+src_configure() {
+ distutils-r1_src_configure
+ cmake_src_configure
+}
+
+src_compile() {
+ distutils-r1_src_compile
+ cmake_src_compile
+
+ build_locale() {
+ msgfmt -o "locale/${1}/LC_MESSAGES/tauon.mo" "locale/${1}/LC_MESSAGES/tauon.po" || die
+ }
+
+ plocale_for_each_locale build_locale
+}
+
+src_test() {
+ distutils-r1_src_test
+ cmake_src_test
+}
+
+python_install() {
+ newbin tauon.py tauon
+ dolib.so "${WORKDIR}/Tauon-${PV}_build/libphazor.so"
+
+ install_locale() {
+ insinto "/usr/share/locale/${1}/LC_MESSAGES"
+ doins "locale/${1}/LC_MESSAGES/tauon.mo"
+ }
+
+ plocale_for_each_locale install_locale
+
+ insinto "/usr/share/${PN}"
+ doins -r assets theme templates
+ doins input.txt
+
+ sed -i 's/\/opt\/tauon-music-box\/tauonmb.sh/tauon/g' extra/tauonmb.desktop || die
+ domenu extra/tauonmb.desktop
+ doicon -s scalable extra/tauonmb.svg
+
+ distutils-r1_python_install
+}
+
+pkg_postinst() {
+ optfeature "last fm support" dev-python/pylast
+ optfeature "PLEX support" dev-python/plexapi
+
+ xdg_pkg_postinst
+}
diff --git a/media-sound/TauonMusicBox/files/TauonMusicBox-7.8.0-phazor-fix.patch b/media-sound/TauonMusicBox/files/TauonMusicBox-7.8.0-phazor-fix.patch
new file mode 100644
index 000000000..bf9623611
--- /dev/null
+++ b/media-sound/TauonMusicBox/files/TauonMusicBox-7.8.0-phazor-fix.patch
@@ -0,0 +1,13 @@
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index cf79faf5..dd00073b 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -5,7 +5,7 @@ add_library(phazor SHARED src/phazor/phazor.c)
+
+ find_package(PkgConfig REQUIRED)
+
+-pkg_check_modules(phazor REQUIRED flac libopenmpt libmpg123 opus opusfile wavpack samplerate)
++pkg_check_modules(phazor REQUIRED flac libgme libopenmpt libmpg123 opus opusfile wavpack samplerate)
+
+ find_package(kissfft CONFIG COMPONENTS float)
+ if(NOT kissfft_FOUND)
diff --git a/media-sound/TauonMusicBox/files/TauonMusicBox-7.8.0-unidecode-compat.patch b/media-sound/TauonMusicBox/files/TauonMusicBox-7.8.0-unidecode-compat.patch
new file mode 100644
index 000000000..be66f2391
--- /dev/null
+++ b/media-sound/TauonMusicBox/files/TauonMusicBox-7.8.0-unidecode-compat.patch
@@ -0,0 +1,102 @@
+commit 6438345be829fa95bcaedf125cf4b29aa1d5064d
+Author: David Roman <davidroman96@gmail.com>
+Date: Sun Jun 2 15:47:44 2024 +0200
+
+ replace isounidecode with unidecode
+
+diff --git a/extra/win-requirements.txt b/extra/win-requirements.txt
+index ef2dfd42..ccb54be7 100644
+--- a/extra/win-requirements.txt
++++ b/extra/win-requirements.txt
+@@ -8,7 +8,7 @@ requests
+ beautifulsoup4
+ PlexAPI
+ musicbrainzngs
+-isounidecode
++unidecode
+ infi.systray
+ mutagen
+ natsort
+diff --git a/requirements.txt b/requirements.txt
+index 3252278f..970d3a06 100644
+--- a/requirements.txt
++++ b/requirements.txt
+@@ -6,7 +6,7 @@ requests
+ beautifulsoup4
+ PlexAPI
+ musicbrainzngs
+-isounidecode
++unidecode
+ setproctitle
+ mutagen
+ natsort
+diff --git a/t_modules/t_lyrics.py b/t_modules/t_lyrics.py
+index 8e5d197a..19b91bd8 100644
+--- a/t_modules/t_lyrics.py
++++ b/t_modules/t_lyrics.py
+@@ -18,7 +18,7 @@
+ # along with Tauon Music Box. If not, see <http://www.gnu.org/licenses/>.
+
+
+-from isounidecode import unidecode
++from unidecode import unidecode
+ from bs4 import BeautifulSoup
+ import urllib.parse
+ import requests
+@@ -81,7 +81,7 @@ def genius(artist, title, return_url=False):
+ line = line.replace("/", "-")
+ line = line.replace("-&-", "-and-")
+ line = line.replace("&", "-and-")
+- line = unidecode(line).decode()
++ line = unidecode(line)
+ line = urllib.parse.quote(line)
+ line = f"https://genius.com/{line}-lyrics"
+
+diff --git a/t_modules/t_main.py b/t_modules/t_main.py
+index c2f2ebab..4848b7b2 100644
+--- a/t_modules/t_main.py
++++ b/t_modules/t_main.py
+@@ -591,7 +591,7 @@ from pathlib import Path
+ from xml.sax.saxutils import escape, unescape
+ from ctypes import *
+ from send2trash import send2trash
+-from isounidecode import unidecode
++from unidecode import unidecode
+ from collections import OrderedDict
+
+ musicbrainzngs.set_useragent("TauonMusicBox", n_version, "https://github.com/Taiko2k/Tauon")
+@@ -25663,14 +25663,14 @@ def worker2():
+ s_text = s_cn
+
+ if dia_mode:
+- title = unidecode(title).decode()
++ title = unidecode(title)
+
+- artist = unidecode(artist).decode()
+- album_artist = unidecode(album_artist).decode()
+- composer = unidecode(composer).decode()
+- album = unidecode(album).decode()
+- filename = unidecode(filename).decode()
+- sartist = unidecode(sartist).decode()
++ artist = unidecode(artist)
++ album_artist = unidecode(album_artist)
++ composer = unidecode(composer)
++ album = unidecode(album)
++ filename = unidecode(filename)
++ sartist = unidecode(sartist)
+
+ if cache_string is None:
+ search_dia_string_cache[
+@@ -30054,9 +30054,9 @@ class Over:
+ click=self.click, replace="github")
+
+ y += spacing
+- ddt.text((x, y), "isounidecode", colours.box_sub_text, font)
+- ddt.text((xx, y), "New BSD License", colours.box_text_label, font)
+- draw_linked_text2(xxx, y, "https://github.com/redvasily/isounidecode", colours.box_sub_text, font,
++ ddt.text((x, y), "unidecode", colours.box_sub_text, font)
++ ddt.text((xx, y), "GPL-2.0+", colours.box_text_label, font)
++ draw_linked_text2(xxx, y, "https://github.com/avian2/unidecode", colours.box_sub_text, font,
+ click=self.click, replace="github")
+
+ y += spacing