I am using OpenCV, which seems to relies on QtWidgets if I'm not wrong.
When running the app, I get this error:
Traceback (most recent call last):
File "scrip.py", line 6, in <module>
File
"/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/PyInstaller/loader/pyimod03_importers.py",
line 627, in exec_module
exec(bytecode, module.__dict__)
File "site-packages/cv2/__init__.py", line 3, in <module>
ImportError:
dlopen(/Users/jessiesui/projects/salvage/dist/scrip/cv2/cv2.cpython-36m-darwin.so,
2): Library not loaded: @loader_path/../QtWidgets
Referenced from:
/Users/jessiesui/projects/salvage/dist/scrip/cv2/cv2.cpython-36m-darwin.so
Reason: Incompatible library version: cv2.cpython-36m-darwin.so requires
version 5.13.0 or later, but QtWidgets provides version 5.9.0
Line 6 of scrip.py is "import cv2". I have tried to prevent QtWidgets from
being added by putting "a.binaries = a.binaries -
TOC([('QtWidgets',None,None)])" in my .spec file, but then OpenCV does not
work (error message below) which is why I believe PyInstaller's OpenCV
relies on QtWidgets.
Traceback (most recent call last):
File "scrip.py", line 6, in <module>
File
"/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/PyInstaller/loader/pyimod03_importers.py",
line 627, in exec_module
exec(bytecode, module.__dict__)
File "site-packages/cv2/__init__.py", line 3, in <module>
ImportError:
dlopen(/Users/jessiesui/projects/salvage/dist/scrip/cv2/cv2.cpython-36m-darwin.so,
2): Library not loaded: @loader_path/../QtWidgets
Referenced from:
/Users/jessiesui/projects/salvage/dist/scrip/cv2/cv2.cpython-36m-darwin.so
Reason: image not found
Is there a way for me to have QtWidgets provide the needed version? Thank
you so much.
--
You received this message because you are subscribed to the Google Groups
"PyInstaller" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/pyinstaller/320d99c9-1554-4c64-98f1-27e468d1bdc5%40googlegroups.com.