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

wrong order of includes & libraries from configure -I & -L

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • P3: Somewhat important
    • 5.6.1
    • 3.x, 4.5.0, 4.5.1, 4.5.2, 4.5.3, 4.6.0, 4.6.1
    • Build System
    • None
    • 867357235ecfe12edd9940d5c8ef08f4e6ac559d

    Description

      When compiling Qt 4.6 (seems to be the same issue for Git 4.6-stable, 4.6 and master, and also the release candidate 1), there seems to be a include search path clash when Qt is compiled with -qt-sql-mysql and -with-webkit.

      Since MySQL support is not included by default, I have to compile Qt manually, and I used the following configuration:

      /Devel/qt/configure \
        -fast \
        -opensource \
        -no-qt3support \
        -no-xmlpatterns \
        -no-stl \
        -no-accessibility \
        -no-multimedia \
        -no-phonon \
        -no-phonon-backend \
        -confirm-license \
        -qt-sql-sqlite \
        -qt-sql-mysql \
        -nomake "demos examples" \
        -silent \
        -qt-sql-mysql \
        -release \
        -I /usr/local/libmysql/include \
        -L /usr/local/libmysql/lib \
      

      As you can see, I defined an additional include path for the libmysql code/libraries. Now when I run make, it compiles fine for a while, but as soon as it reaches a certain part of WebKit code, the following happens:

      [...]
      compiling /Devel/qt/src/3rdparty/webkit/WebCore/bindings/js/JSCustomPositionErrorCallback.cpp
      compiling /Devel/qt/src/3rdparty/webkit/WebCore/bindings/js/JSCustomVoidCallback.cpp
      compiling /Devel/qt/src/3rdparty/webkit/WebCore/bindings/js/JSCustomXPathNSResolver.cpp
      compiling /Devel/qt/src/3rdparty/webkit/WebCore/bindings/js/JSDataGridColumnListCustom.cpp
      compiling /Devel/qt/src/3rdparty/webkit/WebCore/bindings/js/JSDataGridDataSource.cpp
      compiling /Devel/qt/src/3rdparty/webkit/WebCore/bindings/js/JSDocumentCustom.cpp
      compiling /Devel/qt/src/3rdparty/webkit/WebCore/bindings/js/JSDocumentFragmentCustom.cpp
      compiling /Devel/qt/src/3rdparty/webkit/WebCore/bindings/js/JSDOMGlobalObject.cpp
      compiling /Devel/qt/src/3rdparty/webkit/WebCore/bindings/js/JSDOMWindowBase.cpp
      compiling /Devel/qt/src/3rdparty/webkit/WebCore/bindings/js/JSDOMWindowCustom.cpp
      /Devel/qt/src/3rdparty/webkit/WebCore/bindings/js/JSDOMWindowCustom.cpp: In member function 'JSC::JSValue WebCore::JSDOMWindow::atob(JSC::ExecState*, const JSC::ArgList&)':
      /Devel/qt/src/3rdparty/webkit/WebCore/bindings/js/JSDOMWindowCustom.cpp:1015: error: 'base64Decode' was not declared in this scope
      /Devel/qt/src/3rdparty/webkit/WebCore/bindings/js/JSDOMWindowCustom.cpp: In member function 'JSC::JSValue WebCore::JSDOMWindow::btoa(JSC::ExecState*, const JSC::ArgList&)':
      /Devel/qt/src/3rdparty/webkit/WebCore/bindings/js/JSDOMWindowCustom.cpp:1041: error: 'base64Encode' was not declared in this scope
      compiling /Devel/qt/src/3rdparty/webkit/WebCore/bindings/js/JSDOMWindowShell.cpp
      make[2]: *** [obj/release/JSDOMWindowCustom.o] Error 1
      make[2]: *** Waiting for unfinished jobs....
      make[1]: *** [release] Error 2
      make: *** [sub-webkit-make_default-ordered] Error 2
      bbense-mbp:qt bbense$ 
      

      It seems that it's possible to work around this by moving the libmysql from a "contained" place like /usr/local/libmysql/, which in turn contains include, lib and bin; to their "public" places like /usr/local/include, etc.

      I consider this to be a blocker, since it costs a LOT of time if you run into this issue and it likely leads to more reports and problems on the user side.
      I assume this is due to the wrong order of include paths, and WebKit includes a file that appears to have the same name in the MySQL drivers, and that one is included instead.

      Also, take a look at a discussion on the mailing lists for more information:
      http://lists.trolltech.com/pipermail/qt4-preview-feedback/2009-November/001114.html

      Attachments

        Issue Links

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

          Activity

            People

              buddenha Oswald Buddenhagen
              bastibense Bastian Bense
              Votes:
              1 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Gerrit Reviews

                  There are no open Gerrit changes