From mboxrd@z Thu Jan  1 00:00:00 1970
Return-Path: <gentoo-commits+bounces-1241855-garchives=archives.gentoo.org@lists.gentoo.org>
Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80])
	(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
	(No client certificate requested)
	by finch.gentoo.org (Postfix) with ESMTPS id 1348E1382C5
	for <garchives@archives.gentoo.org>; Fri, 15 Jan 2021 08:25:04 +0000 (UTC)
Received: from pigeon.gentoo.org (localhost [127.0.0.1])
	by pigeon.gentoo.org (Postfix) with SMTP id 1B4A8E087C;
	Fri, 15 Jan 2021 08:24:57 +0000 (UTC)
Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183])
	(using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits))
	(No client certificate requested)
	by pigeon.gentoo.org (Postfix) with ESMTPS id 03A5FE087C
	for <gentoo-commits@lists.gentoo.org>; Fri, 15 Jan 2021 08:24:56 +0000 (UTC)
Received: from oystercatcher.gentoo.org (unknown [IPv6:2a01:4f8:202:4333:225:90ff:fed9:fc84])
	(using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits))
	(No client certificate requested)
	by smtp.gentoo.org (Postfix) with ESMTPS id 098AA340E42
	for <gentoo-commits@lists.gentoo.org>; Fri, 15 Jan 2021 08:24:56 +0000 (UTC)
Received: from localhost.localdomain (localhost [IPv6:::1])
	by oystercatcher.gentoo.org (Postfix) with ESMTP id B979E53
	for <gentoo-commits@lists.gentoo.org>; Fri, 15 Jan 2021 08:24:54 +0000 (UTC)
From: "Andrew Ammerlaan" <andrewammerlaan@riseup.net>
To: gentoo-commits@lists.gentoo.org
Content-Transfer-Encoding: 8bit
Content-type: text/plain; charset=UTF-8
Reply-To: gentoo-dev@lists.gentoo.org, "Andrew Ammerlaan" <andrewammerlaan@riseup.net>
Message-ID: <1610699086.7c42b3e976a4afaf0f711abbeb76de550737e15f.andrewammerlaan@gentoo>
Subject: [gentoo-commits] repo/proj/guru:dev commit in: media-video/syncplay/
X-VCS-Repository: repo/proj/guru
X-VCS-Files: media-video/syncplay/syncplay-1.6.7-r1.ebuild media-video/syncplay/syncplay-1.6.7.ebuild
X-VCS-Directories: media-video/syncplay/
X-VCS-Committer: andrewammerlaan
X-VCS-Committer-Name: Andrew Ammerlaan
X-VCS-Revision: 7c42b3e976a4afaf0f711abbeb76de550737e15f
X-VCS-Branch: dev
Date: Fri, 15 Jan 2021 08:24:54 +0000 (UTC)
Precedence: bulk
List-Post: <mailto:gentoo-commits@lists.gentoo.org>
List-Help: <mailto:gentoo-commits+help@lists.gentoo.org>
List-Unsubscribe: <mailto:gentoo-commits+unsubscribe@lists.gentoo.org>
List-Subscribe: <mailto:gentoo-commits+subscribe@lists.gentoo.org>
List-Id: Gentoo Linux mail <gentoo-commits.gentoo.org>
X-BeenThere: gentoo-commits@lists.gentoo.org
X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply
X-Archives-Salt: 8d03a5de-12fc-40cd-8d8b-f5a4b77364ca
X-Archives-Hash: 29e5bd28511861b03a304700429cace9
Message-ID: <20210115082454.EZjryxGqQUrr_MSyNXjhd9iXpTgVFgEQburQzkAfzq4@z>

commit:     7c42b3e976a4afaf0f711abbeb76de550737e15f
Author:     Andrew Ammerlaan <andrewammerlaan <AT> riseup <DOT> net>
AuthorDate: Fri Jan 15 08:24:46 2021 +0000
Commit:     Andrew Ammerlaan <andrewammerlaan <AT> riseup <DOT> net>
CommitDate: Fri Jan 15 08:24:46 2021 +0000
URL:        https://gitweb.gentoo.org/repo/proj/guru.git/commit/?id=7c42b3e9

media-video/syncplay: properly install python modules and scripts

now we use the dedicated python_do* functions instead of
the shipped make install, this ensures that syncplay
is run with the version of python that is enabled with
PYTHON_TARGETS

also set DISTUTILS_SINGLE_IMPL because there is no
need to install this for more than one python version

Closes: https://bugs.gentoo.org/765484
Package-Manager: Portage-3.0.13, Repoman-3.0.2
Signed-off-by: Andrew Ammerlaan <andrewammerlaan <AT> riseup.net>

 ...cplay-1.6.7.ebuild => syncplay-1.6.7-r1.ebuild} | 27 +++++++++++++++-------
 1 file changed, 19 insertions(+), 8 deletions(-)

diff --git a/media-video/syncplay/syncplay-1.6.7.ebuild b/media-video/syncplay/syncplay-1.6.7-r1.ebuild
similarity index 67%
rename from media-video/syncplay/syncplay-1.6.7.ebuild
rename to media-video/syncplay/syncplay-1.6.7-r1.ebuild
index 6c85c3d3..0454f956 100644
--- a/media-video/syncplay/syncplay-1.6.7.ebuild
+++ b/media-video/syncplay/syncplay-1.6.7-r1.ebuild
@@ -1,12 +1,13 @@
-# Copyright 1999-2020 Gentoo Authors
+# Copyright 1999-2021 Gentoo Authors
 # Distributed under the terms of the GNU General Public License v2
 
 EAPI=7
 
 PYTHON_COMPAT=( python3_{7,8,9} )
 DISTUTILS_USE_SETUPTOOLS=rdepend
+DISTUTILS_SINGLE_IMPL=1
 
-inherit distutils-r1 optfeature xdg
+inherit desktop distutils-r1 optfeature xdg
 
 DESCRIPTION="Client/server to synchronize media playback"
 HOMEPAGE="https://github.com/Syncplay/syncplay https://syncplay.pl"
@@ -17,12 +18,17 @@ SLOT="0"
 KEYWORDS="~amd64 ~x86"
 
 IUSE="+client +server"
+REQUIRED_USE="|| ( client server )"
 
 RDEPEND="
-	dev-python/certifi[${PYTHON_USEDEP}]
-	dev-python/twisted[${PYTHON_USEDEP}]
+	$( python_gen_cond_dep \
+	'dev-python/certifi[${PYTHON_USEDEP}]
+	dev-python/twisted[${PYTHON_USEDEP}]'
+	)
 	client? (
-		dev-python/QtPy[${PYTHON_USEDEP},gui]
+		$( python_gen_cond_dep \
+		'dev-python/QtPy[${PYTHON_USEDEP},gui]'
+		)
 		|| (
 			media-video/vlc[lua]
 			media-video/mpv[lua]
@@ -40,12 +46,17 @@ PATCHES=(
 )
 
 python_install() {
-	local MY_MAKEOPTS=( DESTDIR="${D}" PREFIX=/usr )
+	python_domodule syncplay
+	for size in 256 128 96 64 48 32 24 16; do
+		doicon -s ${size} "${PN}/resources/hicolor/${size}x${size}/apps/syncplay.png"
+	done
 	if use client; then
-		emake "${MY_MAKEOPTS[@]}" install-client
+		python_newscript syncplayClient.py syncplay
+		domenu syncplay/resources/syncplay.desktop
 	fi
 	if use server; then
-		emake "${MY_MAKEOPTS[@]}" install-server
+		python_newscript syncplayServer.py syncplay-server
+		domenu syncplay/resources/syncplay-server.desktop
 		newinitd "${FILESDIR}/${PN}-server-init" "${PN}"
 		newconfd "${FILESDIR}/${PN}-server-init-conf" "${PN}"
 	fi