From 9fea4b8d50194e66603c7ac93b1ec619c59d104c Mon Sep 17 00:00:00 2001
From: Christian Schroeder <chris.schroeder.public@gmail.com>
Date: Mon, 16 Aug 2021 11:21:13 +0300
Subject: x11-misc/copyq: bump to 4.1.0

Closes: https://bugs.gentoo.org/807190
Signed-off-by: Christian Schroeder <chris.schroeder.public@gmail.com>
Signed-off-by: Joonas Niilola <juippis@gentoo.org>
---
 x11-misc/copyq/Manifest                            |  1 +
 x11-misc/copyq/copyq-4.1.0.ebuild                  | 59 ++++++++++++++++++++++
 .../copyq/files/copyq-4.1.0-bash-completion.patch  | 14 +++++
 3 files changed, 74 insertions(+)
 create mode 100644 x11-misc/copyq/copyq-4.1.0.ebuild
 create mode 100644 x11-misc/copyq/files/copyq-4.1.0-bash-completion.patch

(limited to 'x11-misc')

diff --git a/x11-misc/copyq/Manifest b/x11-misc/copyq/Manifest
index a0a405df42bc..f976b7203c8b 100644
--- a/x11-misc/copyq/Manifest
+++ b/x11-misc/copyq/Manifest
@@ -1 +1,2 @@
 DIST copyq-3.13.0.tar.gz 2917941 BLAKE2B e8fc963e6a773ae70ca5a39f9ea55a98de5c5d129b845d0da9ed08ffec65d88ed8b5dd138dea11a33d563b899f0497929ed3c40d418574e50c2a1fbbd7b1a9f6 SHA512 898d4501002202849f0b5302d7315e8c539f8b0f8d5198641b3d3a647839581841e2ef1e2519c690d3cc95f85fdc921c979f2879348184de42767d31e081c307
+DIST copyq-4.1.0.tar.gz 2999036 BLAKE2B 1252a66a3bbde3d4435ced9934792ed97066229b23cd5ec21a6187d4f36718d46ac5e16ff19c45afee8715a32686bfe8e47af1bbb37d61a1cacb4e9395dc7bc9 SHA512 538be8b5b60dc054cb8220174461516a4d1e9d6f7c1a03406770f143b83f9a23875b0cf663406e16d83a762b6170587f0e44c386a7d9d552ec6f914b3673206d
diff --git a/x11-misc/copyq/copyq-4.1.0.ebuild b/x11-misc/copyq/copyq-4.1.0.ebuild
new file mode 100644
index 000000000000..379ed955f7ea
--- /dev/null
+++ b/x11-misc/copyq/copyq-4.1.0.ebuild
@@ -0,0 +1,59 @@
+# Copyright 1999-2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit cmake xdg-utils
+
+DESCRIPTION="Clipboard manager with advanced features"
+HOMEPAGE="https://github.com/hluk/CopyQ"
+SRC_URI="https://github.com/hluk/CopyQ/archive/v${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="GPL-3+"
+SLOT="0"
+KEYWORDS="~amd64 ~x86 ~amd64-linux ~x86-linux"
+IUSE="test"
+
+RESTRICT="!test? ( test )"
+
+RDEPEND="
+	dev-qt/qtcore:5
+	dev-qt/qtgui:5
+	dev-qt/qtnetwork:5
+	dev-qt/qtsvg:5
+	dev-qt/qtwayland:5
+	dev-qt/qtwidgets:5
+	dev-qt/qtx11extras:5
+	kde-frameworks/knotifications:5
+	x11-libs/libX11
+	x11-libs/libXfixes
+	x11-libs/libXtst
+"
+DEPEND="${RDEPEND}
+	test? ( dev-qt/qttest:5 )"
+BDEPEND="
+	dev-qt/linguist-tools:5
+"
+
+S="${WORKDIR}/CopyQ-${PV}"
+
+PATCHES=( "${FILESDIR}/${P}-bash-completion.patch" )
+
+src_configure() {
+	local mycmakeargs=(
+		-DCMAKE_BUILD_TYPE=Release
+		-DPLUGIN_INSTALL_PREFIX="/usr/$(get_libdir)/${PN}/plugins"
+		-DWITH_TESTS=$(usex test)
+	)
+	cmake_src_configure
+}
+
+pkg_postinst() {
+	xdg_desktop_database_update
+	xdg_icon_cache_update
+}
+
+pkg_postrm() {
+	xdg_desktop_database_update
+	xdg_icon_cache_update
+}
diff --git a/x11-misc/copyq/files/copyq-4.1.0-bash-completion.patch b/x11-misc/copyq/files/copyq-4.1.0-bash-completion.patch
new file mode 100644
index 000000000000..f787dcbd2ae5
--- /dev/null
+++ b/x11-misc/copyq/files/copyq-4.1.0-bash-completion.patch
@@ -0,0 +1,14 @@
+Fix installation of bash completion script.
+Signed-off-by: Christian Schroeder <chris.schroeder.public@gmail.com>
+
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -54,7 +54,7 @@
+ set(copyq_ICON_MASK       src/images/icon_mask.svg)
+ set(copyq_DESKTOP         shared/${copyq_APP_ID}.desktop)
+ set(copyq_APPDATA         shared/${copyq_APP_ID}.appdata.xml)
+-set(copyq_BASH_COMPLETION shared/${copyq_APP_ID}.appdata.xml)
++set(copyq_BASH_COMPLETION shared/copyq-completion)
+ set(copyq_MANPAGE         debian/copyq.1)
+ 
+ # Be more strict while compiling debugging version
-- 
cgit v1.2.3-65-gdbad