From 8736bde34469e9e0716a9d00ca67b6529bab3849 Mon Sep 17 00:00:00 2001 From: Subhaditya Nath Date: Sat, 28 Jan 2023 19:36:46 +0530 Subject: [PATCH] musikcube: update to 0.99.4 --- srcpkgs/musikcube-alsa | 1 + srcpkgs/musikcube-gme | 1 + srcpkgs/musikcube-portaudio | 1 + .../patches/fix-install-locations.patch | 25 ++++++++--- srcpkgs/musikcube/patches/ppc-musl.patch | 13 ------ srcpkgs/musikcube/template | 42 +++++++++++++++---- 6 files changed, 55 insertions(+), 28 deletions(-) create mode 120000 srcpkgs/musikcube-alsa create mode 120000 srcpkgs/musikcube-gme create mode 120000 srcpkgs/musikcube-portaudio delete mode 100644 srcpkgs/musikcube/patches/ppc-musl.patch diff --git a/srcpkgs/musikcube-alsa b/srcpkgs/musikcube-alsa new file mode 120000 index 00000000000000..b3cc8e74bf4847 --- /dev/null +++ b/srcpkgs/musikcube-alsa @@ -0,0 +1 @@ +musikcube \ No newline at end of file diff --git a/srcpkgs/musikcube-gme b/srcpkgs/musikcube-gme new file mode 120000 index 00000000000000..b3cc8e74bf4847 --- /dev/null +++ b/srcpkgs/musikcube-gme @@ -0,0 +1 @@ +musikcube \ No newline at end of file diff --git a/srcpkgs/musikcube-portaudio b/srcpkgs/musikcube-portaudio new file mode 120000 index 00000000000000..b3cc8e74bf4847 --- /dev/null +++ b/srcpkgs/musikcube-portaudio @@ -0,0 +1 @@ +musikcube \ No newline at end of file diff --git a/srcpkgs/musikcube/patches/fix-install-locations.patch b/srcpkgs/musikcube/patches/fix-install-locations.patch index 590f27bf1a7dfd..eaa012dbe128bb 100644 --- a/srcpkgs/musikcube/patches/fix-install-locations.patch +++ b/srcpkgs/musikcube/patches/fix-install-locations.patch @@ -36,7 +36,7 @@ index 62d3c003..01ef58ac 100644 DESTINATION bin/ PERMISSIONS OWNER_EXECUTE OWNER_READ OWNER_WRITE -@@ -66,14 +58,6 @@ install( +@@ -58,14 +50,6 @@ install( # executable and shell script for daemon install( FILES bin/musikcubed @@ -54,8 +54,8 @@ index 62d3c003..01ef58ac 100644 diff --git a/src/musikcore/support/Common.cpp b/src/musikcore/support/Common.cpp index 31703117..53aa8a88 100644 --- a/src/musikcore/support/Common.cpp -+++ b/src/musikcore/support/Common.cpp -@@ -82,65 +82,11 @@ static inline void silentDelete(const std::string fn) { ++++ a/src/musikcore/support/Common.cpp +@@ -87,78 +87,11 @@ namespace musik { namespace core { std::string GetPluginDirectory() { @@ -105,15 +105,28 @@ index 31703117..53aa8a88 100644 - argv = new char*[len]; - if (sysctl(mib, 4, argv, &len, nullptr, 0) < 0) abort(); - -- boost::filesystem::path command = boost::filesystem::system_complete(argv[0]); -- realpath(command.c_str(), pathbuf); +- fs::path command = fs::absolute(fs::path(fs::u8path(argv[0]))); +- realpath(command.u8string().c_str(), pathbuf); - delete[] argv; +- #elif defined __HAIKU__ +- image_info ii; +- int32 c = 0; +- while (get_next_image_info(0, &c, &ii) == B_OK) { +- if (ii.type == B_APP_IMAGE) { +- if (strlen(ii.name)) { +- std::string fn(ii.name); +- result = fs::u8path(fn).u8string(); +- } +- } +- } - #else - std::string pathToProc = u8fmt("/proc/%d/exe", (int) getpid()); - readlink(pathToProc.c_str(), pathbuf, PATH_MAX); - #endif - -- result.assign(pathbuf); +- if (!result.size() && strlen(pathbuf)) { +- result.assign(pathbuf); +- } - size_t last = result.find_last_of("/"); - result = result.substr(0, last); /* remove filename component */ - #endif diff --git a/srcpkgs/musikcube/patches/ppc-musl.patch b/srcpkgs/musikcube/patches/ppc-musl.patch deleted file mode 100644 index fc5d21c7a9767d..00000000000000 --- a/srcpkgs/musikcube/patches/ppc-musl.patch +++ /dev/null @@ -1,13 +0,0 @@ -Taken from libgme patches. - ---- a/src/plugins/gmedecoder/gme/blargg_endian.h -+++ b/src/plugins/gmedecoder/gme/blargg_endian.h -@@ -36,7 +36,7 @@ - #endif - - #if defined (MSB_FIRST) || defined (__BIG_ENDIAN__) || defined (WORDS_BIGENDIAN) || \ -- defined (__sparc__) || BLARGG_CPU_POWERPC || \ -+ defined (__sparc__) || \ - (defined (BIG_ENDIAN) && BIG_ENDIAN+0 != 4321) - #define BLARGG_BIG_ENDIAN 1 - #elif !defined (__mips__) diff --git a/srcpkgs/musikcube/template b/srcpkgs/musikcube/template index 8157816c87688e..4b79300411260f 100644 --- a/srcpkgs/musikcube/template +++ b/srcpkgs/musikcube/template @@ -1,23 +1,23 @@ # Template file for 'musikcube' pkgname=musikcube -version=0.98.0 -revision=3 +version=0.99.4 +revision=1 build_style=cmake make_cmd=make -configure_args="-DNO_NCURSESW=1 -DENABLE_BUNDLED_TAGLIB=false" +configure_args="-DNO_NCURSESW=1" hostmakedepends="pkg-config" -makedepends="boost-devel libogg-devel libmicrohttpd-devel ffmpeg-devel +makedepends="libgme-devel libogg-devel libmicrohttpd-devel ffmpeg-devel openssl-devel pulseaudio-devel lame-devel zlib-devel alsa-lib-devel libvorbis-devel libcurl-devel ncurses-devel libev-devel taglib-devel sndio-devel pipewire-devel ncurses-libtinfo-devel libopenmpt-devel - $(vopt_if elogind elogind-devel)" + portaudio-devel asio $(vopt_if elogind elogind-devel)" short_desc="Terminal-based music player in c++" maintainer="Subhaditya Nath " license="BSD-3-Clause" homepage="https://musikcube.com/" changelog="https://raw.githubusercontent.com/clangen/musikcube/master/CHANGELOG.txt" distfiles="https://github.com/clangen/musikcube/archive/${version}.tar.gz" -checksum=a4ae9d6d0fa5ce99de2e7bbc1de75cc8638704a2284b38a51178e23bbe55499c +checksum=dd8e74c8c8460250c0da325941db2df0f7dcca77f2c68a0295ab21e81f8dd8a4 build_options="elogind" desc_option_elogind="Support MPRIS interface via elogind" build_options_default="elogind" @@ -40,11 +40,11 @@ musikcube-devel_package() { } } -musikcube-sndio_package() { +musikcube-alsa_package() { depends="${sourcepkg}>=${version}_${revision}" - short_desc+=" - sndio output plugin" + short_desc+=" - alsa output plugin" pkg_install() { - vmove usr/lib/musikcube/plugins/libsndioout.so + vmove usr/lib/musikcube/plugins/libalsaout.so } } @@ -56,6 +56,30 @@ musikcube-pipewire_package() { } } +musikcube-portaudio_package() { + depends="${sourcepkg}>=${version}_${revision}" + short_desc+=" - portaudio output plugin" + pkg_install() { + vmove usr/lib/musikcube/plugins/libportaudioout.so + } +} + +musikcube-sndio_package() { + depends="${sourcepkg}>=${version}_${revision}" + short_desc+=" - sndio output plugin" + pkg_install() { + vmove usr/lib/musikcube/plugins/libsndioout.so + } +} + +musikcube-gme_package() { + depends="${sourcepkg}>=${version}_${revision}" + short_desc+=" - gme decoder plugin" + pkg_install() { + vmove usr/lib/musikcube/plugins/libgmedecoder.so + } +} + musikcube-openmpt_package() { depends="${sourcepkg}>=${version}_${revision}" short_desc+=" - openmpt decoder plugin"