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

Mingw keyword "interface" conflict in QtDBus

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • P1: Critical
    • 5.6.0 Beta, 5.6.0
    • 5.6.0 Alpha
    • D-Bus
    • None
    • Windows
      Thread model: posix
      gcc version 4.9.2 (i686-posix-dwarf-rev1, Built by MinGW-W64 project)
      Qt 5.6 Alpha1
    • 32f957ccc68084fe11fcf23823c5094a1833a790, 786d23bb4966b6697ac04c43158e2312d898e133

    Description

      Short summary:
      There is a build failure in QtDBus 5.6-alpha due to the usage of the preserved keyword "interface". build.log is attached.

      Long summary:
      The latest QtDBus changes in branch 5.6 have disclosed a very old problem. There are a lot public API methods in QDBusConnection which have the following argument:

      const QString &interface

      and there is also the method

      QDBusConnectionInterface *QDBusConnection ::interface() const;

      According to MSDN interface is a Windows C++ extension and a reserved keyword.

      I can only speak for MinGW-w64 for now, but they indeed declare it in
      i686-w64-mingw32\include\rpc.h

      #ifndef _OBJC_
      #undef interface
      #define interface struct
      #endif

      Maybe due to some rearranges of header includes, this header is now included and causes the build failures in the attached build.log.

      I did not yet submit any patch to gerrit, because there are several options how to address the issue. Attached is a easy fix from Fedora from 2013.

      Attachments

        Issue Links

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

          Activity

            People

              thiago Thiago Macieira
              rolandwinklmeier Roland Winklmeier
              Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Gerrit Reviews

                  There are no open Gerrit changes