mirror of
https://github.com/gentoo-mirror/guru.git
synced 2025-04-18 07:19:01 -04:00
// Major changes: * Add a patch to disable HTTP/3 by default. * Relax requirements for indirect dependencies, which are only checked at build time. * Separate runtime dependencies from build dependencies. // Notable changes: * Drop Qt6Concurrency dependency. * Drop Qt6DeclarativeWidgets dependency. * Add subslot operators for qtbase and qtdeclarative because private APIs are used. * Do not hard-depend on GStreamer support for QtMultimedia. * Add gst-plugins-qt6 dependency for video call support. * Fix GStreamer deps for X11 and Wayland. // Minor changes: * Add minimum Qt version restriction. * Bump minimum GStreamer version. * Add pkg-config dependency. * Change IUSE: +man -> man Signed-off-by: Anna (cybertailor) Vyalkova <cyber+gentoo@sysrq.in>
130 lines
3.0 KiB
Bash
130 lines
3.0 KiB
Bash
# Copyright 2020-2024 Gentoo Authors
|
|
# Distributed under the terms of the GNU General Public License v2
|
|
|
|
EAPI=8
|
|
|
|
inherit cmake optfeature xdg
|
|
|
|
MY_P="${PN}-v${PV}"
|
|
DESCRIPTION="Native desktop client for Matrix using Qt"
|
|
HOMEPAGE="https://github.com/Nheko-Reborn/nheko"
|
|
SRC_URI="https://nheko.im/nheko-reborn/${PN}/-/archive/v${PV}/${MY_P}.tar.bz2"
|
|
S="${WORKDIR}/${MY_P}"
|
|
|
|
LICENSE="GPL-3 MIT"
|
|
SLOT="0"
|
|
KEYWORDS="~amd64"
|
|
IUSE="X doc +pie man video voip wayland"
|
|
REQUIRED_USE="video? ( voip )"
|
|
|
|
# Check WebRTCSession::havePlugins() in ./src/voip/WebRTCSession.cpp
|
|
# to get GStreamer plugin deps right.
|
|
MY_GST_V="1.20.0"
|
|
|
|
QTMIN="6.5.0"
|
|
COMMON_DEPEND="
|
|
app-text/cmark:=
|
|
>=dev-cpp/blurhash-0.2.0:=
|
|
dev-cpp/cpp-httplib:=
|
|
dev-db/lmdb:=
|
|
dev-libs/libfmt:=
|
|
>=dev-libs/kdsingleapplication-1.1.0
|
|
>=dev-libs/mtxclient-0.10.0:=
|
|
dev-libs/olm
|
|
>=dev-libs/qtkeychain-0.14.1-r1:=[qt6]
|
|
dev-libs/spdlog:=
|
|
>=dev-qt/qtbase-${QTMIN}:6=[dbus,gui,widgets]
|
|
>=dev-qt/qtdeclarative-${QTMIN}:6=
|
|
>=dev-qt/qtmultimedia-${QTMIN}:6[qml]
|
|
>=dev-qt/qtsvg-${QTMIN}:6
|
|
X? (
|
|
x11-libs/libxcb:=
|
|
x11-libs/xcb-util-wm
|
|
)
|
|
voip? (
|
|
>=media-libs/gstreamer-${MY_GST_V}:1.0
|
|
>=media-libs/gst-plugins-bad-${MY_GST_V}:1.0[wayland?]
|
|
>=media-libs/gst-plugins-base-${MY_GST_V}:1.0[X?,opengl]
|
|
)
|
|
"
|
|
# Dependencies which are required by CMake but not linked with Nheko
|
|
INDIRECT_DEPEND="
|
|
>=dev-cpp/coeurl-0.3.0
|
|
dev-libs/libevent
|
|
dev-libs/openssl
|
|
dev-libs/re2
|
|
net-misc/curl
|
|
"
|
|
DEPEND="
|
|
${COMMON_DEPEND}
|
|
${INDIRECT_DEPEND}
|
|
dev-cpp/nlohmann_json
|
|
>=dev-db/lmdb++-1.0.0
|
|
"
|
|
RDEPEND="
|
|
${COMMON_DEPEND}
|
|
dev-qt/qtimageformats:6
|
|
virtual/notification-daemon
|
|
voip? (
|
|
>=media-plugins/gst-plugins-dtls-${MY_GST_V}:1.0
|
|
media-plugins/gst-plugins-libnice:1.0
|
|
>=media-plugins/gst-plugins-meta-${MY_GST_V}:1.0[opus]
|
|
>=media-plugins/gst-plugins-srtp-${MY_GST_V}:1.0
|
|
>=media-plugins/gst-plugins-webrtc-${MY_GST_V}:1.0
|
|
video? (
|
|
>=media-plugins/gst-plugins-meta-${MY_GST_V}:1.0[vpx]
|
|
>=media-plugins/gst-plugins-qt6-${MY_GST_V}:1.0
|
|
X? (
|
|
>=media-plugins/gst-plugins-ximagesrc-${MY_GST_V}:1.0
|
|
)
|
|
wayland? (
|
|
media-video/pipewire[gstreamer]
|
|
)
|
|
)
|
|
)
|
|
"
|
|
BDEPEND="
|
|
>=dev-qt/qttools-${QTMIN}:6[linguist]
|
|
virtual/pkgconfig
|
|
doc? ( app-text/doxygen[dot] )
|
|
man? (
|
|
|| (
|
|
app-text/asciidoc
|
|
dev-ruby/asciidoctor
|
|
)
|
|
)
|
|
"
|
|
|
|
PATCHES=(
|
|
"${FILESDIR}"/${PN}-0.12.0-disable-http3.patch
|
|
"${FILESDIR}"/${PN}-0.12.0-fmt11.patch
|
|
"${FILESDIR}"/${PN}-0.12.0-remove-wayland-dep-on-x11.patch
|
|
)
|
|
|
|
src_configure() {
|
|
local -a mycmakeargs=(
|
|
-DUSE_BUNDLED_CPPHTTPLIB=no
|
|
-DUSE_BUNDLED_BLURHASH=no
|
|
|
|
-DVOIP=$(usex voip)
|
|
-DX11=$(usex X)
|
|
-DBUILD_DOCS=$(usex doc)
|
|
-DMAN=$(usex man)
|
|
|
|
# See #890903 and #911111
|
|
-DCMAKE_POSITION_INDEPENDENT_CODE=$(usex pie)
|
|
)
|
|
|
|
cmake_src_configure
|
|
}
|
|
|
|
pkg_postinst() {
|
|
optfeature "secrets storage support other than kwallet (for example gnome-keyring or keepassxc)" \
|
|
"dev-libs/qtkeychain[keyring]"
|
|
optfeature "additional, less common, image format support" \
|
|
kde-frameworks/kimageformats:6
|
|
optfeature "identicons support" dev-cpp/qt-jdenticon:6
|
|
|
|
xdg_pkg_postinst
|
|
}
|