diff options
author | Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com> | 2015-06-05 17:45:47 +0200 |
---|---|---|
committer | Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com> | 2015-09-17 16:36:12 +0000 |
commit | 967372c975fcaea5c2ef4e8a5950fb60bab10e6c (patch) | |
tree | d54c001705ff067bf77717e8c43850bdd344a2ee /mkspecs/features/mac | |
parent | e853edd657d8f403d175a0e0c305ebf61a51f3ef (diff) |
sanitize qt rpath handling, in particular on mac
the addition of qt's rpath belongs into qt.prf - even on mac.
so consolidate the two implementations.
as a nice "side effect", we get relative rpaths also on linux.
another "side effect" is that we don't unnecessarily add the qt rpath to
qt modules also on linux.
the qt rpath addition mechanism should not be responsible for setting
the policy who gets a relative rpath, so move the logic to higher-level
callers.
Change-Id: I52e8fe2e8279e7b1ac25fae758867a5cb1cafcf8
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Diffstat (limited to 'mkspecs/features/mac')
-rw-r--r-- | mkspecs/features/mac/default_post.prf | 25 |
1 files changed, 0 insertions, 25 deletions
diff --git a/mkspecs/features/mac/default_post.prf b/mkspecs/features/mac/default_post.prf index 7100717b78..30960e66dd 100644 --- a/mkspecs/features/mac/default_post.prf +++ b/mkspecs/features/mac/default_post.prf @@ -22,31 +22,6 @@ qt { 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 expected to be installed into the Qt prefix build, use - # relative path, so all SDK tools and examples work when relocated. - prefix_build:defined(target.path, var):\ - contains(target.path, "$$re_escape($$[QT_INSTALL_PREFIX])/.*"):\ - # Tests are an exception, since they are launched in their build not - # install location by CI, so we cannot use relative rpaths there. - !contains(target.path, "$$re_escape($$[QT_INSTALL_TESTS])/.*") { - 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) - } else { - # Otherwise, use absolute path to Qt libraries - QMAKE_RPATHDIR = $$[QT_INSTALL_LIBS] - } - } } macx-xcode:!isEmpty(QMAKE_XCODE_DEBUG_INFORMATION_FORMAT) { |