git: 9288f153e01b - main - audio/rhythmbox: unbreak with --auto-features=enabled

From: Jan Beich <jbeich_at_FreeBSD.org>
Date: Thu, 30 Mar 2023 02:12:58 UTC
The branch main has been updated by jbeich:

URL: https://cgit.FreeBSD.org/ports/commit/?id=9288f153e01b684b2bb16b51e6cf752f93e4c52c

commit 9288f153e01b684b2bb16b51e6cf752f93e4c52c
Author:     Jan Beich <jbeich@FreeBSD.org>
AuthorDate: 2023-03-30 01:31:20 +0000
Commit:     Jan Beich <jbeich@FreeBSD.org>
CommitDate: 2023-03-30 02:11:56 +0000

    audio/rhythmbox: unbreak with --auto-features=enabled
    
    meson.build:227:0: ERROR: Dependency "lirc" not found, tried pkgconfig
    
    PR:             270361
    Reported by:    antoine (via exp-run)
---
 audio/rhythmbox/Makefile                |  6 +++---
 audio/rhythmbox/files/patch-meson.build | 14 ++++++++++++++
 audio/rhythmbox/pkg-plist               |  6 +++---
 3 files changed, 20 insertions(+), 6 deletions(-)

diff --git a/audio/rhythmbox/Makefile b/audio/rhythmbox/Makefile
index 40287a5fea46..51fd5ba61bc3 100644
--- a/audio/rhythmbox/Makefile
+++ b/audio/rhythmbox/Makefile
@@ -38,7 +38,7 @@ USE_LDCONFIG=	yes
 GLIB_SCHEMAS=	org.gnome.rhythmbox.gschema.xml
 
 OPTIONS_SUB=	yes
-OPTIONS_DEFINE=	BRASERO DAAP DOCS GRILO IPOD MTP NLS NOTIFY PYTHON
+OPTIONS_DEFINE=	BRASERO DAAP DOCS GRILO IPOD LIRC MTP NLS NOTIFY PYTHON
 OPTIONS_DEFAULT=BRASERO NOTIFY PYTHON
 BRASERO_DESC=	Brasero disc burning support
 BRASERO_MESON_ENABLED=	brasero
@@ -56,8 +56,8 @@ IPOD_MESON_ENABLED=	ipod
 IPOD_LIB_DEPENDS=	libgpod.so:audio/libgpod \
 			libplist-2.0.so:devel/libplist \
 			libimobiledevice-1.0.so:comms/libimobiledevice
-#LIRC_MESON_ENABLED=	lirc
-#LIRC_LIB_DEPENDS=	liblirc_client.so:comms/lirc
+LIRC_MESON_ENABLED=	lirc
+LIRC_LIB_DEPENDS=	liblirc_client.so:comms/lirc
 MTP_MESON_ENABLED=	mtp
 MTP_LIB_DEPENDS=	libmtp.so:multimedia/libmtp
 NOTIFY_MESON_ENABLED=	libnotify
diff --git a/audio/rhythmbox/files/patch-meson.build b/audio/rhythmbox/files/patch-meson.build
new file mode 100644
index 000000000000..4a2522cee67f
--- /dev/null
+++ b/audio/rhythmbox/files/patch-meson.build
@@ -0,0 +1,14 @@
+Drop after comms/lirc >= 0.9.2 update.
+https://sourceforge.net/p/lirc/git/ci/c763e92584a9
+
+--- meson.build.orig	2022-06-21 12:04:40 UTC
++++ meson.build
+@@ -224,7 +224,7 @@ endif
+   plugins += 'notification'
+ endif
+ 
+-lirc = dependency('lirc', required: get_option('lirc'))
++lirc = cc.find_library('lirc_client', required: get_option('lirc'))
+ if lirc.found()
+   plugins += 'lirc'
+ endif
diff --git a/audio/rhythmbox/pkg-plist b/audio/rhythmbox/pkg-plist
index afe3d78a3411..a7494a1d3722 100644
--- a/audio/rhythmbox/pkg-plist
+++ b/audio/rhythmbox/pkg-plist
@@ -146,8 +146,8 @@ lib/rhythmbox/plugins/power-manager/power-manager.plugin
 %%PYTHON%%lib/rhythmbox/plugins/rb/rb.py
 %%PYTHON%%lib/rhythmbox/plugins/rb/rbconfig.py
 %%PYTHON%%lib/rhythmbox/plugins/rb/stringmatch.py
-@comment %%LIRC%%lib/rhythmbox/plugins/rblirc/librblirc.so
-@comment %%LIRC%%lib/rhythmbox/plugins/rblirc/rblirc.plugin
+%%LIRC%%lib/rhythmbox/plugins/rblirc/librblirc.so
+%%LIRC%%lib/rhythmbox/plugins/rblirc/rblirc.plugin
 %%PYTHON%%lib/rhythmbox/plugins/replaygain/config.py
 %%PYTHON%%lib/rhythmbox/plugins/replaygain/player.py
 %%PYTHON%%lib/rhythmbox/plugins/replaygain/replaygain.plugin
@@ -488,4 +488,4 @@ share/metainfo/org.gnome.Rhythmbox3.appdata.xml
 %%DATADIR%%/rhythmbox.gep
 share/vala/vapi/rb.vapi
 share/vala/vapi/rhythmdb.vapi
-@comment %%LIRC%%%%DATADIR%%/plugins/rblirc/rhythmbox_lirc_default
+%%LIRC%%%%DATADIR%%/plugins/rblirc/rhythmbox_lirc_default