summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarek Szuba <marecki@gentoo.org>2021-07-18 00:00:27 +0100
committerMarek Szuba <marecki@gentoo.org>2021-07-18 01:31:40 +0100
commitff8efc6a420864e0a2150530cdbc07e401501690 (patch)
tree0892de9dbf10beed48cce64ba2210d09b2b5b36d /media-sound/pulseeffects
parentmedia-sound/pulseeffects: tweak USE-flag descriptions in metadata (diff)
downloadgentoo-ff8efc6a420864e0a2150530cdbc07e401501690.tar.gz
gentoo-ff8efc6a420864e0a2150530cdbc07e401501690.tar.bz2
gentoo-ff8efc6a420864e0a2150530cdbc07e401501690.zip
media-sound/pulseeffects: improve dependencies
1. Both dev-libs/appstream-glib and sys-devel/gettext are *build-time* dependencies so they should have been moved from DEPEND to BDEPEND when this package got bumped to EAPI 7. Do it now; 2. Add missing (if optional) BDEPEND dev-util/desktop-file-utils; 3. Add an explanation of why media-libs/libsamplerate is in BDEPEND rather than DEPEND; 4. Clearly separate dependencies which meson looks for (in DEPEND+RDEPEND) from those which are auto-loaded at run time (in RDEPEND only); 5. Add RDEPEND=gnome-extra/yelp so that it is possible to display built-in help; 6. Add DEPEND="media-libs/libsndfile (implicitly pulled in by media-libs/lilv but meson looks for it and pulseffects is linked against it) media-libs/gst-plugins-base (pulled in by other GStreamer plug-in packs but meson explicitly looks for gstreamer-audio and gstreamer-fft)"; 7. The pitch plug-in only works properly if media-libs/rubberband has USE=ladspa set; 8. Optionally enable rnnoise and webrtc plug-ins; 8. Patch meson scripts so that if USE-flags: bs2db and rnnoise are disabled, the relevant dependencies are not pulled in even if present at build time. Signed-off-by: Marek Szuba <marecki@gentoo.org>
Diffstat (limited to 'media-sound/pulseeffects')
-rw-r--r--media-sound/pulseeffects/files/pulseeffects-4.8.5-meson_no_automagic.patch55
-rw-r--r--media-sound/pulseeffects/pulseeffects-4.8.5-r1.ebuild83
2 files changed, 138 insertions, 0 deletions
diff --git a/media-sound/pulseeffects/files/pulseeffects-4.8.5-meson_no_automagic.patch b/media-sound/pulseeffects/files/pulseeffects-4.8.5-meson_no_automagic.patch
new file mode 100644
index 000000000000..2ad89e629771
--- /dev/null
+++ b/media-sound/pulseeffects/files/pulseeffects-4.8.5-meson_no_automagic.patch
@@ -0,0 +1,55 @@
+--- a/meson.build
++++ b/meson.build
+@@ -4,7 +4,7 @@
+ 'cpp',
+ default_options : ['cpp_std=c++17','buildtype=debugoptimized'],
+ version: '4.8.5',
+- meson_version: '>= 0.40.0'
++ meson_version: '>= 0.47.0'
+ )
+
+ add_global_arguments('-DG_LOG_DOMAIN="pulseeffects"', language : 'c')
+--- a/meson_options.txt
++++ b/meson_options.txt
+@@ -0,0 +1,12 @@
++option(
++ 'bs2b',
++ type: 'feature',
++ value: 'auto',
++ description: 'Enable bs2b-based Crossfeed plug-in for improving headphone listening of stereo audio records'
++)
++option(
++ 'rnnoise',
++ type: 'feature',
++ value: 'auto',
++ description: 'Enable rnnoise-based Noise Reduction plug-in'
++)
+--- a/src/meson.build
++++ b/src/meson.build
+@@ -108,7 +108,7 @@
+ dependency('gstreamer-plugins-bad-1.0', version: '>=1.12.5'),
+ dependency('gstreamer-fft-1.0'),
+ dependency('lilv-0', version: '>=0.22', required: false),
+- dependency('libbs2b', required: false),
++ dependency('libbs2b', required: get_option('bs2b')),
+ dependency('boost', version: '>=1.72', modules:['system','filesystem']),
+ dependency('sndfile'),
+ dependency('threads')
+--- a/src/rnnoise/meson.build
++++ b/src/rnnoise/meson.build
+@@ -1,4 +1,5 @@
+-dep_rnnoise = dependency('rnnoise', required: false)
++opt_rnnoise = get_option('rnnoise')
++dep_rnnoise = dependency('rnnoise', required: opt_rnnoise)
+
+ if dep_rnnoise.found()
+
+@@ -28,7 +29,7 @@
+ cpp_args: plugins_cxx_args
+ )
+
+-else
++elif opt_rnnoise.auto()
+
+ message('could not find the RNNoise library')
+
diff --git a/media-sound/pulseeffects/pulseeffects-4.8.5-r1.ebuild b/media-sound/pulseeffects/pulseeffects-4.8.5-r1.ebuild
new file mode 100644
index 000000000000..2525d6bef1d3
--- /dev/null
+++ b/media-sound/pulseeffects/pulseeffects-4.8.5-r1.ebuild
@@ -0,0 +1,83 @@
+# Copyright 1999-2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit gnome2-utils meson
+
+DESCRIPTION="Limiter, compressor, reverberation, equalizer auto volume effects for Pulseaudio"
+HOMEPAGE="https://github.com/wwmm/easyeffects/tree/pulseaudio-legacy"
+
+if [[ ${PV} == *9999 ]]; then
+ inherit git-r3
+ EGIT_REPO_URI="https://github.com/wwmm/easyeffects"
+ EGIT_BRANCH="pulseaudio-legacy"
+else
+ SRC_URI="https://github.com/wwmm/easyeffects/archive/v${PV}.tar.gz -> ${P}.tar.gz"
+ KEYWORDS="~amd64 ~x86"
+fi
+
+LICENSE="GPL-3"
+SLOT="0"
+IUSE="bs2b calf rnnoise rubberband webrtc"
+
+DEPEND=">=dev-libs/boost-1.72:=
+ >=dev-cpp/glibmm-2.56.0:2
+ >=dev-cpp/gtkmm-3.24:3.0
+ >=dev-libs/glib-2.56:2
+ >=dev-libs/libsigc++-2.10:2
+ >=media-libs/gstreamer-1.12.5:1.0
+ media-libs/gst-plugins-base
+ >=media-libs/gst-plugins-bad-1.12.5:1.0
+ media-libs/libebur128
+ media-libs/libsndfile
+ >=media-libs/lilv-0.24.2-r1
+ >=media-libs/zita-convolver-3.0.0
+ media-sound/pulseaudio
+ >=x11-libs/gtk+-3.20:3
+ bs2b? ( >=media-plugins/gst-plugins-bs2b-1.12.5:1.0 )
+ rnnoise? ( media-libs/rnnoise )"
+RDEPEND="!media-sound/easyeffects
+ ${DEPEND}
+ gnome-extra/yelp
+ >=media-libs/gst-plugins-good-1.12.5:1.0
+ >=media-libs/lsp-plugins-1.1.24[lv2]
+ >=media-plugins/gst-plugins-ladspa-1.12.5:1.0
+ >=media-plugins/gst-plugins-lv2-1.12.5:1.0
+ >=media-plugins/gst-plugins-pulse-1.12.5:1.0
+ sys-apps/dbus
+ calf? ( >=media-plugins/calf-0.90.1[lv2] )
+ rubberband? ( media-libs/rubberband[ladspa] )
+ webrtc? ( media-plugins/gst-plugins-webrtc )"
+# Only header files are used from libsamplerate so put it here rather than DEPEND
+# to avoid unnecessary cross-compilation.
+BDEPEND="dev-libs/appstream-glib
+ dev-util/desktop-file-utils
+ dev-util/itstool
+ media-libs/libsamplerate
+ sys-devel/gettext
+ virtual/pkgconfig"
+
+PATCHES=(
+ "${FILESDIR}"/${PN}-4.8.5-meson_no_automagic.patch
+)
+
+src_configure() {
+ local emesonargs=(
+ $(meson_feature bs2b)
+ $(meson_feature rnnoise)
+ )
+ meson_src_configure
+}
+
+pkg_postinst() {
+ gnome2_gconf_install
+ gnome2_schemas_update
+ xdg_icon_cache_update
+}
+
+pkg_postrm() {
+ gnome2_gconf_uninstall
+ gnome2_schemas_update
+ xdg_icon_cache_update
+}