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

moc parse error when tbb.h included

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • P2: Important
    • 5.15.6
    • 5.14.0, 5.15.5
    • Build tools: moc
    • Linux/X11

    Description

      The Meta object compiler  (moc) issues parse error when Intel <tbb/tbb.h> is included in header hierarchy .

      The moc output message is :
      usr/include/tbb/tbb_profiling.:28: Parse error at "{"

      The minimal code example to reproduce  is attached.

      The example uses the 'WITH_TBB' macro to include/exclude the <tbb.h>
      #if WITH_TBB
      #include <tbb/tbb.h>
      #endif

      To build the example  with and without of TBB dependency use the -DWITH_TBB=ON/OFF cmake parameter

      $ mkdir build && cd build && cmake -DWITH_TBB=ON ..

       

       

      The TBB versioon is 2020.0-1

      $ pacman -Qi intel-tbb
      Name : intel-tbb
      Version : 2020.0-1
      Description : High level abstract threading library
      Architecture : x86_64
      URL : https://www.threadingbuildingblocks.org/
      Licenses : GPL
      Groups : None
      Provides : None
      Depends On : gcc-libs
      Optional Deps : None
      Required By : opencv suitesparse
      Optional For : intel-mkl-slim
      Conflicts With : None
      Replaces : None
      Installed Size : 2.13 MiB
      Packager : Antonio Rojas <arojas@archlinux.org>
      Build Date : Wed 18 Dec 2019 09:30:42 PM EET
      Install Date : Thu 19 Dec 2019 03:07:35 AM EET
      Install Reason : Installed as a dependency for another package
      Install Script : No
      Validated By : Signature

       

      Attachments

        1. QTBUG-80578.zip
          0.6 kB
          Keith Kyzivat
        2. tbbmoc_test.tar.bz2
          1 kB
          Andrey Myznikov

        Issue Links

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

          Activity

            People

              mmutz Marc Mutz
              amyznikov Andrey Myznikov
              Votes:
              10 Vote for this issue
              Watchers:
              19 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Gerrit Reviews

                  There are no open Gerrit changes