git: 584a88ad2575 - main - audio/py-pyradio: Update to 0.8.9.32
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Sat, 10 Dec 2022 13:51:59 UTC
The branch main has been updated by nivit: URL: https://cgit.FreeBSD.org/ports/commit/?id=584a88ad25752c63b8951cf38fe8ab418942fb2d commit 584a88ad25752c63b8951cf38fe8ab418942fb2d Author: Nicola Vitale <nivit@FreeBSD.org> AuthorDate: 2022-12-10 13:48:15 +0000 Commit: Nicola Vitale <nivit@FreeBSD.org> CommitDate: 2022-12-10 13:50:25 +0000 audio/py-pyradio: Update to 0.8.9.32 - Install additional files (.desktop and icon) - Add a post-patch target to set up default configuration - Add desktop-file-utils to USES Changelog: https://github.com/coderholic/pyradio/releases/tag/0.8.9.32 --- audio/py-pyradio/Makefile | 17 ++++++++++++++--- audio/py-pyradio/distinfo | 6 +++--- audio/py-pyradio/files/patch-pyradio_ping.py | 20 ++++++++++---------- 3 files changed, 27 insertions(+), 16 deletions(-) diff --git a/audio/py-pyradio/Makefile b/audio/py-pyradio/Makefile index db7e65364794..9d82a06aedab 100644 --- a/audio/py-pyradio/Makefile +++ b/audio/py-pyradio/Makefile @@ -1,5 +1,5 @@ PORTNAME= pyradio -DISTVERSION= 0.8.9.31 +DISTVERSION= 0.8.9.32 CATEGORIES= audio python PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX} @@ -21,11 +21,13 @@ RUN_DEPENDS= ${PKGNAMEPREFIX}dnspython>=2.2.1:dns/py-dnspython@${PY_FLAVOR} \ ${PKGNAMEPREFIX}wheel>=0.38.4:devel/py-wheel@${PY_FLAVOR} \ bash:shells/bash -USES= python:3.7+ +USES= desktop-file-utils python:3.7+ USE_GITHUB= yes GH_ACCOUNT= coderholic USE_PYTHON= autoplist distutils +PLIST_FILES= share/applications/${PORTNAME}.desktop \ + share/pixmaps/${PORTNAME}.png PORTDOCS= * OPTIONS_DEFINE= DOCS @@ -43,9 +45,18 @@ MPLAYER_RUN_DEPENDS+= mplayer:multimedia/mplayer MPV_RUN_DEPENDS+= mpv:multimedia/mpv VLC_RUN_DEPENDS+= vlc:multimedia/vlc +post-patch: + ${SED} -i.bak -e 's/\(distro =\) None/\1 ${OPSYS}/' \ + -e 's/\(enable_notifications =\) -1/\1 0/' \ + ${WRKSRC}/pyradio/config + post-install-DOCS-on: - ${MKDIR} ${STAGEDIR}${DOCSDIR} + @${MKDIR} ${STAGEDIR}${DOCSDIR} ${INSTALL_MAN} ${WRKSRC}/pyradio*.1 ${STAGEDIR}${MANPREFIX}/man/man1 ${INSTALL_DATA} ${WRKSRC}/*.html ${WRKSRC}/*.md ${STAGEDIR}${DOCSDIR}/ + ${INSTALL_DATA} ${WRKSRC}/devel/${PORTNAME}.desktop \ + ${STAGEDIR}${DESKTOPDIR}/${PORTNAME}.desktop + ${INSTALL_DATA} ${WRKSRC}/devel/${PORTNAME}.png \ + ${STAGEDIR}${PREFIX}/share/pixmaps/${PORTNAME}.png .include <bsd.port.mk> diff --git a/audio/py-pyradio/distinfo b/audio/py-pyradio/distinfo index ad54fa8f4cee..c77e29f2bf02 100644 --- a/audio/py-pyradio/distinfo +++ b/audio/py-pyradio/distinfo @@ -1,3 +1,3 @@ -TIMESTAMP = 1669451407 -SHA256 (coderholic-pyradio-0.8.9.31_GH0.tar.gz) = f5787d002f4bb891dc00421934c93ab42f6afa616dd51773cc53f775b16112a2 -SIZE (coderholic-pyradio-0.8.9.31_GH0.tar.gz) = 629976 +TIMESTAMP = 1670604676 +SHA256 (coderholic-pyradio-0.8.9.32_GH0.tar.gz) = d86f13849151aa9ea5d40310cfb827a3bd7138e8809affa9a0442fbc427b5df6 +SIZE (coderholic-pyradio-0.8.9.32_GH0.tar.gz) = 635875 diff --git a/audio/py-pyradio/files/patch-pyradio_ping.py b/audio/py-pyradio/files/patch-pyradio_ping.py index fe35285c2b92..2ce6336c4c71 100644 --- a/audio/py-pyradio/files/patch-pyradio_ping.py +++ b/audio/py-pyradio/files/patch-pyradio_ping.py @@ -1,11 +1,11 @@ ---- pyradio/ping.py.orig 2022-11-25 15:21:16 UTC +--- pyradio/ping.py.orig 2022-12-09 15:36:15 UTC +++ pyradio/ping.py -@@ -35,7 +35,7 @@ def linux_ping(server, count=1, timeout_in_seconds=1): - -1: error - ''' - try: -- r=subprocess.Popen(['ping', '-c', str(count), '-w', str(timeout_in_seconds), server ], stdout=subprocess.PIPE).stdout.read() -+ r=subprocess.Popen(['ping', '-c', str(count), '-t', str(timeout_in_seconds), server ], stdout=subprocess.PIPE).stdout.read() - # print(r) - return 0 if '100%' in str(r) else 1 - except: +@@ -49,7 +49,7 @@ def linux_ping(server, count=1, timeout_in_seconds=1): + return 0 if '100%' in out[0] else 1 + else: + r=subprocess.Popen( +- ['ping', '-c', str(count), '-w', ++ ['ping', '-c', str(count), '-t', + str(timeout_in_seconds), server], + stderr=subprocess.DEVNULL, + stdout=subprocess.PIPE