# Template file for 'gnome-podcasts'
pkgname=gnome-podcasts
version=25.3
revision=1
build_style=meson
build_helper="rust"
hostmakedepends="cargo desktop-file-utils gettext glib-devel
 gtk-update-icon-cache pkg-config"
makedepends="gstreamer1-devel gst-plugins-bad1-devel gst-plugins-base1-devel
 gtk4-devel libadwaita-devel openssl-devel sqlite-devel texinfo rust-std"
short_desc="Listen to your favorite podcasts"
maintainer="Orphaned <orphan@voidlinux.org>"
license="GPL-3.0-or-later"
homepage="https://apps.gnome.org/Podcasts/"
changelog="https://gitlab.gnome.org/World/podcasts/-/blob/main/CHANGELOG.md"
distfiles="https://gitlab.gnome.org/World/podcasts/-/archive/${version}/podcasts-${version}.tar.gz"
checksum=b2d012e31f20385bbba9919dacf5783ea20fb3e60c86dfd21fdf7d8ea640d600
make_check=no # Unable to init server: Could not connect: Connection refused

export GETTEXT_BIN_DIR=/usr/bin
export GETTEXT_LIB_DIR="${XBPS_CROSS_BASE}/usr/lib/gettext"
export GETTEXT_INCLUDE_DIR="${XBPS_CROSS_BASE}/usr/include"

post_patch() {
	if [ "$CROSS_BUILD" ]; then
		vsed -i podcasts-gtk/src/meson.build \
			-e "s%rust_target /%'${RUST_TARGET}' / rust_target /%"
	fi
}
