Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-67189

qdoc doesn't use clang from standard paths



    • Type: Bug
    • Status: Closed
    • Priority: P1: Critical
    • Resolution: Done
    • Affects Version/s: 5.11.0 Beta 2, 5.12.0 Alpha
    • Fix Version/s: 5.12.0 Beta 1
    • Component/s: Build tools: qdoc
    • Labels:
    • Commits:
      8f7cf4b535f90231947e8a9efaa5a10c2566cab4, 0e48dff881f8f2eda07dc07057e12cf0fbdda062, 78ad47466567adb79c59a239d380906fa7aa61cc


      I have clang installed on my system and I want it to be used for building qdoc. To that end I've made sure that llvm-config is in $PATH:

      ulf@zebra:~$ llvm-config --version

      This is the common behavior when you just install libclang-dev or similar using your distribution's package manager. I did not manually set any paths or tweak any configuration settings. "apt-get install libclang-dev" installs the package in a well-known location and other tools should just use this, if not instructed otherwise. At least that's the intention of system wide package managemet.

      However, instead of just using that clang, qdoc just refuses to build. http://doc-snapshots.qt.io/qt5-5.11/qdoc-guide-clang.html tells me that I have to set an environment variable to build qdoc. This is a bad idea for the following reasons

      • I will most likely only find out about this after unsuccessfully trying to build qdoc and searching in the documentation for the reason or asking others. Therefore this wastes people's time.
      • It is not standard practice to require environment variables for using system-installed 3rdparty libraries. The qtbase build system probes various libraries at configure time and just uses them if found. There for the requirement of setting an environment variable creates friction.
      • People will fail to build qdoc and just assume that it's not meant for them to use. This reduces the exposure of qdoc to potential testers in the community.


          Issue Links

          No reviews matched the request. Check your Options in the drop-down menu of this sections header.



              paulwicking Paul Wicking
              ulherman Ulf Hermann
              2 Vote for this issue
              9 Start watching this issue



                  Gerrit Reviews

                  There are no open Gerrit changes