altendky / qt-tools

Other
1 stars 1 forks source link

error running `qt5-tools uic ...` #9

Open benoit-pierre opened 2 years ago

benoit-pierre commented 2 years ago
▸ ./venv/bin/qt5-tools uic -g python about_dialog.ui
[..]venv/lib/python3.9/site-packages/qt5_applications/Qt/bin/uic: symbol lookup error: [...]/venv/lib/python3.9/site-packages/qt5_applications/Qt/bin/uic: undefined symbol: _ZdlPvm, version Qt_5

But running ./venv/lib/python3.9/site-packages/qt5_applications/Qt/bin/uic -g python about_dialog.ui directly works fine.

It looks like qt5_tools.create_environment is to blame.

Patching LD_LIBRARY_PATH does not seem necessary (running ldd on ./venv/[...]/uic shows that the Qt libraries are correctly resolved relative to the binary, using the qt5_applications libraries), but even if that were necessary I see 3 issues:

altendky commented 2 years ago

Thanks for the detailed report. I was starting into qt-applications to get Qt 6.2 added to the matrix and would of course swing through the upper layer libraries as well. Any chance you might have some time to dig into a solution for this? This has all been finicky for awhile and may well depend on the Qt version and how the linked stuff etc. And yes, presumably I have it wrong in various ways that at least mostly end up not being complained about. :]

Any help you can offer with a PR would be appreciated.

Cheers, -kyle

benoit-pierre commented 2 years ago

I've successfully used qt5-applications directly on Linux/Windows/macOS to generate UI code, so I'd be inclined to just get rid of the create_environment part (even the patch to PATH seems dubious to me).