Use QMAKE_TARGET_BUNDLE_PREFIX to build bundle identifier

Currently the bundle identifier is build using com.yourcompany +
QMAKE_BUNDLE. This patch adds the handling of
QMAKE_TARGET_BUNDLE_PREFIX to build the bundle prefix.

Task-number: QTBUG-19006

Change-Id: I014279da6dbef393b0df36f6d4995e40ab105316
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Reviewed-by: Liang Qi <liang.qi@digia.com>
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
This commit is contained in:
Samuel Gaist 2014-02-18 10:02:26 +01:00 committed by The Qt Project
parent d0784ae43b
commit 42789d04a3

View File

@ -729,7 +729,10 @@ UnixMakefileGenerator::writeMakeParts(QTextStream &t)
QString::fromLatin1("????") : project->first("QMAKE_PKGINFO_TYPEINFO").left(4)) << ",g\" ";
if(project->first("TEMPLATE") == "app") {
QString icon = fileFixify(var("ICON"));
QString bundleIdentifier = "com.yourcompany." + var("QMAKE_BUNDLE");
QString bundlePrefix = project->first("QMAKE_TARGET_BUNDLE_PREFIX").toQString();
if (bundlePrefix.isEmpty())
bundlePrefix = "com.yourcompany.";
QString bundleIdentifier = bundlePrefix + var("QMAKE_BUNDLE");
if (bundleIdentifier.endsWith(".app"))
bundleIdentifier.chop(4);
t << "@$(DEL_FILE) " << info_plist_out << "\n\t"