From fcb78b500076bf3917e5d8bf8507395bbc33a1a5 Mon Sep 17 00:00:00 2001 From: BogDan Vatra Date: Tue, 17 Sep 2019 09:56:14 +0300 Subject: Android: Fix plugins naming Android 5 doesn't extract the files from libs folder unless they are prefixed with "lib". This patch sets a proper name for the plugin which will make gdb happy and it will also avoid any name clashes. If we rename the plugins when we copy them, gdb won't find them, therefore it can't load their symbols. On Android all the libs are in a single folder, so to make sure we don't have any name clashes, we are prefixing the plugin name with it's relative path to qt folder (we replace / with _). Fixes: QTBUG-78616 Change-Id: I7e0e67d65448532769d69f46b1856c029e2cf5cb Reviewed-by: Eskil Abrahamsen Blomfeldt --- mkspecs/features/qt_functions.prf | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'mkspecs/features/qt_functions.prf') diff --git a/mkspecs/features/qt_functions.prf b/mkspecs/features/qt_functions.prf index 2c68e91cd7..ee6a4b352a 100644 --- a/mkspecs/features/qt_functions.prf +++ b/mkspecs/features/qt_functions.prf @@ -21,7 +21,13 @@ defineReplace(qtLibraryTarget) { } defineReplace(qt5LibraryTarget) { - LIBRARY_NAME = $$qtLibraryTarget($$1) + android { + LIBRARY_NAME_PREFIX = $$2 + LIBRARY_NAME_PREFIX = $$replace(LIBRARY_NAME_PREFIX, "//", "/") + LIBRARY_NAME_PREFIX = $$replace(LIBRARY_NAME_PREFIX, "/", "_") + LIBRARY_NAME = $$LIBRARY_NAME_PREFIX$$qtLibraryTarget($$1) + unset(LIBRARY_NAME_PREFIX) + } else: LIBRARY_NAME = $$qtLibraryTarget($$1) isEmpty(QMAKE_FRAMEWORK_BUNDLE_NAME) { # Insert the major version of Qt in the library name # unless it's a framework build. -- cgit v1.2.3