diff options
author | Frederik Gladhorn <frederik.gladhorn@theqtcompany.com> | 2014-11-24 13:37:06 +0100 |
---|---|---|
committer | Frederik Gladhorn <frederik.gladhorn@theqtcompany.com> | 2014-11-24 13:39:13 +0100 |
commit | 34aba4724f196e34ed02cf50073f41968f119bb6 (patch) | |
tree | 0ebdfcabda989ab76ee6de53c6461553c7a767a5 /mkspecs/features/mac/default_post.prf | |
parent | b86b2a742afae118bf974c82ba966ddb0cae4afb (diff) | |
parent | b1cf07f495e10c93e53651ac03e46ebdaea0a97e (diff) |
Merge remote-tracking branch 'origin/5.4' into dev
Conflicts:
src/corelib/io/qiodevice.cpp
src/plugins/bearer/linux_common/qofonoservice_linux.cpp
src/plugins/bearer/linux_common/qofonoservice_linux_p.h
src/plugins/platforms/android/qandroidplatformtheme.cpp
src/tools/bootstrap/bootstrap.pro
src/widgets/styles/qmacstyle_mac.mm
Change-Id: Ia02aab6c4598ce74e9c30bb4666d5e2ef000f99b
Diffstat (limited to 'mkspecs/features/mac/default_post.prf')
-rw-r--r-- | mkspecs/features/mac/default_post.prf | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/mkspecs/features/mac/default_post.prf b/mkspecs/features/mac/default_post.prf index 530683552b..246c9c60e6 100644 --- a/mkspecs/features/mac/default_post.prf +++ b/mkspecs/features/mac/default_post.prf @@ -35,6 +35,30 @@ qt:!isEmpty(QT_CONFIG) { QMAKE_LFLAGS += -stdlib=libstdc++ } } + # If Qt was built with shared libraries with rpath support and project does + # not specify own rpaths (including empty list) add one pointing to Qt + # libraries. This applies only to apps, since all loaded libraries inherit + # rpaths from current process executable. + else:!if(host_build:force_bootstrap):equals(TEMPLATE, app):!defined(QMAKE_RPATHDIR, var):contains(QT_CONFIG, rpath) { + # If app is outside of Qt SDK prefix use absolute path to Qt libraries, + # otherwise make it relative, so all SDK tools and examples work when + # relocated. + # Tests are an exception, since they are launched in their build not + # install location by CI, so we cannot use relative rpaths there. + if(!contains(target.path, "$$re_escape($$[QT_INSTALL_PREFIX])/.*")|\ + contains(target.path, "$$re_escape($$[QT_INSTALL_TESTS])/.*")) { + QMAKE_RPATHDIR = $$[QT_INSTALL_LIBS] + } else { + app_bundle { + ios: binpath = $$target.path/$${TARGET}.app + else: binpath = $$target.path/$${TARGET}.app/Contents/MacOS + } else { + binpath = $$target.path + } + QMAKE_RPATHDIR = @loader_path/$$relative_path($$[QT_INSTALL_LIBS], $$binpath) + unset(binpath) + } + } } macx-xcode:!isEmpty(QMAKE_XCODE_DEBUG_INFORMATION_FORMAT) { |