From 661cf8ff4ef55663977a74d9bccf21c50b50f513 Mon Sep 17 00:00:00 2001 From: Andreas Holzammer Date: Tue, 7 Aug 2012 22:22:38 +0200 Subject: Make it possible to force generation of debug info in release builds Change-Id: Ie79e5a6a87475d5140163a2a547b4385a53fc05f Reviewed-by: Oswald Buddenhagen --- tools/configure/configureapp.cpp | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) (limited to 'tools') diff --git a/tools/configure/configureapp.cpp b/tools/configure/configureapp.cpp index 126edb966b..d92a3237be 100644 --- a/tools/configure/configureapp.cpp +++ b/tools/configure/configureapp.cpp @@ -276,6 +276,7 @@ Configure::Configure(int& argc, char** argv) dictionary[ "BUILD" ] = "debug"; dictionary[ "BUILDALL" ] = "auto"; // Means yes, but not explicitly + dictionary[ "FORCEDEBUGINFO" ] = "no"; dictionary[ "BUILDTYPE" ] = "none"; @@ -459,6 +460,8 @@ void Configure::parseCmdLine() dictionary[ "BUILDALL" ] = "no"; } else if (configCmdLine.at(i) == "-debug-and-release") dictionary[ "BUILDALL" ] = "yes"; + else if (configCmdLine.at(i) == "-force-debug-info") + dictionary[ "FORCEDEBUGINFO" ] = "yes"; else if (configCmdLine.at(i) == "-shared") dictionary[ "SHARED" ] = "yes"; @@ -1596,6 +1599,8 @@ bool Configure::displayHelp() desc("BUILD", "debug", "-debug", "Compile and link Qt with debugging turned on."); desc("BUILDALL", "yes", "-debug-and-release", "Compile and link two Qt libraries, with and without debugging turned on.\n"); + desc("FORCEDEBUGINFO", "yes","-force-debug-info", "Create symbol files for release builds.\n"); + desc("OPENSOURCE", "opensource", "-opensource", "Compile and link the Open-Source Edition of Qt."); desc("COMMERCIAL", "commercial", "-commercial", "Compile and link the Commercial Edition of Qt.\n"); @@ -2392,6 +2397,8 @@ void Configure::generateOutputVars() if (dictionary[ "BUILDALL" ] == "yes") { qtConfig += "build_all"; } + if (dictionary[ "FORCEDEBUGINFO" ] == "yes") + qtConfig += "force_debug_info"; qmakeConfig += dictionary[ "BUILD" ]; dictionary[ "QMAKE_OUTDIR" ] = dictionary[ "BUILD" ]; @@ -3204,7 +3211,14 @@ void Configure::displayConfig() sout << "Host Architecture..........." << dictionary["QT_HOST_ARCH"] << ", features:" << dictionary["QT_HOST_CPU_FEATURES"] << endl; sout << "Maketool...................." << dictionary[ "MAKE" ] << endl; - sout << "Debug symbols..............." << (dictionary[ "BUILD" ] == "debug" ? "yes" : "no") << endl; + if (dictionary[ "BUILDALL" ] == "yes") { + sout << "Debug build................." << "yes (combined)" << endl; + sout << "Default build..............." << dictionary[ "BUILD" ] << endl; + } else { + sout << "Debug......................." << (dictionary[ "BUILD" ] == "debug" ? "yes" : "no") << endl; + } + if (dictionary[ "BUILD" ] == "release" || dictionary[ "BUILDALL" ] == "yes") + sout << "Force debug info............" << dictionary[ "FORCEDEBUGINFO" ] << endl; sout << "Link Time Code Generation..." << dictionary[ "LTCG" ] << endl; sout << "Accessibility support......." << dictionary[ "ACCESSIBILITY" ] << endl; sout << "RTTI support................" << dictionary[ "RTTI" ] << endl; -- cgit v1.2.3