summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEkaterina Vaartis <vaartis@kotobank.ch>2021-06-03 11:15:35 +0300
committerMichał Górny <mgorny@gentoo.org>2021-06-05 14:36:15 +0200
commit46ae38a7e0e44aef269a444bab234ee200e6f080 (patch)
tree3bde95ffb652998253853868826491ff26d785dd /media-gfx/hydrus/files
parentprofiles/arch/arm64: drop obsolete mask for www-client/chromium[tcmalloc] (diff)
downloadgentoo-46ae38a7e0e44aef269a444bab234ee200e6f080.tar.gz
gentoo-46ae38a7e0e44aef269a444bab234ee200e6f080.tar.bz2
gentoo-46ae38a7e0e44aef269a444bab234ee200e6f080.zip
media-gfx/hydrus: Update to 442 + upnpc fix
Signed-off-by: Ekaterina Vaartis <vaartis@kotobank.ch> Closes: https://github.com/gentoo/gentoo/pull/21100 Signed-off-by: Michał Górny <mgorny@gentoo.org>
Diffstat (limited to 'media-gfx/hydrus/files')
-rw-r--r--media-gfx/hydrus/files/test-exitcode.patch36
-rw-r--r--media-gfx/hydrus/files/upnpc.patch40
2 files changed, 76 insertions, 0 deletions
diff --git a/media-gfx/hydrus/files/test-exitcode.patch b/media-gfx/hydrus/files/test-exitcode.patch
new file mode 100644
index 000000000000..d61d341ee1ef
--- /dev/null
+++ b/media-gfx/hydrus/files/test-exitcode.patch
@@ -0,0 +1,36 @@
+diff --git a/hydrus/hydrus_test.py b/hydrus/hydrus_test.py
+index 3504c9c..7f95af8 100644
+--- a/hydrus/hydrus_test.py
++++ b/hydrus/hydrus_test.py
+@@ -91,6 +91,9 @@ def boot():
+ if sys.stdin.isatty():
+
+ input( 'Press any key to exit.' )
++ else:
+
++ success = 0 if controller.was_successful else 1
++ sys.exit(success)
+
+
+diff --git a/hydrus/test/TestController.py b/hydrus/test/TestController.py
+index 0c43440..7e6c5ef 100644
+--- a/hydrus/test/TestController.py
++++ b/hydrus/test/TestController.py
+@@ -168,7 +168,6 @@ only_run = None
+ class Controller( object ):
+
+ def __init__( self, win, only_run ):
+-
+ self.app = win
+ self.win = win
+ self.only_run = only_run
+@@ -827,8 +826,7 @@ class Controller( object ):
+ def do_it():
+
+ try:
+-
+- runner.run( suite )
++ self.was_successful = runner.run( suite ).wasSuccessful()
+
+ finally:
+
diff --git a/media-gfx/hydrus/files/upnpc.patch b/media-gfx/hydrus/files/upnpc.patch
new file mode 100644
index 000000000000..ea78f2b70b63
--- /dev/null
+++ b/media-gfx/hydrus/files/upnpc.patch
@@ -0,0 +1,40 @@
+diff --git a/hydrus/core/networking/HydrusNATPunch.py b/hydrus/core/networking/HydrusNATPunch.py
+index c959753..6792d89 100644
+--- a/hydrus/core/networking/HydrusNATPunch.py
++++ b/hydrus/core/networking/HydrusNATPunch.py
+@@ -3,6 +3,7 @@ import socket
+ import subprocess
+ import threading
+ import traceback
++import shutil
+
+ from hydrus.core import HydrusConstants as HC
+ from hydrus.core import HydrusData
+@@ -18,7 +19,7 @@ if HC.PLATFORM_WINDOWS:
+
+ else:
+
+- possible_bin_filenames = [ 'upnpc-static', 'upnpc-shared', 'miniupnpc' ]
++ possible_bin_filenames = [ 'upnpc', 'upnpc-static', 'upnpc-shared', 'miniupnpc' ]
+
+ if HC.PLATFORM_LINUX:
+
+@@ -42,7 +43,17 @@ for filename in possible_bin_filenames:
+
+ UPNPC_PATH = possible_path
+
+-
++ break
++
++ maybe_in_path = shutil.which( filename )
++
++ if maybe_in_path:
++
++ UPNPC_PATH = maybe_in_path
++
++ break
++
++
+ EXTERNAL_IP = {}
+ EXTERNAL_IP[ 'ip' ] = None
+ EXTERNAL_IP[ 'time' ] = 0