From 1c8b5d83301455b8dabb9674503bb0990ca50909 Mon Sep 17 00:00:00 2001 From: axis Date: Mon, 15 Mar 2010 15:41:32 +0100 Subject: Moved UID2 processing from cpp code to profiles. This enables it to be used by all Symbian build systems. RevBy: Miikka Heikkinen --- mkspecs/features/symbian/default_post.prf | 15 +++++++++++++++ qmake/generators/symbian/symmake.cpp | 18 +----------------- 2 files changed, 16 insertions(+), 17 deletions(-) diff --git a/mkspecs/features/symbian/default_post.prf b/mkspecs/features/symbian/default_post.prf index ed90e3c..d29e460 100644 --- a/mkspecs/features/symbian/default_post.prf +++ b/mkspecs/features/symbian/default_post.prf @@ -31,3 +31,18 @@ contains(TEMPLATE, ".*app"):contains(QT, gui):contains(CONFIG,qt) { } isEmpty(TARGET.UID3):TARGET.UID3 = $$generate_uid("$${OUT_PWD}/$${TARGET}") +isEmpty(TARGET.UID2) { + contains(CONFIG, stdbinary) { + TARGET.UID2 = 0x20004C45 + } else { + contains(TEMPLATE, app) { + contains(QT, gui) { + TARGET.UID2 = 0x100039CE + } else { + TARGET.UID2 = 0 + } + } else:contains(TEMPLATE, lib):!contains(CONFIG, static):!contains(CONFIG, staticlib) { + TARGET.UID2 = 0x1000008d + } + } +} diff --git a/qmake/generators/symbian/symmake.cpp b/qmake/generators/symbian/symmake.cpp index 393e56b..83d1149 100644 --- a/qmake/generators/symbian/symmake.cpp +++ b/qmake/generators/symbian/symmake.cpp @@ -315,23 +315,7 @@ void SymbianMakefileGenerator::init() // .mmp initMmpVariables(); - if (0 != project->values("TARGET.UID2").size()) { - uid2 = project->first("TARGET.UID2"); - } else if (project->isActiveConfig("stdbinary")) { - uid2 = "0x20004C45"; - } else { - if (targetType == TypeExe) { - if (project->values("QT").contains("gui", Qt::CaseInsensitive)) { - // exe and gui -> uid2 needed - uid2 = "0x100039CE"; - } else { - // exe but not gui: uid2 is ignored anyway -> set it to 0 - uid2 = "0"; - } - } else if (targetType == TypeDll || targetType == TypeLib || targetType == TypePlugin) { - uid2 = "0x1000008d"; - } - } + uid2 = project->first("TARGET.UID2"); uid2 = uid2.trimmed(); } -- cgit v0.12