Details
-
Bug
-
Resolution: Done
-
P1: Critical
-
5.11.0 Alpha, 5.11.0 Beta 3
-
None
-
Windows 10 Enterprise 1703 version, 64bit x64 MinGW32 bit
Ubuntu 16.04.4 LTS, gcc 5.4.0
Description
It appears that qdoc links against libclang dynamically. As a consequence the binary we ship in our packages do not run out of the box. How to reproduce:
1. Install the 5.11 alpha binaries via the Qt online installer.
2. Try to run the qdoc binary:
./qdoc: error while loading shared libraries: libclang.so.4: cannot open shared object file: No such file or directory
We need to either link statically against libclang or ship the binaries and link with rpath.
The same problem exists on Windows, where any attempt of trying to run qdoc.exe results in a message box with the test "The code execution cannot proceed because libclang.dll was not found. Reinstalling the program may fix this problem.".
The binaries we shipped in 5.10 used to work, so this is a regression.
Update 3.5.2018:
We cannot provide binaries of qdoc if the host compiler is MinGW 5.3.0 and we use static linkage. That means our official x86-64 MinGW packages, our Qt/Android Windows packages and our Qt/QNX Windows will not contain qdoc and users of those packages will not be able to build document of their own application/library (or of Qt itself).
The reason as to why we can't simply perform this build is because libclang is built with MinGW 7.1 (despite the Jenkins stages claiming that it's 5.3) and thus uses symbols from libstdc++ that are new in that version and not present in libstdc++ in 5.3.0 (as undefined symbol references to std::thread::_State::~_State indicate). Unfortunately we cannot build libclang with MinGW 5.3.0 as the compiler crashes during the build.
So the only path to restore qdoc binaries with the chosen approach is to upgrade the MinGW build of Qt to use MinGW 7.1 or newer. Whether that is an acceptable option for the 5.11.0 release is something that needs to be discussed now. If the decision is to ship 5.11.0 without qdoc for the affected builds, then the next question would be: Is an upgrade of MinGW to 7.1 an acceptable option for a patch release of Qt (5.11.x) ?
Conclusion: MinGW and Qt/Android|QNX packages on Windows will ship without qdoc in 5.11.0. MinGW 7.3 builds will be added in parallel to 5.3.0 to Qt for 5.11.1 and then qdoc will be re-enabled for those configurations. Follow-up bugs created and linked from here.
Attachments
Issue Links
- depends on
-
QTBUG-65762 Compiling qdoc in dev is a big pain
- Closed
- duplicates
-
QTBUG-68038 Doc build broken for boot2qt
- Closed
- is duplicated by
-
QTBUG-66538 qdoc has dependency to libclang which is not part of installation
- Closed
- relates to
-
QTBUG-66353 Document LLVM dependency of qdoc
- Closed
-
QTBUG-69791 WIN64: 'cannot find -llibclang' error for static builds using mingw-w64
- Closed
- resulted in
-
QTBUG-68064 Enable the build of qdoc with static libclang linkage when using MinGW
- Closed
-
QTQAINFRA-2380 Create a build job for building libclang specifically for qdoc
- Closed
For Gerrit Dashboard: QTBUG-66015 | ||||||
---|---|---|---|---|---|---|
# | Subject | Branch | Project | Status | CR | V |
226689,9 | Update clang version to 6.0 | 5.11.0 | qt/qt5 | Status: MERGED | -2 | 0 |
227840,9 | Disable QDoc on MinGW | 5.11.0 | qt/qttools | Status: MERGED | +2 | 0 |
227850,4 | Install the MinGW build of libclang | 5.11.0 | qt/qt5 | Status: MERGED | +2 | 0 |