achille-martin / pyqt-crom

Create cross-platform apps (Android for now) using only Python and the Qt Framework (PyQt5 for now).
MIT License
29 stars 2 forks source link

bug: demo project does not start without libxcb-xinerama-so.0 being installed #34

Closed mcdurdin closed 7 months ago

mcdurdin commented 7 months ago

Following the steps as given in the README, we encountered core dump trying to run the demo at step 1.4.4.

This gives a solution: https://askubuntu.com/questions/1298645/shared-library-not-found-for-pyqt5-libxcb-xinerama-so-0-not-found

sudo apt install libxcb-xinerama0
achille-martin commented 7 months ago

Thanks for your contribution!

Interesting, I mentioned this issue in v1.0.0 and how to troubleshoot it.

When I created v2.0.0 and tested it with a fresh build, I didn't encounter any problem with Qt and xcb, so I removed it.

I can re-add the fix suggestion to the troubleshooting note.

Here are my questions to find the origin of the issue: 1) What is the error message you got (fully)? 2) What is your setup? (python, OS, virtual machine?, ubuntu, etc.) 3) By any chance, did you install Qt Creator at this step? It seems here and here that it could be the origin of the problem. 4) Did your problem get fixed after using sudo apt install libxcb-xinerama0?

mcdurdin commented 7 months ago

1.

(pyqt-crom-env) sandy@pyqt-crom:~/pyqt-crom/examples/demo/demo_project/demo_pkg$ python3 demo_app.py 
qt.qpa.plugin: Could not load the Qt platform plugin "xcb" in "" even though it was found.
This application failed to start because no Qt platform plugin could be initialized. Reinstalling the application may fix this problem.

Available platform plugins are: eglfs, linuxfb, minimal, minimalegl, offscreen, vnc, wayland-egl, wayland, wayland-xcomposite-egl, wayland-xcomposite-glx, webgl, xcb.

Aborted (core dumped)
  1. Brand new Ubuntu 22.04 VM, following steps in README
  2. No
  3. Yes, although it was later in the install when we had trouble with Qt that we went back and retried (after other external deps installed)
achille-martin commented 7 months ago

I have created a PR to fix the instructions:

Please double-check if you wish and I'll merge.

Thanks again