Title: [121901] trunk/Tools
Revision
121901
Author
[email protected]
Date
2012-07-05 06:10:04 -0700 (Thu, 05 Jul 2012)

Log Message

[Qt] Remove rpath-hacks in qt_webkit.pri

Having it in qt_webkit.pri meant that all client apps would inherit the rpath,
even if they were not using QtWebKit.

This is a regression for people who build client apps against a non-installed
QtWebKit, as the client app will be missing a rpath to the standalone WebKit
build dir. This can be solved by LD_LIBRARY_PATH or custom QMAKE_RPATHDIR
logic, until the real issue is fixed in Qt.

Reviewed by Csaba Osztrogonác.

Modified Paths

Diff

Modified: trunk/Tools/ChangeLog (121900 => 121901)


--- trunk/Tools/ChangeLog	2012-07-05 12:31:56 UTC (rev 121900)
+++ trunk/Tools/ChangeLog	2012-07-05 13:10:04 UTC (rev 121901)
@@ -1,3 +1,20 @@
+2012-07-05  Tor Arne Vestbø  <[email protected]>
+
+        [Qt] Remove rpath-hacks in qt_webkit.pri
+
+        Having it in qt_webkit.pri meant that all client apps would inherit the rpath,
+        even if they were not using QtWebKit.
+
+        This is a regression for people who build client apps against a non-installed
+        QtWebKit, as the client app will be missing a rpath to the standalone WebKit
+        build dir. This can be solved by LD_LIBRARY_PATH or custom QMAKE_RPATHDIR
+        logic, until the real issue is fixed in Qt.
+
+        Reviewed by Csaba Osztrogonác.
+
+        * qmake/mkspecs/features/rpath.prf:
+        * qmake/qt_webkit.pri:
+
 2012-07-05  Dongwoo Im  <[email protected]>
 
         [EFL] Enable the CUSTOM_SCHEME_HANDLER feature as default.

Modified: trunk/Tools/qmake/mkspecs/features/rpath.prf (121900 => 121901)


--- trunk/Tools/qmake/mkspecs/features/rpath.prf	2012-07-05 12:31:56 UTC (rev 121900)
+++ trunk/Tools/qmake/mkspecs/features/rpath.prf	2012-07-05 13:10:04 UTC (rev 121901)
@@ -1,23 +1,25 @@
 # -------------------------------------------------------------------
 # Set rpath for the application/library we're building
 #
-# Only used by Qt4.
-#
 # See 'Tools/qmake/README' for an overview of the build system
 # -------------------------------------------------------------------
 
-haveQt(4) {
-    equals(ROOT_BUILD_DIR, $$dirname(DESTDIR)): RPATHDIR_RELATIVE_TO_DESTDIR = ../lib
+equals(ROOT_BUILD_DIR, $$dirname(DESTDIR)): RPATHDIR_RELATIVE_TO_DESTDIR = ../lib
 
-    linux-*:!isEmpty(RPATHDIR_RELATIVE_TO_DESTDIR) {
-        # Do the rpath by hand since it's not possible to use ORIGIN in QMAKE_RPATHDIR
-        # this expands to $ORIGIN (after qmake and make), it does NOT read a qmake var.
-        QMAKE_RPATHDIR = \$\$ORIGIN/$${RPATHDIR_RELATIVE_TO_DESTDIR} $${QMAKE_RPATHDIR}
-        RPATH = $$join(QMAKE_RPATHDIR, ":")
+linux-*:!isEmpty(RPATHDIR_RELATIVE_TO_DESTDIR) {
+    # Do the rpath by hand since it's not possible to use ORIGIN in QMAKE_RPATHDIR
+    # this expands to $ORIGIN (after qmake and make), it does NOT read a qmake var.
+    QMAKE_RPATHDIR = \$\$ORIGIN/$${RPATHDIR_RELATIVE_TO_DESTDIR} $${QMAKE_RPATHDIR}
+    RPATH = $$join(QMAKE_RPATHDIR, ":")
 
-        QMAKE_LFLAGS += -Wl,-z,origin \'-Wl,-rpath,$${RPATH}\'
-        QMAKE_RPATHDIR =
-    } else {
-        QMAKE_RPATHDIR = $${ROOT_BUILD_DIR}/lib $${QMAKE_RPATHDIR}
-    }
+    QMAKE_LFLAGS += -Wl,-z,origin \'-Wl,-rpath,$${RPATH}\'
+    QMAKE_RPATHDIR =
+} else {
+    QMAKE_RPATHDIR = $${ROOT_BUILD_DIR}/lib $${QMAKE_RPATHDIR}
 }
+
+# FIXME: For Qt5 this will only give correct rpath for the tools that come with WebKit
+# Any client application built against a developer-build of Qt + WebKit (that does
+# QT += webkit) will not get the rpath pointing to the stand-alone WebKit-build,
+# and will have to set LD_LIBRARY_PATH or do their own rpath logic. This needs
+# to be fixed on the Qt side.

Modified: trunk/Tools/qmake/qt_webkit.pri (121900 => 121901)


--- trunk/Tools/qmake/qt_webkit.pri	2012-07-05 12:31:56 UTC (rev 121900)
+++ trunk/Tools/qmake/qt_webkit.pri	2012-07-05 13:10:04 UTC (rev 121901)
@@ -27,15 +27,3 @@
 QT_WEBKIT_MAJOR_VERSION = $$QT.webkit.MAJOR_VERSION
 QT_WEBKIT_MINOR_VERSION = $$QT.webkit.MINOR_VERSION
 QT_WEBKIT_PATCH_VERSION = $$QT.webkit.PATCH_VERSION
-
-unix:!mac {
-    !isEmpty(QT_MODULE_LIB_BASE):!equals(QT_MODULE_LIB_BASE, $$[QT_INSTALL_LIBS]) {
-        # We are loading the qt_webkit.pri forwarding file from the
-        # local webkit build directory, so set up rpath to point to
-        # to the local build. This ensures that any of the WebKit tools
-        # such as WebKitTestRunner and QtTestBrowser will link to the
-        # non-installed QtWebKit library. The same applies to third-
-        # party applications that set QMAKE_EXTRA_MODULE_FORWARDS.
-        QMAKE_LFLAGS *= "$${QMAKE_LFLAGS_RPATH}$${QT_MODULE_LIB_BASE}"
-    }
-}
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes

Reply via email to