-
Notifications
You must be signed in to change notification settings - Fork 1.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
test qt components #5922
test qt components #5922
Conversation
The test does not work for me: [100%] Built target test_package Aborted (core dumped) Does anyone have the same problem? |
This comment has been minimized.
This comment has been minimized.
There is exactly the same problem in CI as I have locally |
That probably means lack of deployment. Does this build Qt as a shared library? You can't use a Qt application before running [win/linux/mac]deployqt on it (that basically copies dlls over and creates files). It works magically on Qt Creator because it adds the Qt libs to path when you click the play button. Now with the PR of proper Qt5 components, if you want to know how to use it, you can read the official documentation... |
Do you have the problem only when using qt as a static library (which is the default)? Can you please try to use Q_IMPORT_PLUGIN ? EDIT: the error you have is different from the one reported by the bot. In you case the executable built by qmake is able to run properly, but the executable built by cmake fails to find the xcb plugin. The bot fails to run the executable built by qmake because |
Yeah, as @ericLemanissier said, this seems to be an issue with headless environments, and definitely lack of "deployment". Qt Applications aren't trivial to run. |
I have removed a gui part, so an example should be able to run on a headless system. |
We'll find out in a couple hours after this really have library rebuilds in the CI :) |
I have tried to run macdeployqt with the old bincrafters recipe out of conanfile, but it didn't work on some reason for me. |
If you read the commit log, there was a patch explicitly for macdeploy Qt. I don't have a mac, sorry, so I can't give input. |
Failure in build 2 (
Note: To save resources, CI tries to finish as soon as an error is found. For this reason you might find that not all the references have been launched or not all the configurations for a given reference. Also, take into account that we cannot guarantee the order of execution as it depends on CI workload and workers availability. |
For all interested, this code allows to create a runnable qt executable with all plugins for gui.
I have reported this issue a while ago |
Wouldn't run [win|mac|linux]deployqt be must better in this scenario? # On Windows, run windeployqt after building
if(WIN32)
# Run winddeployqt if it can be found
find_program(
WINDEPLOYQT_EXECUTABLE
NAMES windeployqt
HINTS ${QTDIR} ENV QTDIR
PATH_SUFFIXES bin)
add_custom_command(
TARGET qt5_example
POST_BUILD
COMMAND ${WINDEPLOYQT_EXECUTABLE} $<TARGET_FILE:qt5_example>)
endif() |
I detected other pull requests that are modifying qt/5.x.x recipe:
This message is automatically generated by https://github.com/ericLemanissier/conan-center-conflicting-prs so don't hesitate to report issues/improvements there. |
It fails because you copy the symlinks e.g. |
This code worked with bincrafters recipe:
|
Specify library name and version: qt/5.15.2
I think, I am not an only one who would like to have a working example, demonstrating how to include different Qt modules in CMakeLists or *.pro file. test_package/ is a perfect place for it.
This is also a good place to share with all of us why you are submitting this PR (specially if it is a new addition to ConanCenter): is it a dependency of other libraries you want to package? Are you the author of the library? Thanks!
conan-center hook activated.