diff --git a/electrum.spec b/electrum.spec index 924f42f..e3f0f9c 100644 --- a/electrum.spec +++ b/electrum.spec @@ -55,7 +55,7 @@ rm -rf Electrum.egg-info rm -rf packages %build -pyrcc5 icons.qrc -o gui/qt/icons_rc.py +pyrcc5 icons.qrc -o electrum/gui/qt/icons_rc.py %{py3_build} %install diff --git a/zbar-installation-instructions.patch b/zbar-installation-instructions.patch index f9d0572..1bfe38a 100644 --- a/zbar-installation-instructions.patch +++ b/zbar-installation-instructions.patch @@ -1,7 +1,13 @@ -diff --git a/lib/qrscanner.py b/lib/qrscanner.py -index f659d5e4..5f0eee79 100644 ---- a/lib/qrscanner.py -+++ b/lib/qrscanner.py -@@ -45 +45 @@ def scan_barcode(device='', timeout=-1, display=True, threaded=False): +diff --git a/electrum/qrscanner.py b/electrum/qrscanner.py +index 463d5ec6..e4358636 100644 +--- a/electrum/qrscanner.py ++++ b/electrum/qrscanner.py +@@ -42,7 +42,7 @@ except BaseException: + + def scan_barcode(device='', timeout=-1, display=True, threaded=False, try_again=True): + if libzbar is None: - raise RuntimeError("Cannot start QR scanner; zbar not available.") + raise RuntimeError("Cannot start QR scanner; zbar not available. Try 'sudo dnf install zbar-pygtk'") + libzbar.zbar_symbol_get_data.restype = ctypes.c_char_p + libzbar.zbar_processor_create.restype = ctypes.POINTER(ctypes.c_int) + libzbar.zbar_processor_get_results.restype = ctypes.POINTER(ctypes.c_int)